lyx_mirror/src/frontends/qt4
Günter Milde c83765163f CJK package is never used with non-TeX fonts.
Prepare for languages that use CJK with TeX fonts and Polyglossia
with non-TeX fonts.

Korean is already supported by Polyglossia,
LyX support will follow (file version change).
2019-05-26 01:45:35 +02:00
..
ui Read line edit label 2019-05-24 17:51:42 +02:00
.gitignore
Action.cpp
Action.h
BulletsModule.cpp
BulletsModule.h
ButtonController.cpp Add forgotten initialization 2018-12-20 13:46:41 +01:00
ButtonController.h Maintain default status for all dialogs using ButtonController 2018-12-20 12:56:30 +01:00
ButtonPolicy.cpp Further BC fixes to GuiCharacter 2018-05-05 17:24:09 +02:00
ButtonPolicy.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
CategorizedCombo.cpp Use underline in (+ bold) for char match in layout 2018-10-22 21:16:56 -04:00
CategorizedCombo.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
CMakeLists.txt Cmake build: Add option to use native file dialog also for linux 2017-11-26 18:50:53 +01:00
ColorCache.cpp Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
ColorCache.h
CustomizedWidgets.cpp
CustomizedWidgets.h
Dialog.cpp Speed up exit time 2017-10-18 13:12:20 +02:00
Dialog.h Speed up exit time 2017-10-18 13:12:20 +02:00
DialogView.cpp
DialogView.h
DockView.cpp Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
DockView.h Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
EmptyTable.cpp
EmptyTable.h
FancyLineEdit.cpp Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
FancyLineEdit.h Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
FileDialog.cpp Make it possible to select (not)native file dialogs at run time 2018-03-19 11:17:33 +01:00
FileDialog.h
FindAndReplace.cpp Fix #11505. Count and display number of replaced strings in FindAdv 2019-03-13 14:06:18 +01:00
FindAndReplace.h Update the Advanced F&R document class when switching buffers. 2018-10-04 20:30:01 -04:00
FloatPlacement.cpp Align some strings 2018-05-11 12:59:26 +02:00
FloatPlacement.h Add support for global float alignment 2018-05-10 20:15:11 +02:00
GuiAbout.cpp Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiAbout.h Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiAlert.cpp Rename for clarity. 2019-05-12 23:16:25 -04:00
GuiApplication.cpp Add LFUN_BUFFER_WRITE_AS_TEMPLATE 2019-03-23 10:17:33 +01:00
GuiApplication.h Add override statements to please clang 2019-01-02 18:49:23 +01:00
GuiBibitem.cpp Another quotation mark fix. 2019-04-19 14:27:27 +02:00
GuiBibitem.h
GuiBibtex.cpp Fix crash in GuiBibtex 2019-04-05 17:53:41 +02:00
GuiBibtex.h GuiBibtex: add button to edit individual databases externally 2019-03-30 11:37:28 +01:00
GuiBox.cpp Use proper localization chain for Box special width/height 2018-01-27 12:26:01 +01:00
GuiBox.h
GuiBranch.cpp
GuiBranch.h
GuiBranches.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
GuiBranches.h
GuiChanges.cpp Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiChanges.h
GuiCharacter.cpp Fix Text Properties dialog height 2018-12-24 16:18:54 +01:00
GuiCharacter.h Compile fix for Qt < 5.7 2018-12-21 13:37:07 +01:00
GuiCitation.cpp Fix some implicit conversion issues. 2019-03-30 09:33:09 +01:00
GuiCitation.h Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiClipboard.cpp Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
GuiClipboard.h
GuiCommandBuffer.cpp Make "devel mode" configurable at run time 2017-07-24 22:00:44 +02:00
GuiCommandBuffer.h Make "devel mode" configurable at run time 2017-07-24 22:00:44 +02:00
GuiCommandEdit.cpp
GuiCommandEdit.h
GuiCompare.cpp Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiCompare.h Start using QDialogButtonGroup rather than manual OK etc. buttons 2018-07-08 16:35:38 +02:00
GuiCompareHistory.cpp Amend 0570d16a3b 2018-07-08 16:48:58 +02:00
GuiCompareHistory.h Amend 0570d16a3b 2018-07-08 16:48:58 +02:00
GuiCompleter.cpp Completion popup menu did not respond to Esc. 2018-12-29 14:36:38 +01:00
GuiCompleter.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
GuiDelimiter.cpp More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiDelimiter.h More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiDialog.cpp GuiCharacter: Add "Reset" and "Restore Defaults" buttons 2018-12-17 12:59:40 +01:00
GuiDialog.h GuiCharacter: Add "Reset" and "Restore Defaults" buttons 2018-12-17 12:59:40 +01:00
GuiDocument.cpp CJK package is never used with non-TeX fonts. 2019-05-26 01:45:35 +02:00
GuiDocument.h Read line edit label 2019-05-24 17:51:42 +02:00
GuiErrorList.cpp More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiErrorList.h
GuiERT.cpp Collapsable -> Collapsible (part 2) 2017-10-16 10:12:21 +02:00
GuiERT.h
GuiExternal.cpp More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiExternal.h
GuiFontExample.cpp
GuiFontExample.h
GuiFontLoader.cpp Move the stateText code for FontInfo to FontInfo class. 2019-05-10 10:45:40 +02:00
GuiFontLoader.h
GuiFontMetrics.cpp Revert "Try to compute row height like it should be done" 2019-05-13 10:47:47 +02:00
GuiFontMetrics.h Revert "Try to compute row height like it should be done" 2019-05-13 10:47:47 +02:00
GuiGraphics.cpp More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiGraphics.h Revert "Create new graphics from within LyX choosing a sample file to copy from." 2017-05-06 09:21:50 +02:00
GuiHSpace.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
GuiHSpace.h
GuiHyperlink.cpp Fix bug #10879. 2018-02-24 01:01:34 -05:00
GuiHyperlink.h
GuiIdListModel.cpp Prevent assert due to some odd role in older qt versions. 2019-05-14 14:05:46 +02:00
GuiIdListModel.h Resolve some implicit conversion warnings. 2019-04-05 11:54:44 +02:00
GuiImage.cpp Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
GuiImage.h
GuiInclude.cpp Maintain default status for all dialogs using ButtonController 2018-12-20 12:56:30 +01:00
GuiInclude.h Fix #10874 compiler warnings. 2017-12-16 00:46:16 -05:00
GuiIndex.cpp More QDialogButtonBox transformation 2018-07-09 09:46:39 +02:00
GuiIndex.h
GuiIndices.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
GuiIndices.h
GuiInfo.cpp New info-inset type l7n 2018-08-13 17:18:44 +02:00
GuiInfo.h Fix small UI glitch 2018-08-07 14:48:51 +02:00
GuiKeySymbol.cpp Do not use GUI language for shortcut info inset if no translation is available 2019-03-09 12:00:40 +01:00
GuiKeySymbol.h
GuiLabel.cpp Fix bug #10879. 2018-02-24 01:01:34 -05:00
GuiLabel.h
GuiLine.cpp
GuiLine.h
GuiListings.cpp Fix some listings/minted incompatibilities 2019-04-19 19:03:29 +02:00
GuiListings.h
GuiLog.cpp More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiLog.h
GuiLyXFiles.cpp GuiLyXFiles: handle defaults.lyx 2019-03-23 17:41:42 +01:00
GuiLyXFiles.h Use GuiLyXFiles also for ui, kbd and bind files in prefs 2019-03-22 14:14:33 +01:00
GuiMathMatrix.cpp More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiMathMatrix.h More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiNomenclature.cpp Fix bug #10879. 2018-02-24 01:01:34 -05:00
GuiNomenclature.h
GuiNote.cpp More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiNote.h
GuiPainter.cpp Fix bold-like characters when selecting bidi text 2019-04-09 11:32:22 +02:00
GuiPainter.h Followup to 9fe101e8: remove unused method. 2018-10-08 16:04:32 +02:00
GuiParagraph.cpp Fix height of paragraph dialog 2018-12-24 16:48:22 +01:00
GuiParagraph.h More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiPhantom.cpp More QDialogButtonBox 2018-07-10 09:04:42 +02:00
GuiPhantom.h
GuiPrefs.cpp Cosmetics 2019-03-22 14:18:17 +01:00
GuiPrefs.h Cosmetics 2019-03-22 14:18:17 +01:00
GuiPrintindex.cpp QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiPrintindex.h
GuiPrintNomencl.cpp
GuiPrintNomencl.h Fix creationCode() of GuiPrintNomencl 2018-07-10 11:01:49 +02:00
GuiProgress.cpp Use QMessageBox for toggleWarning if possible 2018-07-10 15:00:25 +02:00
GuiProgress.h
GuiProgressView.cpp Fix bug #10881. 2018-02-22 00:17:46 -05:00
GuiProgressView.h Speed up exit time 2017-10-18 13:12:20 +02:00
GuiRef.cpp Use combo box data rather than looking up info from InsetRef. 2019-01-06 17:46:40 -05:00
GuiRef.h QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiSearch.cpp More alignment fixes 2018-12-25 18:20:02 +01:00
GuiSearch.h
GuiSelection.cpp
GuiSelection.h
GuiSelectionManager.cpp GuiDocument: Sort available modules by category 2019-04-07 11:23:19 +02:00
GuiSelectionManager.h GuiDocument: Sort available modules by category 2019-04-07 11:23:19 +02:00
GuiSendto.cpp QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiSendto.h
GuiSetBorder.cpp booktabs: support for \cmidrule trimming 2019-04-03 07:59:52 +02:00
GuiSetBorder.h booktabs: support for \cmidrule trimming 2019-04-03 07:59:52 +02:00
GuiShowFile.cpp QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiShowFile.h
GuiSpellchecker.cpp Fix #10884 compiler warnings. 2017-12-16 00:48:34 -05:00
GuiSpellchecker.h Fix #10884 compiler warnings. 2017-12-16 00:48:34 -05:00
GuiSymbols.cpp Rename legacy input encoding settings. 2019-04-16 20:17:32 +02:00
GuiSymbols.h QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiTabular.cpp booktabs trimming: fix some thinkos 2019-04-03 17:18:21 +02:00
GuiTabular.h booktabs: support for \cmidrule trimming 2019-04-03 07:59:52 +02:00
GuiTabularCreate.cpp Initialize TabularCreate dialog enabled. 2019-04-04 08:23:27 +02:00
GuiTabularCreate.h Introducing table templates 2019-03-26 13:43:33 +01:00
GuiTexinfo.cpp QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiTexinfo.h
GuiThesaurus.cpp GuiThesaurus: maintain default state of Replace button 2018-12-21 12:56:02 +01:00
GuiThesaurus.h
GuiToc.cpp Fix bug #10879. 2018-02-24 01:01:34 -05:00
GuiToc.h
GuiToolbar.cpp Fix regression introduced in a65f1e54dc 2018-12-28 17:25:53 +01:00
GuiToolbar.h No need for an extra icon 2018-12-27 11:18:13 +01:00
GuiView.cpp Revert "GMO for BG" 2019-05-12 23:30:49 -04:00
GuiView.h Revert "GMO for BG" 2019-05-12 23:30:49 -04:00
GuiViewSource.cpp Speed up exit time 2017-10-18 13:12:20 +02:00
GuiViewSource.h Speed up exit time 2017-10-18 13:12:20 +02:00
GuiVSpace.cpp
GuiVSpace.h
GuiWorkArea_Private.h Use a backing store on macOS 2017-12-15 17:30:20 +01:00
GuiWorkArea.cpp Display URL-encoded chars decoded in display path 2019-03-23 15:15:08 +01:00
GuiWorkArea.h Make tab movement visible (#10733) 2018-10-04 19:52:21 -04:00
GuiWrap.cpp QDialogButtonBox for the remaining dialogs. 2018-07-10 13:04:02 +02:00
GuiWrap.h
IconPalette.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
IconPalette.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
InGuiThread.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
InGuiThread.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
InsertTableWidget.cpp Fix bug #10879. 2018-02-24 01:01:34 -05:00
InsertTableWidget.h
InsetParamsDialog.cpp Maintain default status for all dialogs using ButtonController 2018-12-20 12:56:30 +01:00
InsetParamsDialog.h More QDialogButtonBox 2018-07-10 09:04:42 +02:00
InsetParamsWidget.cpp
InsetParamsWidget.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
LaTeXHighlighter.cpp Fix trailing whitespace in cpp files. 2017-07-03 13:53:14 -04:00
LaTeXHighlighter.h
LayoutBox.cpp Use underline in (+ bold) for char match in layout 2018-10-22 21:16:56 -04:00
LayoutBox.h Fix whitespace at EOL. 2017-07-03 13:46:30 -04:00
LengthCombo.cpp
LengthCombo.h Bulk cleanup/fix incorrect annotation at the end of namespaces. 2017-07-23 13:11:54 +02:00
LyXFileDialog.cpp Get rid of idiosyncratic accelerator syntax 2017-12-20 11:37:13 +01:00
LyXFileDialog.h
Makefile.am Revert "GMO for BG" 2019-05-12 23:30:49 -04:00
Menus.cpp Include all parent branches in the menu. 2019-05-22 22:00:31 -04:00
Menus.h Extend list of accessible menu info 2018-08-08 15:05:58 +02:00
PanelStack.cpp Fix minor whitespace error. 2017-07-17 22:23:17 +02:00
PanelStack.h
qt_helpers.cpp Avoid extra space in tooltips 2018-11-04 14:02:42 -10:00
qt_helpers.h Sort external templates locale-aware 2017-08-09 16:09:50 +02:00
qt_i18n.h
README
TocModel.cpp Fix Undocked Outliner & multiple window crashes (#11004). 2018-03-12 14:34:24 +01:00
TocModel.h Fix Undocked Outliner & multiple window crashes (#11004). 2018-03-12 14:34:24 +01:00
TocWidget.cpp Fix Undocked Outliner & multiple window crashes (#11004). 2018-03-12 14:34:24 +01:00
TocWidget.h Fix Undocked Outliner & multiple window crashes (#11004). 2018-03-12 14:34:24 +01:00
Toolbars.cpp Add toolbar menus for custom insets and character styles. 2018-05-02 20:31:24 -04:00
Toolbars.h Add toolbar menus for custom insets and character styles. 2018-05-02 20:31:24 -04:00
ToolTipFormatter.cpp
ToolTipFormatter.h
Validator.cpp Fix bug #10892. 2018-02-22 00:33:28 -05:00
Validator.h

This file contains some do's and dont's for the Qt4 frontend.

General rules
-------------

Every editable field that affects the state of the dialog contents
from LyX's point of view should connect its xxxChanged() signal to
a the dialog's changed_adaptor() slot, which in turn should call
changed(). If you are using a more complicated thing anyway,
then remember to call changed() at the end (if it has changed!)

Every non-trivial widget should have a tooltip. If you don't know
what to write, write "FIXME", and it can fixed later. Don't be afraid
to use QWhatsThis too, but this must be done in the derived class's
constructor, and use _("..."). Non-trivial means that things like "OK"
/must not/ have a tooltip.

moc needs a fully qualified "std::string" for .connect() statements
to work. Be very, very careful.

Remember to check tab order on a dialog (third icon, with blue bars in
designer).

Remember to check sensible resizing behaviour on a dialog. This is
usually done by adding a top-level layout to the dialog in Designer.

Remember to use Edit->Check Accelerators

If necessary, you should override Qt2Base::isValid() for determining the
validity of the current dialog's contents.

OK/Apply/Restore/Close should be connected in the derived class's
constructor to call slotOK() etc. Refer to close/cancel as close in the
source.

Override update_contents() to update the dialog, not update().  Only
these functions may change dialog widgets that may emit changed() during
initialisation, to prevent the button controller from changing its
state.

Never call buttoncontroller functions directly from dialogs. In general,
you should use Qt2Base::changed() in all circumstances. However, if you
must call the buttoncontroller, make sure to respect Qt2Base::updating_

Naming conventions
------------------

QFoo.{cpp,h}     The file that interacts with the controller _and_
the implementation of the dialog, derived from the generated files
ui/FooDialog.ui  The designer file
ui_FooDialog.h   Generated files from FooDialog.ui

slots should be named e.g. slotFooClicked(), slotFooSelected(), where
foo is the name of the widget.

Widgets should be named like "fooXX", where XX is one of the following
widget types :

CB - check box
CO - combo box
ED - line edit
GB - group box
LA - label
LC - LengthCombo
LV - QListView
ML - QTextBrowser
PB - push button
RB - radio button
SB - spin box
SL - slider
TE - text edit
TW - tree widget (FIXME: also TV in some files)


Qt, Unicode, and LyX
--------------------

LyX uses a different encoding (UCS4) than Qt (UTF16), therefore there are a
number of conversion functions in qt_helpers.{cpp,h}. Read the doxygen
documentation for details when to use which function.

Additionally, you should follow these simple rules :

o Use qt_() not _() in code
o Use the conversion functions of qt_helpers.h, NOT .latin1() / .c_str() etc.