2022-08-19 15:59:36 +02:00
|
|
|
// Copyright (C) 2016 The Qt Company Ltd.
|
2022-12-21 10:12:09 +01:00
|
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
|
2009-06-04 14:43:16 +02:00
|
|
|
|
2016-03-18 07:55:01 +01:00
|
|
|
#pragma once
|
2009-06-04 14:43:16 +02:00
|
|
|
|
|
|
|
|
#include "utils_global.h"
|
2022-05-24 10:17:39 +02:00
|
|
|
|
2012-02-15 10:42:41 +01:00
|
|
|
#include <QObject>
|
2009-06-04 14:43:16 +02:00
|
|
|
|
|
|
|
|
QT_BEGIN_NAMESPACE
|
2013-03-20 15:45:38 +01:00
|
|
|
class QHeaderView;
|
2009-06-04 14:43:16 +02:00
|
|
|
QT_END_NAMESPACE
|
|
|
|
|
|
|
|
|
|
namespace Utils {
|
|
|
|
|
|
2013-03-20 15:45:38 +01:00
|
|
|
class QTCREATOR_UTILS_EXPORT HeaderViewStretcher : public QObject
|
2009-06-04 14:43:16 +02:00
|
|
|
{
|
2011-03-02 17:13:33 +01:00
|
|
|
const int m_columnToStretch;
|
2009-06-04 14:43:16 +02:00
|
|
|
public:
|
2013-03-20 15:45:38 +01:00
|
|
|
explicit HeaderViewStretcher(QHeaderView *headerView, int columnToStretch);
|
2009-06-04 14:43:16 +02:00
|
|
|
|
2016-02-24 17:58:44 +01:00
|
|
|
void stretch();
|
2021-12-08 11:18:22 +01:00
|
|
|
void softStretch();
|
2016-02-24 17:58:44 +01:00
|
|
|
bool eventFilter(QObject *obj, QEvent *ev) override;
|
2009-06-04 14:43:16 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
} // namespace Utils
|