Before Width: | Height: | Size: 472 B |
Before Width: | Height: | Size: 995 B After Width: | Height: | Size: 995 B |
Before Width: | Height: | Size: 1.5 KiB After Width: | Height: | Size: 1.5 KiB |
Before Width: | Height: | Size: 545 B After Width: | Height: | Size: 545 B |
Before Width: | Height: | Size: 496 B After Width: | Height: | Size: 496 B |
Before Width: | Height: | Size: 545 B After Width: | Height: | Size: 545 B |
Before Width: | Height: | Size: 420 B After Width: | Height: | Size: 420 B |
Before Width: | Height: | Size: 420 B After Width: | Height: | Size: 420 B |
Before Width: | Height: | Size: 446 B After Width: | Height: | Size: 446 B |
Before Width: | Height: | Size: 465 B After Width: | Height: | Size: 465 B |
@ -1,114 +1,114 @@
|
||||
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
|
||||
<class>AboutDialogBase</class>
|
||||
<widget class="TQDialog">
|
||||
<class>AboutDialogBase</class>
|
||||
<widget class="TQDialog">
|
||||
<property name="name">
|
||||
<cstring>AboutDialogBase</cstring>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>588</width>
|
||||
<height>512</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>0</hsizetype>
|
||||
<vsizetype>5</vsizetype>
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>588</width>
|
||||
<height>333</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="caption">
|
||||
<string>About UniversalIndentGUI</string>
|
||||
</property>
|
||||
<vbox>
|
||||
<property name="margin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQFrame">
|
||||
<property name="name">
|
||||
<cstring>frame</cstring>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>StyledPanel</enum>
|
||||
</property>
|
||||
<vbox>
|
||||
<widget class="TQLabel">
|
||||
<property name="name">
|
||||
<cstring>bannerLabel</cstring>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>0</hsizetype>
|
||||
<vsizetype>0</vsizetype>
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>570</width>
|
||||
<height>87</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>570</width>
|
||||
<height>87</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string></string>
|
||||
</property>
|
||||
</widget>
|
||||
<hbox>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer1</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>okButton</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer2</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</widget>
|
||||
</vbox>
|
||||
</widget>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>588</width>
|
||||
<height>512</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>0</hsizetype>
|
||||
<vsizetype>5</vsizetype>
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>588</width>
|
||||
<height>333</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="caption">
|
||||
<string>About UniversalIndentGUI</string>
|
||||
</property>
|
||||
<vbox>
|
||||
<property name="margin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQFrame">
|
||||
<property name="name">
|
||||
<cstring>frame</cstring>
|
||||
</property>
|
||||
<property name="frameShape">
|
||||
<enum>StyledPanel</enum>
|
||||
</property>
|
||||
<vbox>
|
||||
<widget class="TQLabel">
|
||||
<property name="name">
|
||||
<cstring>bannerLabel</cstring>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>0</hsizetype>
|
||||
<vsizetype>0</vsizetype>
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>570</width>
|
||||
<height>87</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="maximumSize">
|
||||
<size>
|
||||
<width>570</width>
|
||||
<height>87</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string></string>
|
||||
</property>
|
||||
</widget>
|
||||
<hbox>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer1</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>okButton</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>OK</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer2</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</widget>
|
||||
</vbox>
|
||||
</widget>
|
||||
</UI>
|
||||
|
@ -1,116 +1,116 @@
|
||||
<!DOCTYPE UI><UI version="3.2" stdsetdef="1">
|
||||
<class>ToolBarWidget</class>
|
||||
<widget class="TQWidget">
|
||||
<property name="name">
|
||||
<cstring>ToolBarWidget</cstring>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>773</width>
|
||||
<height>34</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="caption">
|
||||
<string>Form</string>
|
||||
</property>
|
||||
<hbox>
|
||||
<property name="name">
|
||||
<cstring>unnamed</cstring>
|
||||
</property>
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbOpenSourceFile</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Open Source File </string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Opens a dialog for selecting a source code file</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbLivePreview</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Live Indent Preview</string>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Turns the preview of the reformatted source code on and off</string>
|
||||
</property>
|
||||
<property name="accel">
|
||||
<string>Ctrl+L</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbEnableSyntaxHL</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Syntax Highlight</string>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Enables and disables the highlighting of the source</string>
|
||||
</property>
|
||||
<property name="accel">
|
||||
<string>Ctrl+H</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer1</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>2000</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>5</hsizetype>
|
||||
<vsizetype>5</vsizetype>
|
||||
<horstretch>1</horstretch>
|
||||
<verstretch>1</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
</spacer>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbAbout</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>About</string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Shows info about UniversalIndentGUI</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbExit</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Exit</string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Quits UniversalIndentGUI</string>
|
||||
</property>
|
||||
</widget>
|
||||
</hbox>
|
||||
</widget>
|
||||
<class>ToolBarWidget</class>
|
||||
<widget class="TQWidget">
|
||||
<property name="name">
|
||||
<cstring>ToolBarWidget</cstring>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>773</width>
|
||||
<height>34</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="caption">
|
||||
<string>Form</string>
|
||||
</property>
|
||||
<hbox>
|
||||
<property name="name">
|
||||
<cstring>unnamed</cstring>
|
||||
</property>
|
||||
<property name="spacing">
|
||||
<number>6</number>
|
||||
</property>
|
||||
<property name="margin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbOpenSourceFile</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Open Source File </string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Opens a dialog for selecting a source code file</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbLivePreview</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Live Indent Preview</string>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Turns the preview of the reformatted source code on and off</string>
|
||||
</property>
|
||||
<property name="accel">
|
||||
<string>Ctrl+L</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbEnableSyntaxHL</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Syntax Highlight</string>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Enables and disables the highlighting of the source</string>
|
||||
</property>
|
||||
<property name="accel">
|
||||
<string>Ctrl+H</string>
|
||||
</property>
|
||||
<property name="checked">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer1</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>2000</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy>
|
||||
<hsizetype>5</hsizetype>
|
||||
<vsizetype>5</vsizetype>
|
||||
<horstretch>1</horstretch>
|
||||
<verstretch>1</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
</spacer>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbAbout</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>About</string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Shows info about UniversalIndentGUI</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>pbExit</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Exit</string>
|
||||
</property>
|
||||
<property name="toolTip" stdset="0">
|
||||
<string>Quits UniversalIndentGUI</string>
|
||||
</property>
|
||||
</widget>
|
||||
</hbox>
|
||||
</widget>
|
||||
</UI>
|
||||
|
@ -0,0 +1,218 @@
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2006-2012 by Thomas Schweitzer *
|
||||
* thomas-schweitzer(at)arcor.de *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License version 2.0 as *
|
||||
* published by the Free Software Foundation. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program in the file LICENSE.GPL; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#include "UiGuiSettingsDialog.h"
|
||||
#include "UiGuiSettings.h"
|
||||
|
||||
#include <tqcheckbox.h>
|
||||
#include <tqcombobox.h>
|
||||
#include <tqpixmap.h>
|
||||
#include <tqspinbox.h>
|
||||
#include <tqtabwidget.h>
|
||||
|
||||
/*
|
||||
\class UiGuiSettingsDialog
|
||||
\ingroup grp_Settings
|
||||
\brief Displays a dialog window with settings for UniversalIndentGUI
|
||||
*/
|
||||
|
||||
/*
|
||||
\brief The constructor calls the setup function for the ui created by uic.
|
||||
*/
|
||||
UiGuiSettingsDialog::UiGuiSettingsDialog(TQWidget *parent, UiGuiSettings *settings) :
|
||||
UiGuiSettingsDialogBase(parent)
|
||||
{
|
||||
// Remember pointer to the UiGuiSettings object.
|
||||
m_settings = settings;
|
||||
|
||||
// For icon setup
|
||||
const TQString ICONS_PATH(APP_ICONS_PATH);
|
||||
// Application icon
|
||||
setIcon(TQPixmap(ICONS_PATH + "preferences-system.png"));
|
||||
|
||||
tabWidget->setTabIconSet(tabCommon, TQPixmap(ICONS_PATH + "applications-system.png"));
|
||||
tabWidget->setTabIconSet(tabEditor, TQPixmap(ICONS_PATH + "accessories-text-editor.png"));
|
||||
tabWidget->setTabIconSet(tabSyntaxHighlight, TQPixmap(ICONS_PATH + "syntax-highlight.png"));
|
||||
|
||||
// Init the language selection combobox.
|
||||
initTranslationSelection();
|
||||
}
|
||||
|
||||
/*
|
||||
\brief By calling this function the combobox for selecting the application language will
|
||||
be initialized.
|
||||
|
||||
Also the translation itself will be reinitialized.
|
||||
*/
|
||||
void UiGuiSettingsDialog::initTranslationSelection()
|
||||
{
|
||||
// For icon setup
|
||||
const TQString ICONS_PATH(APP_ICONS_PATH);
|
||||
|
||||
// First empty the combo box.
|
||||
cmbBoxLanguageSelection->clear();
|
||||
|
||||
// Now add an entry into the box for every language short.
|
||||
for (const TQString &languageShort : m_settings->getAvailableTranslations())
|
||||
{
|
||||
// Identify the language mnemonic and set the full name.
|
||||
if (languageShort == "en")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-en.png"), tr("English"));
|
||||
}
|
||||
else if (languageShort == "fr")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-fr.png"), tr("French"));
|
||||
}
|
||||
else if (languageShort == "de")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-de.png"), tr("German"));
|
||||
}
|
||||
else if (languageShort == "zh_TW")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-zh_TW.png"),
|
||||
tr("Chinese (Taiwan)"));
|
||||
}
|
||||
else if (languageShort == "ja")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-ja.png"), tr("Japanese"));
|
||||
}
|
||||
else if (languageShort == "ru")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-ru.png"), tr("Russian"));
|
||||
}
|
||||
else if (languageShort == "uk")
|
||||
{
|
||||
cmbBoxLanguageSelection->insertItem(TQPixmap(ICONS_PATH + "language-uk.png"), tr("Ukrainian"));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
\brief Displays the dialog by calling the dialogs exec function.
|
||||
|
||||
Before it gets all the values needed from the UiGuiSettings object.
|
||||
*/
|
||||
void UiGuiSettingsDialog::showDialog()
|
||||
{
|
||||
// Init all settings dialog objects with values from settings.
|
||||
cbLoadLastOpenedFileOnStartup->setChecked(
|
||||
m_settings->getValueByName("LoadLastOpenedFileOnStartup").toBool());
|
||||
cbEnableIndenterParameterTooltips->setChecked(
|
||||
m_settings->getValueByName("IndenterParameterTooltipsEnabled").toBool());
|
||||
cbWhiteSpaceIsVisible->setChecked(
|
||||
m_settings->getValueByName("WhiteSpaceIsVisible").toBool());
|
||||
cbEnableSyntaxHL->setChecked(
|
||||
m_settings->getValueByName("SyntaxHighlightingEnabled").toBool());
|
||||
sbRecentlyOpenedListSize->setValue(m_settings->getValueByName("RecentlyOpenedListSize").toInt());
|
||||
sbTabWidth->setValue(m_settings->getValueByName("TabWidth").toInt());
|
||||
|
||||
// Execute the dialog.
|
||||
if (exec() == TQDialog::Accepted)
|
||||
{
|
||||
updateSettings();
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
\brief This slot is called when the dialog box is closed by pressing the Ok button.
|
||||
|
||||
Writes all settings to the UiGuiSettings object.
|
||||
*/
|
||||
void UiGuiSettingsDialog::updateSettings()
|
||||
{
|
||||
m_settings->setValueByName("LoadLastOpenedFileOnStartup",
|
||||
cbLoadLastOpenedFileOnStartup->isChecked());
|
||||
m_settings->setValueByName("IndenterParameterTooltipsEnabled",
|
||||
cbEnableIndenterParameterTooltips->isChecked());
|
||||
m_settings->setValueByName("RecentlyOpenedListSize", sbRecentlyOpenedListSize->value());
|
||||
m_settings->setValueByName("WhiteSpaceIsVisible", cbWhiteSpaceIsVisible->isChecked());
|
||||
m_settings->setValueByName("TabWidth", sbTabWidth->value());
|
||||
m_settings->setValueByName("SyntaxHighlightingEnabled", cbEnableSyntaxHL->isChecked());
|
||||
}
|
||||
|
||||
//--- /*
|
||||
//--- \brief Catches language change events and retranslates all needed widgets.
|
||||
//--- */
|
||||
//--- void UiGuiSettingsDialog::changeEvent(TQEvent *event)
|
||||
//--- {
|
||||
//--- if (event->type() == TQEvent::LanguageChange)
|
||||
//--- {
|
||||
//--- retranslateUi(this);
|
||||
//--- // If this is not explicit set here, TQt < 4.3.0 does not translate the buttons.
|
||||
//--- buttonBox->setStandardButtons(
|
||||
//--- TQDialogButtonBox::Cancel | TQDialogButtonBox::NoButton | TQDialogButtonBox::Ok);
|
||||
//---
|
||||
//--- //TODO: This has to be removed when the properties for the highlighters can be set.
|
||||
//--- groupBoxSyntaxHighlighterProperties->setToolTip(
|
||||
//--- "(Will be implemented soon)" +
|
||||
//--- groupBoxSyntaxHighlighterProperties->toolTip());
|
||||
//---
|
||||
//--- TQStringList languageShortList = _settings->getAvailableTranslations();
|
||||
//---
|
||||
//--- // Now retranslate every entry in the language selection box.
|
||||
//--- for (int i = 0; i < languageShortList.size(); i++)
|
||||
//--- {
|
||||
//--- TQString languageShort = languageShortList.at(i);
|
||||
//---
|
||||
//--- // Identify the language mnemonic and set the full name.
|
||||
//--- if (languageShort == "en")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("English"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "fr")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("French"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "de")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("German"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "zh_TW")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("Chinese (Taiwan)"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "ja")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("Japanese"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "ru")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("Russian"));
|
||||
//--- }
|
||||
//--- else if (languageShort == "uk")
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i, tr("Ukrainian"));
|
||||
//--- }
|
||||
//--- else
|
||||
//--- {
|
||||
//--- cmbBoxLanguageSelection->setItemText(i,
|
||||
//--- tr("Unknown language mnemonic ") + languageShort);
|
||||
//--- }
|
||||
//--- }
|
||||
//--- }
|
||||
//--- else
|
||||
//--- {
|
||||
//--- TQWidget::changeEvent(event);
|
||||
//--- }
|
||||
//--- }
|
||||
|
||||
#include "UiGuiSettingsDialog.moc"
|
@ -0,0 +1,338 @@
|
||||
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
|
||||
<class>UiGuiSettingsDialogBase</class>
|
||||
<widget class="TQDialog">
|
||||
<property name="name">
|
||||
<cstring>UiGuiSettingsDialogBase</cstring>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>503</width>
|
||||
<height>336</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="caption">
|
||||
<string>Settings</string>
|
||||
</property>
|
||||
<vbox>
|
||||
<widget class="TQTabWidget">
|
||||
<property name="name">
|
||||
<cstring>tabWidget</cstring>
|
||||
</property>
|
||||
<property name="currentPage">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQWidget">
|
||||
<property name="name">
|
||||
<cstring>tabCommon</cstring>
|
||||
</property>
|
||||
<attribute name="title">
|
||||
<string>Common</string>
|
||||
</attribute>
|
||||
<vbox>
|
||||
<hbox>
|
||||
<widget class="TQLabel">
|
||||
<property name="name">
|
||||
<cstring>languageLabel</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Application language</string>
|
||||
</property>
|
||||
<property name="buddy" stdset="0">
|
||||
<cstring>cmbBoxLanguageSelection</cstring>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Choose UniversalIndentGui language.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQComboBox">
|
||||
<property name="name">
|
||||
<cstring>cmbBoxLanguageSelection</cstring>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Choose UniversalIndentGui language.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer8</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</hbox>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbLoadLastOpenedFileOnStartup</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Automatically open last file on startup</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>If checked, reopen the last used source code file on startup.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbEnableIndenterParameterTooltips</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enable Parameter Tooltips</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>If checked, tool tips will show up for the indenter parameters.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<hbox>
|
||||
<widget class="TQLabel">
|
||||
<property name="name">
|
||||
<cstring>labelRecentlyOpenedListSize</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Number of files in recently opened list</string>
|
||||
</property>
|
||||
<property name="buddy" stdset="0">
|
||||
<cstring>sbRecentlyOpenedListSize</cstring>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Sets number of files in the list of recently opened files.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQSpinBox">
|
||||
<property name="name">
|
||||
<cstring>sbRecentlyOpenedListSize</cstring>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maxValue">
|
||||
<number>30</number>
|
||||
</property>
|
||||
<property name="minValue">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Sets number of files in the list of recently opened files.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer7</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</hbox>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer6</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</vbox>
|
||||
</widget>
|
||||
<widget class="TQWidget">
|
||||
<property name="name">
|
||||
<cstring>tabEditor</cstring>
|
||||
</property>
|
||||
<attribute name="title">
|
||||
<string>Editor</string>
|
||||
</attribute>
|
||||
<vbox>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbWhiteSpaceIsVisible</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Display white space character (tabs, spaces, etc.)</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>Enables or disables displaying of white space characters in the editor.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<hbox>
|
||||
<widget class="TQLabel">
|
||||
<property name="name">
|
||||
<cstring>labelTabWidth</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Displayed width of tabs</string>
|
||||
</property>
|
||||
<property name="buddy" stdset="0">
|
||||
<cstring>sbTabWidth</cstring>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Defines how many spaces should be displayed in the editor for one tab.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQSpinBox">
|
||||
<property name="name">
|
||||
<cstring>sbTabWidth</cstring>
|
||||
</property>
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="maxValue">
|
||||
<number>99</number>
|
||||
</property>
|
||||
<property name="minValue">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="whatsThis" stdset="0">
|
||||
<string>Defines how many spaces should be displayed in the editor for one tab.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer5</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</hbox>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer4</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</vbox>
|
||||
</widget>
|
||||
<widget class="TQWidget">
|
||||
<property name="name">
|
||||
<cstring>tabSyntaxHighlight</cstring>
|
||||
</property>
|
||||
<attribute name="title">
|
||||
<string>Syntax Highlighting</string>
|
||||
</attribute>
|
||||
<vbox>
|
||||
<widget class="TQCheckBox">
|
||||
<property name="name">
|
||||
<cstring>cbEnableSyntaxHL</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enable syntax highlighting</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>By enabling special key words of the source code are highlighted.</string>
|
||||
</property>
|
||||
</widget>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer2</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</vbox>
|
||||
</widget>
|
||||
</widget>
|
||||
<hbox>
|
||||
<spacer>
|
||||
<property name="name">
|
||||
<cstring>spacer1</cstring>
|
||||
</property>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>okButton</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Ok</string>
|
||||
</property>
|
||||
<property name="default">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
</widget>
|
||||
<widget class="TQPushButton">
|
||||
<property name="name">
|
||||
<cstring>cancelButton</cstring>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>&Cancel</string>
|
||||
</property>
|
||||
</widget>
|
||||
</hbox>
|
||||
</vbox>
|
||||
</widget>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>okButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>UiGuiSettingsDialogBase</receiver>
|
||||
<slot>accept()</slot>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>cancelButton</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>UiGuiSettingsDialogBase</receiver>
|
||||
<slot>reject()</slot>
|
||||
</connection>
|
||||
</connections>
|
||||
</UI>
|
@ -1,205 +0,0 @@
|
||||
/***************************************************************************
|
||||
* Copyright (C) 2006-2012 by Thomas Schweitzer *
|
||||
* thomas-schweitzer(at)arcor.de *
|
||||
* *
|
||||
* This program is free software; you can redistribute it and/or modify *
|
||||
* it under the terms of the GNU General Public License version 2.0 as *
|
||||
* published by the Free Software Foundation. *
|
||||
* *
|
||||
* This program is distributed in the hope that it will be useful, *
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of *
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
|
||||
* GNU General Public License for more details. *
|
||||
* *
|
||||
* You should have received a copy of the GNU General Public License *
|
||||
* along with this program in the file LICENSE.GPL; if not, write to the *
|
||||
* Free Software Foundation, Inc., *
|
||||
* 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. *
|
||||
***************************************************************************/
|
||||
|
||||
#include "UiGuiSettingsDialog.h"
|
||||
#include "ui_UiGuiSettingsDialog.h"
|
||||
|
||||
#include "UiGuiSettings.h"
|
||||
|
||||
/*
|
||||
\class UiGuiSettingsDialog
|
||||
\ingroup grp_Settings
|
||||
\brief Displays a dialog window with settings for UniversalIndentGUI
|
||||
*/
|
||||
|
||||
/*
|
||||
\brief The constructor calls the setup function for the ui created by uic.
|
||||
*/
|
||||
UiGuiSettingsDialog::UiGuiSettingsDialog(TQWidget *parent,
|
||||
TQSharedPointer<UiGuiSettings> settings) :
|
||||
TQDialog(parent)
|
||||
{
|
||||
// Remember pointer to the UiGuiSettings object.
|
||||
_settings = settings;
|
||||
|
||||
// Init the user interface created by the UIC.
|
||||
_settingsDialogForm = new Ui::SettingsDialog();
|
||||
_settingsDialogForm->setupUi(this);
|
||||
|
||||
//TODO: This call has to be removed when the properties for the highlighters can be set
|
||||
// with the settings dialog.
|
||||
_settingsDialogForm->groupBoxSyntaxHighlighterProperties->setToolTip(
|
||||
"(Will be implemented soon)" +
|
||||
_settingsDialogForm->groupBoxSyntaxHighlighterProperties->toolTip());
|
||||
|
||||
// Connect the accepted signal to own function, to write values back to the UiGuiSettings object.
|
||||
connect(this, SIGNAL(accepted()), this, SLOT(writeWidgetValuesToSettings()));
|
||||
|
||||
// Init the language selection combobox.
|
||||
initTranslationSelection();
|
||||
}
|
||||
|
||||
/*
|
||||
\brief By calling this function the combobox for selecting the application language will
|
||||
be initialized.
|
||||
|
||||
Also the translation itself will be reinitialized.
|
||||
*/
|
||||
void UiGuiSettingsDialog::initTranslationSelection()
|
||||
{
|
||||
// First empty the combo box.
|
||||
_settingsDialogForm->languageSelectionComboBox->clear();
|
||||
|
||||
// Now add an entry into the box for every language short.
|
||||
foreach(TQString languageShort, _settings->getAvailableTranslations())
|
||||
{
|
||||
// Identify the language mnemonic and set the full name.
|
||||
if (languageShort == "en")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("English"));
|
||||
}
|
||||
else if (languageShort == "fr")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("French"));
|
||||
}
|
||||
else if (languageShort == "de")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("German"));
|
||||
}
|
||||
else if (languageShort == "zh_TW")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("Chinese (Taiwan)"));
|
||||
}
|
||||
else if (languageShort == "ja")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("Japanese"));
|
||||
}
|
||||
else if (languageShort == "ru")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("Russian"));
|
||||
}
|
||||
else if (languageShort == "uk")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(TQIcon(TQString(":/language/language-"
|
||||
+ languageShort + ".png")), tr("Ukrainian"));
|
||||
}
|
||||
else
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->addItem(tr(
|
||||
"Unknown language mnemonic ") + languageShort);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
\brief Displays the dialog by calling the dialogs exec function.
|
||||
|
||||
Before it gets all the values needed from the UiGuiSettings object.
|
||||
*/
|
||||
int UiGuiSettingsDialog::showDialog()
|
||||
{
|
||||
// Init all settings dialog objects with values from settings.
|
||||
_settings->setObjectPropertyToSettingValueRecursive(this);
|
||||
|
||||
// Execute the dialog.
|
||||
return exec();
|
||||
}
|
||||
|
||||
/*
|
||||
\brief This slot is called when the dialog box is closed by pressing the Ok button.
|
||||
|
||||
Writes all settings to the UiGuiSettings object.
|
||||
*/
|
||||
void UiGuiSettingsDialog::writeWidgetValuesToSettings()
|
||||
{
|
||||
// Write settings dialog object values to settings.
|
||||
_settings->setSettingToObjectPropertyValueRecursive(this);
|
||||
}
|
||||
|
||||
/*
|
||||
\brief Catches language change events and retranslates all needed widgets.
|
||||
*/
|
||||
void UiGuiSettingsDialog::changeEvent(TQEvent *event)
|
||||
{
|
||||
if (event->type() == TQEvent::LanguageChange)
|
||||
{
|
||||
_settingsDialogForm->retranslateUi(this);
|
||||
// If this is not explicit set here, TQt < 4.3.0 does not translate the buttons.
|
||||
_settingsDialogForm->buttonBox->setStandardButtons(
|
||||
TQDialogButtonBox::Cancel | TQDialogButtonBox::NoButton | TQDialogButtonBox::Ok);
|
||||
|
||||
//TODO: This has to be removed when the properties for the highlighters can be set.
|
||||
_settingsDialogForm->groupBoxSyntaxHighlighterProperties->setToolTip(
|
||||
"(Will be implemented soon)" +
|
||||
_settingsDialogForm->groupBoxSyntaxHighlighterProperties->toolTip());
|
||||
|
||||
TQStringList languageShortList = _settings->getAvailableTranslations();
|
||||
|
||||
// Now retranslate every entry in the language selection box.
|
||||
for (int i = 0; i < languageShortList.size(); i++)
|
||||
{
|
||||
TQString languageShort = languageShortList.at(i);
|
||||
|
||||
// Identify the language mnemonic and set the full name.
|
||||
if (languageShort == "en")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("English"));
|
||||
}
|
||||
else if (languageShort == "fr")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("French"));
|
||||
}
|
||||
else if (languageShort == "de")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("German"));
|
||||
}
|
||||
else if (languageShort == "zh_TW")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("Chinese (Taiwan)"));
|
||||
}
|
||||
else if (languageShort == "ja")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("Japanese"));
|
||||
}
|
||||
else if (languageShort == "ru")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("Russian"));
|
||||
}
|
||||
else if (languageShort == "uk")
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i, tr("Ukrainian"));
|
||||
}
|
||||
else
|
||||
{
|
||||
_settingsDialogForm->languageSelectionComboBox->setItemText(i,
|
||||
tr("Unknown language mnemonic ") + languageShort);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
TQWidget::changeEvent(event);
|
||||
}
|
||||
}
|
@ -1,460 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>SettingsDialog</class>
|
||||
<widget class="TQDialog" name="SettingsDialog">
|
||||
<property name="windowModality">
|
||||
<enum>TQt::ApplicationModal</enum>
|
||||
</property>
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>503</width>
|
||||
<height>336</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Settings</string>
|
||||
</property>
|
||||
<property name="windowIcon">
|
||||
<iconset resource="../resources/Icons.qrc">
|
||||
<normaloff>:/mainWindow/preferences-system.png</normaloff>:/mainWindow/preferences-system.png</iconset>
|
||||
</property>
|
||||
<layout class="TQVBoxLayout">
|
||||
<item>
|
||||
<widget class="TQTabWidget" name="tabWidget">
|
||||
<property name="currentIndex">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="TQWidget" name="tab">
|
||||
<attribute name="icon">
|
||||
<iconset resource="../resources/Icons.qrc">
|
||||
<normaloff>:/settingsDialog/applications-system.png</normaloff>:/settingsDialog/applications-system.png</iconset>
|
||||
</attribute>
|
||||
<attribute name="title">
|
||||
<string>Common</string>
|
||||
</attribute>
|
||||
<layout class="TQVBoxLayout">
|
||||
<item>
|
||||
<layout class="TQHBoxLayout">
|
||||
<item>
|
||||
<widget class="TQLabel" name="label">
|
||||
<property name="toolTip">
|
||||
<string>Displays all available translations for UniversalIndentGui and lets you choose one.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Application language</string>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>languageSelectionComboBox</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQComboBox" name="languageSelectionComboBox">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Displays all available translations for UniversalIndentGui and lets you choose one.</string>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">language</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">currentIndex</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQCheckBox" name="loadLastOpenedFileOnStartupComboBox">
|
||||
<property name="toolTip">
|
||||
<string>If selected opens the source code file on startup that was opened last time.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Automatically open last file on startup</string>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">loadLastSourceCodeFileOnStartup</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">checked</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQCheckBox" name="enableIndenterParameterTooltipsCheckBox">
|
||||
<property name="toolTip">
|
||||
<string>If checked, tool tips will show up if the mouse cursor remains over an indenter parameter for a while.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enable Parameter Tooltips</string>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">indenterParameterTooltipsEnabled</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">checked</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="TQHBoxLayout">
|
||||
<item>
|
||||
<widget class="TQLabel" name="labelRecentlyOpenedListSize">
|
||||
<property name="toolTip">
|
||||
<string>Sets how many files should be remembered in the list of recently opened files.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Number of files in recently opened list</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQSpinBox" name="recentlyOpenedListSizeSpinBox">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Sets how many files should be remembered in the list of recently opened files.</string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>30</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">recentlyOpenedListSize</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">value</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="TQWidget" name="tab_2">
|
||||
<attribute name="icon">
|
||||
<iconset resource="../resources/Icons.qrc">
|
||||
<normaloff>:/settingsDialog/accessories-text-editor.png</normaloff>:/settingsDialog/accessories-text-editor.png</iconset>
|
||||
</attribute>
|
||||
<attribute name="title">
|
||||
<string>Editor</string>
|
||||
</attribute>
|
||||
<layout class="TQVBoxLayout">
|
||||
<item>
|
||||
<widget class="TQCheckBox" name="whiteSpaceIsVisibleCheckBox">
|
||||
<property name="toolTip">
|
||||
<string>Enables or disables displaying of white space characters in the editor.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Display white space character (tabs, spaces, etc.)</string>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">whiteSpaceIsVisible</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">checked</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="TQHBoxLayout">
|
||||
<item>
|
||||
<widget class="TQLabel" name="labelTabWidth">
|
||||
<property name="toolTip">
|
||||
<string>Sets width in single spaces used for tabs</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Defines how many spaces should be displayed in the editor for one tab.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Displayed width of tabs</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQSpinBox" name="tabWidthSpinBox">
|
||||
<property name="sizePolicy">
|
||||
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
|
||||
<horstretch>0</horstretch>
|
||||
<verstretch>0</verstretch>
|
||||
</sizepolicy>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Defines how many spaces should be displayed in the editor for one tab character.</string>
|
||||
</property>
|
||||
<property name="minimum">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="maximum">
|
||||
<number>99</number>
|
||||
</property>
|
||||
<property name="value">
|
||||
<number>1</number>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">tabWidth</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">value</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<widget class="TQWidget" name="tab_3">
|
||||
<attribute name="icon">
|
||||
<iconset resource="../resources/Icons.qrc">
|
||||
<normaloff>:/settingsDialog/syntax-highlight.png</normaloff>:/settingsDialog/syntax-highlight.png</iconset>
|
||||
</attribute>
|
||||
<attribute name="title">
|
||||
<string>Syntax Highlighting</string>
|
||||
</attribute>
|
||||
<layout class="TQVBoxLayout">
|
||||
<item>
|
||||
<widget class="TQCheckBox" name="cbEnableSyntaxHL">
|
||||
<property name="toolTip">
|
||||
<string>By enabling special key words of the source code are highlighted.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Enable syntax highlighting</string>
|
||||
</property>
|
||||
<property name="connectedSettingName" stdset="0">
|
||||
<string notr="true">SyntaxHighlightingEnabled</string>
|
||||
</property>
|
||||
<property name="connectedPropertyName" stdset="0">
|
||||
<string notr="true">checked</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQGroupBox" name="groupBoxSyntaxHighlighterProperties">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Lets you make settings for all properties of the available syntax highlighters, like font and color.</string>
|
||||
</property>
|
||||
<property name="title">
|
||||
<string>Highlighter settings</string>
|
||||
</property>
|
||||
<layout class="TQHBoxLayout">
|
||||
<item>
|
||||
<widget class="TQListWidget" name="listWidget">
|
||||
<property name="currentRow">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQListWidget" name="listWidget_2">
|
||||
<property name="currentRow">
|
||||
<number>-1</number>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="TQVBoxLayout">
|
||||
<item>
|
||||
<widget class="TQPushButton" name="pushButton_2">
|
||||
<property name="toolTip">
|
||||
<string>Set the font for the current selected highlighter property.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Set Font</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQPushButton" name="pushButton">
|
||||
<property name="toolTip">
|
||||
<string>Set the color for the current selected highlighter property.</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Set Color</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer>
|
||||
<property name="orientation">
|
||||
<enum>TQt::Vertical</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>20</width>
|
||||
<height>40</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="TQDialogButtonBox" name="buttonBox">
|
||||
<property name="orientation">
|
||||
<enum>TQt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="standardButtons">
|
||||
<set>TQDialogButtonBox::Cancel|TQDialogButtonBox::Ok</set>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</widget>
|
||||
<resources>
|
||||
<include location="../resources/Icons.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>accepted()</signal>
|
||||
<receiver>SettingsDialog</receiver>
|
||||
<slot>accept()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>250</x>
|
||||
<y>316</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>153</x>
|
||||
<y>236</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBox</sender>
|
||||
<signal>rejected()</signal>
|
||||
<receiver>SettingsDialog</receiver>
|
||||
<slot>reject()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>327</x>
|
||||
<y>316</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>282</x>
|
||||
<y>236</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>enableProxyCheckBox</sender>
|
||||
<signal>toggled(bool)</signal>
|
||||
<receiver>widget</receiver>
|
||||
<slot>setEnabled(bool)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>73</x>
|
||||
<y>68</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>76</x>
|
||||
<y>95</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
</ui>
|