TextEditor: inline completionsettingspage.ui

Change-Id: I41f9b6376b3478a7a6aa0e96ee1165f9aa94d46e
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
This commit is contained in:
hjk
2022-07-25 15:06:51 +02:00
parent c7f59ec188
commit e9a13d83a4
5 changed files with 230 additions and 578 deletions

View File

@@ -49,7 +49,7 @@ add_qtc_plugin(TextEditor
command.cpp command.h command.cpp command.h
commentssettings.cpp commentssettings.h commentssettings.cpp commentssettings.h
completionsettings.cpp completionsettings.h completionsettings.cpp completionsettings.h
completionsettingspage.cpp completionsettingspage.h completionsettingspage.ui completionsettingspage.cpp completionsettingspage.h
displaysettings.cpp displaysettings.h displaysettings.cpp displaysettings.h
displaysettingspage.cpp displaysettingspage.h displaysettingspage.ui displaysettingspage.cpp displaysettingspage.h displaysettingspage.ui
extraencodingsettings.cpp extraencodingsettings.h extraencodingsettings.cpp extraencodingsettings.h

View File

@@ -27,15 +27,28 @@
#include "texteditorsettings.h" #include "texteditorsettings.h"
#include "texteditorconstants.h" #include "texteditorconstants.h"
#include "ui_completionsettingspage.h"
#include <cppeditor/cpptoolssettings.h> #include <cppeditor/cpptoolssettings.h>
#include <coreplugin/icore.h> #include <coreplugin/icore.h>
#include <QTextStream> #include <utils/layoutbuilder.h>
#include <QApplication>
#include <QCheckBox>
#include <QComboBox>
#include <QFormLayout>
#include <QGridLayout>
#include <QGroupBox>
#include <QHBoxLayout>
#include <QLabel>
#include <QSpacerItem>
#include <QSpinBox>
#include <QVBoxLayout>
#include <QWidget>
using namespace CppEditor; using namespace CppEditor;
using namespace Utils;
namespace TextEditor { namespace TextEditor {
namespace Internal { namespace Internal {
@@ -55,19 +68,132 @@ private:
void settingsFromUi(CompletionSettings &completion, CommentsSettings &comment) const; void settingsFromUi(CompletionSettings &completion, CommentsSettings &comment) const;
CompletionSettingsPage *m_owner = nullptr; CompletionSettingsPage *m_owner = nullptr;
Ui::CompletionSettingsPage m_ui;
QComboBox *m_caseSensitivity;
QComboBox *m_completionTrigger;
QSpinBox *m_thresholdSpinBox;
QSpinBox *m_automaticProposalTimeoutSpinBox;
QCheckBox *m_partiallyComplete;
QCheckBox *m_autoSplitStrings;
QCheckBox *m_insertBrackets;
QCheckBox *m_insertQuotes;
QCheckBox *m_surroundBrackets;
QCheckBox *m_spaceAfterFunctionName;
QCheckBox *m_surroundQuotes;
QCheckBox *m_animateAutoComplete;
QCheckBox *m_highlightAutoComplete;
QCheckBox *m_skipAutoComplete;
QCheckBox *m_removeAutoComplete;
QCheckBox *m_overwriteClosingChars;
QCheckBox *m_enableDoxygenCheckBox;
QCheckBox *m_generateBriefCheckBox;
QCheckBox *m_leadingAsterisksCheckBox;
}; };
CompletionSettingsPageWidget::CompletionSettingsPageWidget(CompletionSettingsPage *owner) CompletionSettingsPageWidget::CompletionSettingsPageWidget(CompletionSettingsPage *owner)
: m_owner(owner) : m_owner(owner)
{ {
m_ui.setupUi(this); resize(823, 756);
connect(m_ui.completionTrigger, QOverload<int>::of(&QComboBox::currentIndexChanged), m_caseSensitivity = new QComboBox;
this, [this] { m_caseSensitivity->addItem(tr("Full"));
m_caseSensitivity->addItem(tr("None"));
m_caseSensitivity->addItem(tr("First Letter"));
auto caseSensitivityLabel = new QLabel(tr("&Case-sensitivity:"));
caseSensitivityLabel->setBuddy(m_caseSensitivity);
m_completionTrigger = new QComboBox;
m_completionTrigger->addItem(tr("Manually"));
m_completionTrigger->addItem(tr("When Triggered"));
m_completionTrigger->addItem(tr("Always"));
auto completionTriggerLabel = new QLabel(tr("Activate completion:"));
auto automaticProposalTimeoutLabel = new QLabel(tr("Timeout in ms:"));
m_automaticProposalTimeoutSpinBox = new QSpinBox;
m_automaticProposalTimeoutSpinBox->setMaximum(2000);
m_automaticProposalTimeoutSpinBox->setSingleStep(50);
m_automaticProposalTimeoutSpinBox->setValue(400);
auto thresholdLabel = new QLabel(tr("Character threshold:"));
m_thresholdSpinBox = new QSpinBox;
m_thresholdSpinBox->setMinimum(1);
m_partiallyComplete = new QCheckBox(tr("Autocomplete common &prefix"));
m_partiallyComplete->setToolTip(tr("Inserts the common prefix of available completion items."));
m_partiallyComplete->setChecked(true);
m_autoSplitStrings = new QCheckBox(tr("Automatically split strings"));
m_autoSplitStrings->setToolTip(
tr("Splits a string into two lines by adding an end quote at the cursor position "
"when you press Enter and a start quote to the next line, before the rest "
"of the string.\n\n"
"In addition, Shift+Enter inserts an escape character at the cursor position "
"and moves the rest of the string to the next line."));
m_insertBrackets = new QCheckBox(tr("Insert opening or closing brackets"));
m_insertBrackets->setChecked(true);
m_insertQuotes = new QCheckBox(tr("Insert closing quote"));
m_insertQuotes->setChecked(true);
m_surroundBrackets = new QCheckBox(tr("Surround text selection with brackets"));
m_surroundBrackets->setChecked(true);
m_surroundBrackets->setToolTip(
tr("When typing a matching bracket and there is a text selection, instead of "
"removing the selection, surrounds it with the corresponding characters."));
m_spaceAfterFunctionName = new QCheckBox(tr("Insert &space after function name"));
m_spaceAfterFunctionName->setEnabled(true);
m_surroundQuotes = new QCheckBox(tr("Surround text selection with quotes"));
m_surroundQuotes->setChecked(true);
m_surroundQuotes->setToolTip(
tr("When typing a matching quote and there is a text selection, instead of "
"removing the selection, surrounds it with the corresponding characters."));
m_animateAutoComplete = new QCheckBox(tr("Animate automatically inserted text"));
m_animateAutoComplete->setChecked(true);
m_animateAutoComplete->setToolTip(tr("Show a visual hint when for example a brace or a quote "
"is automatically inserted by the editor."));
m_highlightAutoComplete = new QCheckBox(tr("Highlight automatically inserted text"));
m_highlightAutoComplete->setChecked(true);
m_skipAutoComplete = new QCheckBox(tr("Skip automatically inserted character when typing"));
m_skipAutoComplete->setToolTip(tr("Skip automatically inserted character if re-typed manually "
"after completion or by pressing tab."));
m_skipAutoComplete->setChecked(true);
m_removeAutoComplete = new QCheckBox(tr("Remove automatically inserted text on backspace"));
m_removeAutoComplete->setChecked(true);
m_removeAutoComplete->setToolTip(tr("Remove the automatically inserted character if the trigger "
"is deleted by backspace after the completion."));
m_overwriteClosingChars = new QCheckBox(tr("Overwrite closing punctuation"));
m_overwriteClosingChars->setToolTip(tr("Automatically overwrite closing parentheses and quotes."));
m_enableDoxygenCheckBox = new QCheckBox(tr("Enable Doxygen blocks"));
m_enableDoxygenCheckBox->setToolTip(tr("Automatically creates a Doxygen comment upon pressing "
"enter after a '/**', '/*!', '//!' or '///'."));
m_generateBriefCheckBox = new QCheckBox(tr("Generate brief description"));
m_generateBriefCheckBox->setToolTip(tr("Generates a <i>brief</i> command with an initial "
"description for the corresponding declaration."));
m_leadingAsterisksCheckBox = new QCheckBox(tr("Add leading asterisks"));
m_leadingAsterisksCheckBox->setToolTip(
tr("Adds leading asterisks when continuing C/C++ \"/*\", Qt \"/*!\" "
"and Java \"/**\" style comments on new lines."));
connect(m_completionTrigger, &QComboBox::currentIndexChanged,
this, [this, automaticProposalTimeoutLabel] {
const bool enableTimeoutWidgets = completionTrigger() == AutomaticCompletion; const bool enableTimeoutWidgets = completionTrigger() == AutomaticCompletion;
m_ui.automaticProposalTimeoutLabel->setEnabled(enableTimeoutWidgets); automaticProposalTimeoutLabel->setEnabled(enableTimeoutWidgets);
m_ui.automaticProposalTimeoutSpinBox->setEnabled(enableTimeoutWidgets); m_automaticProposalTimeoutSpinBox->setEnabled(enableTimeoutWidgets);
}); });
int caseSensitivityIndex = 0; int caseSensitivityIndex = 0;
@@ -96,31 +222,81 @@ CompletionSettingsPageWidget::CompletionSettingsPageWidget(CompletionSettingsPag
break; break;
} }
m_ui.caseSensitivity->setCurrentIndex(caseSensitivityIndex); m_caseSensitivity->setCurrentIndex(caseSensitivityIndex);
m_ui.completionTrigger->setCurrentIndex(completionTriggerIndex); m_completionTrigger->setCurrentIndex(completionTriggerIndex);
m_ui.automaticProposalTimeoutSpinBox m_automaticProposalTimeoutSpinBox
->setValue(m_owner->m_completionSettings.m_automaticProposalTimeoutInMs); ->setValue(m_owner->m_completionSettings.m_automaticProposalTimeoutInMs);
m_ui.thresholdSpinBox->setValue(m_owner->m_completionSettings.m_characterThreshold); m_thresholdSpinBox->setValue(m_owner->m_completionSettings.m_characterThreshold);
m_ui.insertBrackets->setChecked(m_owner->m_completionSettings.m_autoInsertBrackets); m_insertBrackets->setChecked(m_owner->m_completionSettings.m_autoInsertBrackets);
m_ui.surroundBrackets->setChecked(m_owner->m_completionSettings.m_surroundingAutoBrackets); m_surroundBrackets->setChecked(m_owner->m_completionSettings.m_surroundingAutoBrackets);
m_ui.insertQuotes->setChecked(m_owner->m_completionSettings.m_autoInsertQuotes); m_insertQuotes->setChecked(m_owner->m_completionSettings.m_autoInsertQuotes);
m_ui.surroundQuotes->setChecked(m_owner->m_completionSettings.m_surroundingAutoQuotes); m_surroundQuotes->setChecked(m_owner->m_completionSettings.m_surroundingAutoQuotes);
m_ui.partiallyComplete->setChecked(m_owner->m_completionSettings.m_partiallyComplete); m_partiallyComplete->setChecked(m_owner->m_completionSettings.m_partiallyComplete);
m_ui.spaceAfterFunctionName->setChecked(m_owner->m_completionSettings.m_spaceAfterFunctionName); m_spaceAfterFunctionName->setChecked(m_owner->m_completionSettings.m_spaceAfterFunctionName);
m_ui.autoSplitStrings->setChecked(m_owner->m_completionSettings.m_autoSplitStrings); m_autoSplitStrings->setChecked(m_owner->m_completionSettings.m_autoSplitStrings);
m_ui.animateAutoComplete->setChecked(m_owner->m_completionSettings.m_animateAutoComplete); m_animateAutoComplete->setChecked(m_owner->m_completionSettings.m_animateAutoComplete);
m_ui.overwriteClosingChars->setChecked(m_owner->m_completionSettings.m_overwriteClosingChars); m_overwriteClosingChars->setChecked(m_owner->m_completionSettings.m_overwriteClosingChars);
m_ui.highlightAutoComplete->setChecked(m_owner->m_completionSettings.m_highlightAutoComplete); m_highlightAutoComplete->setChecked(m_owner->m_completionSettings.m_highlightAutoComplete);
m_ui.skipAutoComplete->setChecked(m_owner->m_completionSettings.m_skipAutoCompletedText); m_skipAutoComplete->setChecked(m_owner->m_completionSettings.m_skipAutoCompletedText);
m_ui.removeAutoComplete->setChecked(m_owner->m_completionSettings.m_autoRemove); m_removeAutoComplete->setChecked(m_owner->m_completionSettings.m_autoRemove);
m_ui.enableDoxygenCheckBox->setChecked(m_owner->m_commentsSettings.m_enableDoxygen); m_enableDoxygenCheckBox->setChecked(m_owner->m_commentsSettings.m_enableDoxygen);
m_ui.generateBriefCheckBox->setChecked(m_owner->m_commentsSettings.m_generateBrief); m_generateBriefCheckBox->setChecked(m_owner->m_commentsSettings.m_generateBrief);
m_ui.leadingAsterisksCheckBox->setChecked(m_owner->m_commentsSettings.m_leadingAsterisks); m_leadingAsterisksCheckBox->setChecked(m_owner->m_commentsSettings.m_leadingAsterisks);
m_ui.generateBriefCheckBox->setEnabled(m_ui.enableDoxygenCheckBox->isChecked()); m_generateBriefCheckBox->setEnabled(m_enableDoxygenCheckBox->isChecked());
m_ui.skipAutoComplete->setEnabled(m_ui.highlightAutoComplete->isChecked()); m_skipAutoComplete->setEnabled(m_highlightAutoComplete->isChecked());
m_ui.removeAutoComplete->setEnabled(m_ui.highlightAutoComplete->isChecked()); m_removeAutoComplete->setEnabled(m_highlightAutoComplete->isChecked());
using namespace Layouting;
auto indent = [](QWidget *widget) { return Row { Space(30), widget }; };
Column {
Group {
title(tr("Behavior")),
Form {
caseSensitivityLabel, m_caseSensitivity, st, br,
completionTriggerLabel, m_completionTrigger, st, br,
automaticProposalTimeoutLabel, m_automaticProposalTimeoutSpinBox, st, br,
thresholdLabel, m_thresholdSpinBox, st, br,
Span(2, m_partiallyComplete), br,
Span(2, m_autoSplitStrings), br,
}
},
Group {
title(tr("&Automatically insert matching characters")),
Row {
Column {
m_insertBrackets,
m_surroundBrackets,
m_spaceAfterFunctionName,
m_highlightAutoComplete,
indent(m_skipAutoComplete),
indent(m_removeAutoComplete)
},
Column {
m_insertQuotes,
m_surroundQuotes,
m_animateAutoComplete,
m_overwriteClosingChars,
st,
}
}
},
Group {
title(tr("Documentation Comments")),
Column {
m_enableDoxygenCheckBox,
indent(m_generateBriefCheckBox),
m_leadingAsterisksCheckBox
}
},
st
}.attachTo(this);
connect(m_enableDoxygenCheckBox, &QCheckBox::toggled, m_generateBriefCheckBox, &QCheckBox::setEnabled);
connect(m_highlightAutoComplete, &QCheckBox::toggled, m_skipAutoComplete, &QCheckBox::setEnabled);
connect(m_highlightAutoComplete, &QCheckBox::toggled, m_removeAutoComplete, &QCheckBox::setEnabled);
} }
void CompletionSettingsPageWidget::apply() void CompletionSettingsPageWidget::apply()
@@ -145,7 +321,7 @@ void CompletionSettingsPageWidget::apply()
CaseSensitivity CompletionSettingsPageWidget::caseSensitivity() const CaseSensitivity CompletionSettingsPageWidget::caseSensitivity() const
{ {
switch (m_ui.caseSensitivity->currentIndex()) { switch (m_caseSensitivity->currentIndex()) {
case 0: // Full case 0: // Full
return TextEditor::CaseSensitive; return TextEditor::CaseSensitive;
case 1: // None case 1: // None
@@ -157,7 +333,7 @@ CaseSensitivity CompletionSettingsPageWidget::caseSensitivity() const
CompletionTrigger CompletionSettingsPageWidget::completionTrigger() const CompletionTrigger CompletionSettingsPageWidget::completionTrigger() const
{ {
switch (m_ui.completionTrigger->currentIndex()) { switch (m_completionTrigger->currentIndex()) {
case 0: case 0:
return TextEditor::ManualCompletion; return TextEditor::ManualCompletion;
case 1: case 1:
@@ -173,32 +349,32 @@ void CompletionSettingsPageWidget::settingsFromUi(CompletionSettings &completion
completion.m_caseSensitivity = caseSensitivity(); completion.m_caseSensitivity = caseSensitivity();
completion.m_completionTrigger = completionTrigger(); completion.m_completionTrigger = completionTrigger();
completion.m_automaticProposalTimeoutInMs completion.m_automaticProposalTimeoutInMs
= m_ui.automaticProposalTimeoutSpinBox->value(); = m_automaticProposalTimeoutSpinBox->value();
completion.m_characterThreshold = m_ui.thresholdSpinBox->value(); completion.m_characterThreshold = m_thresholdSpinBox->value();
completion.m_autoInsertBrackets = m_ui.insertBrackets->isChecked(); completion.m_autoInsertBrackets = m_insertBrackets->isChecked();
completion.m_surroundingAutoBrackets = m_ui.surroundBrackets->isChecked(); completion.m_surroundingAutoBrackets = m_surroundBrackets->isChecked();
completion.m_autoInsertQuotes = m_ui.insertQuotes->isChecked(); completion.m_autoInsertQuotes = m_insertQuotes->isChecked();
completion.m_surroundingAutoQuotes = m_ui.surroundQuotes->isChecked(); completion.m_surroundingAutoQuotes = m_surroundQuotes->isChecked();
completion.m_partiallyComplete = m_ui.partiallyComplete->isChecked(); completion.m_partiallyComplete = m_partiallyComplete->isChecked();
completion.m_spaceAfterFunctionName = m_ui.spaceAfterFunctionName->isChecked(); completion.m_spaceAfterFunctionName = m_spaceAfterFunctionName->isChecked();
completion.m_autoSplitStrings = m_ui.autoSplitStrings->isChecked(); completion.m_autoSplitStrings = m_autoSplitStrings->isChecked();
completion.m_animateAutoComplete = m_ui.animateAutoComplete->isChecked(); completion.m_animateAutoComplete = m_animateAutoComplete->isChecked();
completion.m_overwriteClosingChars = m_ui.overwriteClosingChars->isChecked(); completion.m_overwriteClosingChars = m_overwriteClosingChars->isChecked();
completion.m_highlightAutoComplete = m_ui.highlightAutoComplete->isChecked(); completion.m_highlightAutoComplete = m_highlightAutoComplete->isChecked();
completion.m_skipAutoCompletedText = m_ui.skipAutoComplete->isChecked(); completion.m_skipAutoCompletedText = m_skipAutoComplete->isChecked();
completion.m_autoRemove = m_ui.removeAutoComplete->isChecked(); completion.m_autoRemove = m_removeAutoComplete->isChecked();
comment.m_enableDoxygen = m_ui.enableDoxygenCheckBox->isChecked(); comment.m_enableDoxygen = m_enableDoxygenCheckBox->isChecked();
comment.m_generateBrief = m_ui.generateBriefCheckBox->isChecked(); comment.m_generateBrief = m_generateBriefCheckBox->isChecked();
comment.m_leadingAsterisks = m_ui.leadingAsterisksCheckBox->isChecked(); comment.m_leadingAsterisks = m_leadingAsterisksCheckBox->isChecked();
} }
const CompletionSettings &CompletionSettingsPage::completionSettings() const CompletionSettings &CompletionSettingsPage::completionSettings() const
{ {
return m_completionSettings; return m_completionSettings;
} }
const CommentsSettings &CompletionSettingsPage::commentsSettings() const CommentsSettings &CompletionSettingsPage::commentsSettings() const
{ {
return m_commentsSettings; return m_commentsSettings;
} }

View File

@@ -38,8 +38,8 @@ class CompletionSettingsPage : public Core::IOptionsPage
public: public:
CompletionSettingsPage(); CompletionSettingsPage();
const CompletionSettings & completionSettings(); const CompletionSettings &completionSettings() const;
const CommentsSettings & commentsSettings(); const CommentsSettings &commentsSettings() const;
private: private:
friend class CompletionSettingsPageWidget; friend class CompletionSettingsPageWidget;

View File

@@ -1,523 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>TextEditor::Internal::CompletionSettingsPage</class>
<widget class="QWidget" name="TextEditor::Internal::CompletionSettingsPage">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>823</width>
<height>756</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
<widget class="QGroupBox" name="groupBox">
<property name="title">
<string>Behavior</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_3">
<item>
<layout class="QFormLayout" name="formLayout">
<item row="0" column="0">
<widget class="QLabel" name="caseSensitivityLabel">
<property name="text">
<string>&amp;Case-sensitivity:</string>
</property>
<property name="buddy">
<cstring>caseSensitivity</cstring>
</property>
</widget>
</item>
<item row="0" column="1">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QComboBox" name="caseSensitivity">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<item>
<property name="text">
<string>Full</string>
</property>
</item>
<item>
<property name="text">
<string>None</string>
</property>
</item>
<item>
<property name="text">
<string>First Letter</string>
</property>
</item>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="completionTriggerLabel">
<property name="text">
<string>Activate completion:</string>
</property>
</widget>
</item>
<item row="1" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QComboBox" name="completionTrigger">
<item>
<property name="text">
<string>Manually</string>
</property>
</item>
<item>
<property name="text">
<string>When Triggered</string>
</property>
</item>
<item>
<property name="text">
<string>Always</string>
</property>
</item>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="2" column="0">
<widget class="QLabel" name="automaticProposalTimeoutLabel">
<property name="text">
<string>Timeout in ms:</string>
</property>
</widget>
</item>
<item row="2" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="QSpinBox" name="automaticProposalTimeoutSpinBox">
<property name="maximum">
<number>2000</number>
</property>
<property name="singleStep">
<number>50</number>
</property>
<property name="value">
<number>400</number>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_3">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="3" column="0">
<widget class="QLabel" name="thresholdLabel">
<property name="text">
<string>Character threshold:</string>
</property>
</widget>
</item>
<item row="3" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_6">
<item>
<widget class="QSpinBox" name="thresholdSpinBox">
<property name="minimum">
<number>1</number>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_4">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="4" column="0">
<widget class="QCheckBox" name="partiallyComplete">
<property name="toolTip">
<string>Inserts the common prefix of available completion items.</string>
</property>
<property name="text">
<string>Autocomplete common &amp;prefix</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QCheckBox" name="autoSplitStrings">
<property name="toolTip">
<string>Splits a string into two lines by adding an end quote at the cursor position when you press Enter and a start quote to the next line, before the rest of the string.
In addition, Shift+Enter inserts an escape character at the cursor position and moves the rest of the string to the next line.</string>
</property>
<property name="text">
<string>Automatically split strings</string>
</property>
</widget>
</item>
</layout>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="autoInsertGroupBox">
<property name="title">
<string>&amp;Automatically insert matching characters</string>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<widget class="QCheckBox" name="insertBrackets">
<property name="text">
<string>Insert opening or closing brackets</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QCheckBox" name="insertQuotes">
<property name="text">
<string>Insert closing quote</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QCheckBox" name="surroundBrackets">
<property name="toolTip">
<string>When typing a matching bracket and there is a text selection, instead of removing the selection, surrounds it with the corresponding characters.</string>
</property>
<property name="text">
<string>Surround text selection with brackets</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QCheckBox" name="spaceAfterFunctionName">
<property name="enabled">
<bool>true</bool>
</property>
<property name="text">
<string>Insert &amp;space after function name</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="surroundQuotes">
<property name="toolTip">
<string>When typing a matching quote and there is a text selection, instead of removing the selection, surrounds it with the corresponding characters.</string>
</property>
<property name="text">
<string>Surround text selection with quotes</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QCheckBox" name="animateAutoComplete">
<property name="toolTip">
<string>Show a visual hint when for example a brace or a quote is automatically inserted by the editor.</string>
</property>
<property name="text">
<string>Animate automatically inserted text</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QCheckBox" name="highlightAutoComplete">
<property name="text">
<string>Highlight automatically inserted text</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="0">
<layout class="QHBoxLayout" name="horizontalLayout_3">
<item>
<spacer name="horizontalSpacer_6">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>30</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QCheckBox" name="skipAutoComplete">
<property name="toolTip">
<string>Skip automatically inserted character if re-typed manually after completion or by pressing tab.</string>
</property>
<property name="text">
<string>Skip automatically inserted character when typing</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="5" column="0">
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<spacer name="horizontalSpacer_7">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>30</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QCheckBox" name="removeAutoComplete">
<property name="toolTip">
<string>Remove the automatically inserted character if the trigger is deleted by backspace after the completion.</string>
</property>
<property name="text">
<string>Remove automatically inserted text on backspace</string>
</property>
<property name="checked">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="3" column="1">
<widget class="QCheckBox" name="overwriteClosingChars">
<property name="toolTip">
<string>Automatically overwrite closing parentheses and quotes.</string>
</property>
<property name="text">
<string>Overwrite closing punctuation</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<widget class="QGroupBox" name="docCommentsGroup">
<property name="title">
<string>Documentation Comments</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<widget class="QCheckBox" name="enableDoxygenCheckBox">
<property name="toolTip">
<string>Automatically creates a Doxygen comment upon pressing enter after a '/**', '/*!', '//!' or '///'.</string>
</property>
<property name="text">
<string>Enable Doxygen blocks</string>
</property>
</widget>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_4">
<item>
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>30</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QCheckBox" name="generateBriefCheckBox">
<property name="toolTip">
<string>Generates a &lt;i&gt;brief&lt;/i&gt; command with an initial description for the corresponding declaration.</string>
</property>
<property name="text">
<string>Generate brief description</string>
</property>
</widget>
</item>
</layout>
</item>
<item>
<widget class="QCheckBox" name="leadingAsterisksCheckBox">
<property name="toolTip">
<string>Adds leading asterisks when continuing C/C++ &quot;/*&quot;, Qt &quot;/*!&quot; and Java &quot;/**&quot; style comments on new lines.</string>
</property>
<property name="text">
<string>Add leading asterisks</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item>
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<tabstops>
<tabstop>caseSensitivity</tabstop>
<tabstop>completionTrigger</tabstop>
<tabstop>automaticProposalTimeoutSpinBox</tabstop>
<tabstop>partiallyComplete</tabstop>
<tabstop>autoSplitStrings</tabstop>
<tabstop>insertBrackets</tabstop>
<tabstop>insertQuotes</tabstop>
<tabstop>surroundBrackets</tabstop>
<tabstop>surroundQuotes</tabstop>
<tabstop>spaceAfterFunctionName</tabstop>
<tabstop>animateAutoComplete</tabstop>
<tabstop>highlightAutoComplete</tabstop>
<tabstop>skipAutoComplete</tabstop>
<tabstop>removeAutoComplete</tabstop>
<tabstop>enableDoxygenCheckBox</tabstop>
<tabstop>generateBriefCheckBox</tabstop>
<tabstop>leadingAsterisksCheckBox</tabstop>
</tabstops>
<resources/>
<connections>
<connection>
<sender>enableDoxygenCheckBox</sender>
<signal>toggled(bool)</signal>
<receiver>generateBriefCheckBox</receiver>
<slot>setEnabled(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>216</x>
<y>411</y>
</hint>
<hint type="destinationlabel">
<x>378</x>
<y>438</y>
</hint>
</hints>
</connection>
<connection>
<sender>highlightAutoComplete</sender>
<signal>toggled(bool)</signal>
<receiver>skipAutoComplete</receiver>
<slot>setEnabled(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>176</x>
<y>277</y>
</hint>
<hint type="destinationlabel">
<x>186</x>
<y>306</y>
</hint>
</hints>
</connection>
<connection>
<sender>highlightAutoComplete</sender>
<signal>toggled(bool)</signal>
<receiver>removeAutoComplete</receiver>
<slot>setEnabled(bool)</slot>
<hints>
<hint type="sourcelabel">
<x>223</x>
<y>275</y>
</hint>
<hint type="destinationlabel">
<x>226</x>
<y>333</y>
</hint>
</hints>
</connection>
</connections>
</ui>

View File

@@ -58,7 +58,6 @@ Project {
"completionsettings.h", "completionsettings.h",
"completionsettingspage.cpp", "completionsettingspage.cpp",
"completionsettingspage.h", "completionsettingspage.h",
"completionsettingspage.ui",
"displaysettings.cpp", "displaysettings.cpp",
"displaysettings.h", "displaysettings.h",
"displaysettingspage.cpp", "displaysettingspage.cpp",