mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
Improve prefs language UI
This commit is contained in:
parent
ebf42d9b10
commit
bbeee6bbef
@ -2396,9 +2396,9 @@ PrefLanguage::PrefLanguage(GuiPreferences * form)
|
|||||||
this, SIGNAL(changed()));
|
this, SIGNAL(changed()));
|
||||||
connect(respectOSkbdCB, SIGNAL(clicked()),
|
connect(respectOSkbdCB, SIGNAL(clicked()),
|
||||||
this, SIGNAL(changed()));
|
this, SIGNAL(changed()));
|
||||||
connect(autoBeginCB, SIGNAL(clicked()),
|
connect(explicitDocLangBeginCB, SIGNAL(clicked()),
|
||||||
this, SIGNAL(changed()));
|
this, SIGNAL(changed()));
|
||||||
connect(autoEndCB, SIGNAL(clicked()),
|
connect(explicitDocLangEndCB, SIGNAL(clicked()),
|
||||||
this, SIGNAL(changed()));
|
this, SIGNAL(changed()));
|
||||||
connect(languagePackageCO, SIGNAL(activated(int)),
|
connect(languagePackageCO, SIGNAL(activated(int)),
|
||||||
this, SIGNAL(changed()));
|
this, SIGNAL(changed()));
|
||||||
@ -2472,8 +2472,8 @@ void PrefLanguage::applyRC(LyXRC & rc) const
|
|||||||
rc.visual_cursor = visualCursorRB->isChecked();
|
rc.visual_cursor = visualCursorRB->isChecked();
|
||||||
rc.mark_foreign_language = markForeignCB->isChecked();
|
rc.mark_foreign_language = markForeignCB->isChecked();
|
||||||
rc.respect_os_kbd_language = respectOSkbdCB->isChecked();
|
rc.respect_os_kbd_language = respectOSkbdCB->isChecked();
|
||||||
rc.language_auto_begin = autoBeginCB->isChecked();
|
rc.language_auto_begin = !explicitDocLangBeginCB->isChecked();
|
||||||
rc.language_auto_end = autoEndCB->isChecked();
|
rc.language_auto_end = !explicitDocLangEndCB->isChecked();
|
||||||
int const p = languagePackageCO->currentIndex();
|
int const p = languagePackageCO->currentIndex();
|
||||||
if (p == 0)
|
if (p == 0)
|
||||||
rc.language_package_selection = LyXRC::LP_AUTO;
|
rc.language_package_selection = LyXRC::LP_AUTO;
|
||||||
@ -2502,8 +2502,8 @@ void PrefLanguage::updateRC(LyXRC const & rc)
|
|||||||
logicalCursorRB->setChecked(true);
|
logicalCursorRB->setChecked(true);
|
||||||
markForeignCB->setChecked(rc.mark_foreign_language);
|
markForeignCB->setChecked(rc.mark_foreign_language);
|
||||||
respectOSkbdCB->setChecked(rc.respect_os_kbd_language);
|
respectOSkbdCB->setChecked(rc.respect_os_kbd_language);
|
||||||
autoBeginCB->setChecked(rc.language_auto_begin);
|
explicitDocLangBeginCB->setChecked(!rc.language_auto_begin);
|
||||||
autoEndCB->setChecked(rc.language_auto_end);
|
explicitDocLangEndCB->setChecked(!rc.language_auto_end);
|
||||||
languagePackageCO->setCurrentIndex(rc.language_package_selection);
|
languagePackageCO->setCurrentIndex(rc.language_package_selection);
|
||||||
languagePackageED->setText(toqstr(rc.language_custom_package));
|
languagePackageED->setText(toqstr(rc.language_custom_package));
|
||||||
languagePackageED->setEnabled(languagePackageCO->currentIndex() == 2);
|
languagePackageED->setEnabled(languagePackageCO->currentIndex() == 2);
|
||||||
|
@ -6,15 +6,17 @@
|
|||||||
<rect>
|
<rect>
|
||||||
<x>0</x>
|
<x>0</x>
|
||||||
<y>0</y>
|
<y>0</y>
|
||||||
<width>475</width>
|
<width>517</width>
|
||||||
<height>362</height>
|
<height>570</height>
|
||||||
</rect>
|
</rect>
|
||||||
</property>
|
</property>
|
||||||
<property name="windowTitle">
|
<property name="windowTitle">
|
||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout_2">
|
<layout class="QGridLayout" name="gridLayout_4">
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
|
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||||
|
<item>
|
||||||
<widget class="QLabel" name="uiLanguageLA">
|
<widget class="QLabel" name="uiLanguageLA">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>User &interface language:</string>
|
<string>User &interface language:</string>
|
||||||
@ -24,7 +26,7 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="0" column="1">
|
<item>
|
||||||
<widget class="QComboBox" name="uiLanguageCO">
|
<widget class="QComboBox" name="uiLanguageCO">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Select the language of the user interface (menus, dialogs, etc.)</string>
|
<string>Select the language of the user interface (menus, dialogs, etc.)</string>
|
||||||
@ -34,7 +36,28 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</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="1" column="0">
|
<item row="1" column="0">
|
||||||
|
<widget class="QGroupBox" name="groupBox">
|
||||||
|
<property name="title">
|
||||||
|
<string>LaTeX Language Support</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" name="gridLayout_2">
|
||||||
|
<item row="0" column="0">
|
||||||
<widget class="QLabel" name="languagePackageLA">
|
<widget class="QLabel" name="languagePackageLA">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Language &package:</string>
|
<string>Language &package:</string>
|
||||||
@ -44,12 +67,10 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1" colspan="2">
|
<item row="0" column="1">
|
||||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
|
||||||
<item>
|
|
||||||
<widget class="QComboBox" name="languagePackageCO">
|
<widget class="QComboBox" name="languagePackageCO">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Select which language package LyX should use</string>
|
<string>Select which (LaTeX) language package documents should use by default</string>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
@ -73,16 +94,14 @@
|
|||||||
</item>
|
</item>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item>
|
<item row="0" column="2">
|
||||||
<widget class="QLineEdit" name="languagePackageED">
|
<widget class="QLineEdit" name="languagePackageED">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Enter the command to load the language package (default: \usepackage{babel})</string>
|
<string>Enter the command to load a custom language package (default: \usepackage{babel})</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
</layout>
|
<item row="1" column="0">
|
||||||
</item>
|
|
||||||
<item row="2" column="0">
|
|
||||||
<widget class="QLabel" name="startCommandLA">
|
<widget class="QLabel" name="startCommandLA">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Command s&tart:</string>
|
<string>Command s&tart:</string>
|
||||||
@ -92,27 +111,14 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="1">
|
<item row="1" column="1" colspan="2">
|
||||||
<widget class="QLineEdit" name="startCommandED">
|
<widget class="QLineEdit" name="startCommandED">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>The LaTeX command that starts a switch to a foreign language</string>
|
<string>The LaTeX command that starts a switch to a different language. The placeholder $$lang is replaced by the actual language name.</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="2">
|
<item row="2" column="0">
|
||||||
<spacer name="horizontalSpacer">
|
|
||||||
<property name="orientation">
|
|
||||||
<enum>Qt::Horizontal</enum>
|
|
||||||
</property>
|
|
||||||
<property name="sizeHint" stdset="0">
|
|
||||||
<size>
|
|
||||||
<width>102</width>
|
|
||||||
<height>20</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
</spacer>
|
|
||||||
</item>
|
|
||||||
<item row="3" column="0">
|
|
||||||
<widget class="QLabel" name="endCommandLA">
|
<widget class="QLabel" name="endCommandLA">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Command e&nd:</string>
|
<string>Command e&nd:</string>
|
||||||
@ -122,109 +128,53 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="3" column="1">
|
<item row="2" column="1" colspan="2">
|
||||||
<widget class="QLineEdit" name="endCommandED">
|
<widget class="QLineEdit" name="endCommandED">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>The LaTeX command that ends a switch to a foreign language</string>
|
<string>The LaTeX command that ends a switch to a different language. The placeholder $$lang is replaced by the actual language name.</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="4" column="0">
|
<item row="3" column="0" colspan="2">
|
||||||
<widget class="QLabel" name="decimalPointL">
|
|
||||||
<property name="text">
|
|
||||||
<string>Default decimal &separator:</string>
|
|
||||||
</property>
|
|
||||||
<property name="buddy">
|
|
||||||
<cstring>defaultDecimalPointLE</cstring>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="4" column="1">
|
|
||||||
<widget class="QLineEdit" name="defaultDecimalPointLE">
|
|
||||||
<property name="maximumSize">
|
|
||||||
<size>
|
|
||||||
<width>20</width>
|
|
||||||
<height>16777215</height>
|
|
||||||
</size>
|
|
||||||
</property>
|
|
||||||
<property name="inputMask">
|
|
||||||
<string/>
|
|
||||||
</property>
|
|
||||||
<property name="alignment">
|
|
||||||
<set>Qt::AlignCenter</set>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="0">
|
|
||||||
<widget class="QLabel" name="defaultLengthUnitLA">
|
|
||||||
<property name="text">
|
|
||||||
<string>Default length &unit:</string>
|
|
||||||
</property>
|
|
||||||
<property name="buddy">
|
|
||||||
<cstring>defaultLengthUnitCO</cstring>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="5" column="1">
|
|
||||||
<widget class="QComboBox" name="defaultLengthUnitCO"/>
|
|
||||||
</item>
|
|
||||||
<item row="6" column="0" colspan="2">
|
|
||||||
<widget class="QCheckBox" name="globalCB">
|
<widget class="QCheckBox" name="globalCB">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>Check to pass the language globally (to the document class), not locally (to the language package)</string>
|
<string>Check to pass the language globally (to the document class), not locally (to the language package), so that other packages are also informed about the used languages.</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Set languages &globally</string>
|
<string>Set languages &globally</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="7" column="0">
|
<item row="4" column="0" colspan="2">
|
||||||
<widget class="QCheckBox" name="autoBeginCB">
|
<widget class="QCheckBox" name="explicitDocLangBeginCB">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>If checked, the document language is not explicitly set by a language switch command</string>
|
<string>If checked, the document language is explicitly set by a language switch command</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Auto &begin</string>
|
<string>Set document language e&xplicitly</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="8" column="0">
|
<item row="5" column="0" colspan="2">
|
||||||
<widget class="QCheckBox" name="autoEndCB">
|
<widget class="QCheckBox" name="explicitDocLangEndCB">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string>If checked, the document language is not explicitly closed by a language switch command</string>
|
<string>If checked, the document language is explicitly closed by a language switch command</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Auto &end</string>
|
<string>&Unset document language explicitly</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="9" column="0" colspan="2">
|
</layout>
|
||||||
<widget class="QCheckBox" name="markForeignCB">
|
|
||||||
<property name="toolTip">
|
|
||||||
<string>Check to highlight foreign languages visually in the work area</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Mark &foreign languages</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="10" column="0" colspan="2">
|
<item row="2" column="0">
|
||||||
<widget class="QCheckBox" name="respectOSkbdCB">
|
|
||||||
<property name="toolTip">
|
|
||||||
<string>Select to use the current keyboard language, as set from the operating system, as default input language.</string>
|
|
||||||
</property>
|
|
||||||
<property name="text">
|
|
||||||
<string>Respect &OS keyboard language</string>
|
|
||||||
</property>
|
|
||||||
</widget>
|
|
||||||
</item>
|
|
||||||
<item row="11" column="0" colspan="3">
|
|
||||||
<widget class="QGroupBox" name="rtlGB2">
|
<widget class="QGroupBox" name="rtlGB2">
|
||||||
<property name="toolTip">
|
<property name="toolTip">
|
||||||
<string/>
|
<string/>
|
||||||
</property>
|
</property>
|
||||||
<property name="title">
|
<property name="title">
|
||||||
<string>Right-to-Left Language Support</string>
|
<string>Editor Settings</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="flat">
|
<property name="flat">
|
||||||
<bool>true</bool>
|
<bool>true</bool>
|
||||||
@ -234,17 +184,46 @@
|
|||||||
</property>
|
</property>
|
||||||
<layout class="QGridLayout" name="gridLayout">
|
<layout class="QGridLayout" name="gridLayout">
|
||||||
<item row="0" column="0">
|
<item row="0" column="0">
|
||||||
|
<widget class="QCheckBox" name="markForeignCB">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Check to highlight additional languages (to the document language) visually in the work area</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>&Mark additional languages</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QCheckBox" name="respectOSkbdCB">
|
||||||
|
<property name="toolTip">
|
||||||
|
<string>Select to use the current keyboard language, as set from the operating system, as default input language.</string>
|
||||||
|
</property>
|
||||||
|
<property name="text">
|
||||||
|
<string>Respect &OS keyboard language</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="2" column="0">
|
||||||
<layout class="QHBoxLayout">
|
<layout class="QHBoxLayout">
|
||||||
<property name="spacing">
|
<property name="spacing">
|
||||||
<number>6</number>
|
<number>6</number>
|
||||||
</property>
|
</property>
|
||||||
<property name="margin">
|
<property name="leftMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="topMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="rightMargin">
|
||||||
|
<number>0</number>
|
||||||
|
</property>
|
||||||
|
<property name="bottomMargin">
|
||||||
<number>0</number>
|
<number>0</number>
|
||||||
</property>
|
</property>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QLabel" name="cursorMovementLA">
|
<widget class="QLabel" name="cursorMovementLA">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Cursor movement:</string>
|
<string>Right-to-left cursor movement:</string>
|
||||||
</property>
|
</property>
|
||||||
<property name="scaledContents">
|
<property name="scaledContents">
|
||||||
<bool>false</bool>
|
<bool>false</bool>
|
||||||
@ -270,14 +249,14 @@
|
|||||||
</item>
|
</item>
|
||||||
</layout>
|
</layout>
|
||||||
</item>
|
</item>
|
||||||
<item row="1" column="1">
|
<item row="2" column="1">
|
||||||
<spacer>
|
<spacer name="horizontalSpacer_3">
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Horizontal</enum>
|
<enum>Qt::Horizontal</enum>
|
||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>101</width>
|
<width>40</width>
|
||||||
<height>20</height>
|
<height>20</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
@ -286,7 +265,68 @@
|
|||||||
</layout>
|
</layout>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="12" column="0">
|
<item row="3" column="0">
|
||||||
|
<widget class="QGroupBox" name="groupBox_2">
|
||||||
|
<property name="title">
|
||||||
|
<string>Local Preferences</string>
|
||||||
|
</property>
|
||||||
|
<layout class="QGridLayout" name="gridLayout_3">
|
||||||
|
<item row="0" column="0">
|
||||||
|
<widget class="QLabel" name="decimalPointL">
|
||||||
|
<property name="text">
|
||||||
|
<string>Default decimal &separator:</string>
|
||||||
|
</property>
|
||||||
|
<property name="buddy">
|
||||||
|
<cstring>defaultDecimalPointLE</cstring>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="0">
|
||||||
|
<widget class="QLabel" name="defaultLengthUnitLA">
|
||||||
|
<property name="text">
|
||||||
|
<string>Default length &unit:</string>
|
||||||
|
</property>
|
||||||
|
<property name="buddy">
|
||||||
|
<cstring>defaultLengthUnitCO</cstring>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="0" column="1">
|
||||||
|
<widget class="QLineEdit" name="defaultDecimalPointLE">
|
||||||
|
<property name="maximumSize">
|
||||||
|
<size>
|
||||||
|
<width>20</width>
|
||||||
|
<height>16777215</height>
|
||||||
|
</size>
|
||||||
|
</property>
|
||||||
|
<property name="inputMask">
|
||||||
|
<string/>
|
||||||
|
</property>
|
||||||
|
<property name="alignment">
|
||||||
|
<set>Qt::AlignCenter</set>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="1">
|
||||||
|
<widget class="QComboBox" name="defaultLengthUnitCO"/>
|
||||||
|
</item>
|
||||||
|
<item row="1" column="2">
|
||||||
|
<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>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
|
<item row="4" column="0">
|
||||||
<spacer>
|
<spacer>
|
||||||
<property name="orientation">
|
<property name="orientation">
|
||||||
<enum>Qt::Vertical</enum>
|
<enum>Qt::Vertical</enum>
|
||||||
@ -313,8 +353,7 @@
|
|||||||
<tabstop>defaultDecimalPointLE</tabstop>
|
<tabstop>defaultDecimalPointLE</tabstop>
|
||||||
<tabstop>defaultLengthUnitCO</tabstop>
|
<tabstop>defaultLengthUnitCO</tabstop>
|
||||||
<tabstop>globalCB</tabstop>
|
<tabstop>globalCB</tabstop>
|
||||||
<tabstop>autoBeginCB</tabstop>
|
<tabstop>explicitDocLangBeginCB</tabstop>
|
||||||
<tabstop>autoEndCB</tabstop>
|
|
||||||
<tabstop>markForeignCB</tabstop>
|
<tabstop>markForeignCB</tabstop>
|
||||||
<tabstop>respectOSkbdCB</tabstop>
|
<tabstop>respectOSkbdCB</tabstop>
|
||||||
<tabstop>logicalCursorRB</tabstop>
|
<tabstop>logicalCursorRB</tabstop>
|
||||||
@ -324,4 +363,5 @@
|
|||||||
<include location="local">qt_i18n.h</include>
|
<include location="local">qt_i18n.h</include>
|
||||||
</includes>
|
</includes>
|
||||||
<resources/>
|
<resources/>
|
||||||
|
<connections/>
|
||||||
</ui>
|
</ui>
|
||||||
|
Loading…
Reference in New Issue
Block a user