forked from qt-creator/qt-creator
Replace the current license disclaimer in files by a SPDX-License-Identifier. Task-number: QTBUG-67283 Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
54 lines
1.2 KiB
C++
54 lines
1.2 KiB
C++
// Copyright (C) 2016 The Qt Company Ltd.
|
|
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0+ OR GPL-3.0 WITH Qt-GPL-exception-1.0
|
|
|
|
#pragma once
|
|
|
|
#include "texteditor_global.h"
|
|
|
|
#include <QGroupBox>
|
|
|
|
QT_BEGIN_NAMESPACE
|
|
class QComboBox;
|
|
class QLabel;
|
|
class QSpinBox;
|
|
QT_END_NAMESPACE
|
|
|
|
namespace TextEditor {
|
|
|
|
class TabSettings;
|
|
|
|
class TEXTEDITOR_EXPORT TabSettingsWidget : public QGroupBox
|
|
{
|
|
Q_OBJECT
|
|
|
|
public:
|
|
enum CodingStyleLink {
|
|
CppLink,
|
|
QtQuickLink
|
|
};
|
|
|
|
explicit TabSettingsWidget(QWidget *parent = nullptr);
|
|
~TabSettingsWidget() override;
|
|
|
|
TabSettings tabSettings() const;
|
|
|
|
void setCodingStyleWarningVisible(bool visible);
|
|
void setTabSettings(const TextEditor::TabSettings& s);
|
|
|
|
signals:
|
|
void settingsChanged(const TextEditor::TabSettings &);
|
|
void codingStyleLinkClicked(TextEditor::TabSettingsWidget::CodingStyleLink link);
|
|
|
|
private:
|
|
void slotSettingsChanged();
|
|
void codingStyleLinkActivated(const QString &linkString);
|
|
|
|
QLabel *m_codingStyleWarning;
|
|
QComboBox *m_tabPolicy;
|
|
QSpinBox *m_tabSize;
|
|
QSpinBox *m_indentSize;
|
|
QComboBox *m_continuationAlignBehavior;
|
|
};
|
|
|
|
} // namespace TextEditor
|