Commit 3ecd6c28 authored by Christoph Cullmann's avatar Christoph Cullmann 🐮
Browse files

show the default settings.json to the user in the config dialog

parent be51b820
......@@ -35,6 +35,12 @@ LSPClientConfigPage::LSPClientConfigPage(QWidget *parent, LSPClientPlugin *plugi
ui = new Ui::LspConfigWidget();
ui->setupUi(this);
// setup default json settings
QFile defaultConfigFile(QStringLiteral(":/lspclient/settings.json"));
defaultConfigFile.open(QIODevice::ReadOnly);
Q_ASSERT(defaultConfigFile.isOpen());
ui->defaultConfig->setPlainText(QString::fromUtf8(defaultConfigFile.readAll()));
reset();
for (const auto &cb : {ui->chkSymbolDetails,
......
......@@ -26,7 +26,7 @@
<item>
<widget class="QTabWidget" name="tabWidget">
<property name="currentIndex">
<number>0</number>
<number>1</number>
</property>
<widget class="QWidget" name="tab">
<attribute name="title">
......@@ -173,7 +173,7 @@
<item>
<widget class="QGroupBox" name="groupBox_3">
<property name="title">
<string>Server Configuration</string>
<string>User Server Configuration</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout_4">
<item>
......@@ -183,17 +183,16 @@
</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>
<widget class="QGroupBox" name="groupBox_4">
<property name="title">
<string>Default Server Configuration</string>
</property>
</spacer>
<layout class="QVBoxLayout" name="verticalLayout_8">
<item>
<widget class="QTextBrowser" name="defaultConfig"/>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment