lyx_mirror/src/frontends/qt4
Georg Baum 9281cd4675 We use char_type, not size_t for storing UCS4 characters.
This may make a difference when char_type is signed.

	* src/frontends/LyXKeySym.h
	(getUCSEncoded): change return type from size_t to char_type

	* src/frontends/qt4/QLyXKeySym.[Ch]
	(getUCSEncoded): ditto

	* src/lyxfunc.C
	(LyXFunc::processKeySym): adjust to the above and add a FIXME since
	this is strange code that looks like it was not intended to do what
	it does.

	* src/lyxfunc.h
	(encoded_last_key): Correct documentation


git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@16833 a592a061-630c-0410-9148-cb99ea01b6c8
2007-01-24 14:01:34 +00:00
..
ui * output_plaintext.C: cosmetics in comment: line length cannot be < 0 2007-01-20 14:51:40 +00:00
Action.C Cleanup Action class: The mother should be the main window (GuiView). This will hopefully fix bug 3107 (Tooltips not showing on main window). 2007-01-22 11:31:42 +00:00
Action.h Cleanup Action class: The mother should be the main window (GuiView). This will hopefully fix bug 3107 (Tooltips not showing on main window). 2007-01-22 11:31:42 +00:00
Alert_pimpl.C With this commit, errors and warnings can use message box even before LyX is properly initialized. This is especially useful for missing sysdir and/or userdir directory. 2007-01-23 12:38:20 +00:00
BulletsModule.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
BulletsModule.h * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
ChangeLog set svn:eol-style to native in qt4 frontend 2006-03-21 19:56:57 +00:00
checkedwidgets.C get rid of QT3_SUPPORT and some cleanup 2006-08-17 08:43:48 +00:00
checkedwidgets.h get rid of QT3_SUPPORT and some cleanup 2006-08-17 08:43:48 +00:00
ColorCache.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
ColorCache.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
Dialogs.C replace "Notation Entry" by "Glossary Entry" and "Notation List" by "Glossary" 2006-11-07 22:28:53 +00:00
emptytable.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
emptytable.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
FileDialog_private.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
FileDialog_private.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
FileDialog.C remove unneeded extra lyx:: namespace qualifier 2007-01-18 15:20:33 +00:00
FloatPlacement.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
FloatPlacement.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
GuiApplication.C Fix another selection bug 2007-01-05 10:11:21 +00:00
GuiApplication.h * GuiApplication.C (GuiApplication): make sure that the Qtranslator 2007-01-04 11:05:57 +00:00
GuiClipboard.C Fix bug 2138: copy and paste should preserve formatting between different 2007-01-13 18:29:50 +00:00
GuiClipboard.h Fix bug 2138: copy and paste should preserve formatting between different 2007-01-13 18:29:50 +00:00
GuiFontLoader.C convert LyXFont::stateText and LColor::getGUIName to docstring, 2006-12-21 14:31:19 +00:00
GuiFontLoader.h This commit is a big rework of the FontLoader/FontMetrics interaction. Only Qt4 for now, I would be grateful is somebody steps up for qt3 and gtk. 2006-10-07 16:15:06 +00:00
GuiFontMetrics.C Fix returned width for small caps (these values are not cached, though) 2006-12-09 07:07:00 +00:00
GuiFontMetrics.h * enable font metrics cache for all platforms. 2006-12-04 10:09:22 +00:00
GuiImplementation.C Fix this error message on startup: 2006-12-21 12:01:35 +00:00
GuiImplementation.h Clean up quit code. 2006-12-02 17:39:31 +00:00
GuiSelection.C Fix enabling of LFUN_PRIMARY_SELECTION_PASTE: It was always disabled, because 2007-01-08 18:37:40 +00:00
GuiSelection.h Fix enabling of LFUN_PRIMARY_SELECTION_PASTE: It was always disabled, because 2007-01-08 18:37:40 +00:00
GuiView.C The Mac doesn't need a offset for the save/restore window position code 2007-01-14 17:14:31 +00:00
GuiView.h Fix focus on WorkArea after mini-buffer command. 2006-12-23 17:09:50 +00:00
GuiWorkArea.C * LyXView.C: 2007-01-18 21:47:27 +00:00
GuiWorkArea.h * LyXView.C: 2007-01-18 21:47:27 +00:00
iconpalette.C fix: http://bugzilla.lyx.org/show_bug.cgi?id=452 2006-12-17 17:36:00 +00:00
iconpalette.h * allow resizing of detached panel 2006-11-21 09:06:12 +00:00
InsertTableWidget.C This commit cleans up everything related to singleton. The other important change is that lyx::dispatch() and lyx::getStatus become _the_ official way to use LyXFunc equivalent methods. 2006-10-11 17:24:46 +00:00
InsertTableWidget.h make sure eol-style native is set and fix eol style 2006-06-30 14:50:44 +00:00
lengthcombo.C * qt4/QExternal.C: 2006-12-03 01:11:37 +00:00
lengthcombo.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
LyXKeySymFactory.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
Makefile.am New nomenclature inset from Ugras 2006-11-04 17:55:36 +00:00
Makefile.dialogs * development/scons/scons_manifest.py: 2007-01-16 22:29:33 +00:00
panelstack.C Make string conversion work with non-ucs2-characters if using qt 4.2 2006-12-04 13:50:46 +00:00
panelstack.h small cosmetic cleanups: 2006-10-30 14:39:05 +00:00
pch.h delete some Qt "signals" macro reference. 2006-07-10 17:44:36 +00:00
QAbout.C Convert the CREDITS file to utf8 and spell Ugras' name correctly. 2006-11-04 12:46:00 +00:00
QAbout.h
QAboutDialog.C Remove quite a few compiler warnings: 2006-07-06 08:18:51 +00:00
QAboutDialog.h
QBibitem.C Use the new InsetCommandParams interface (frontend part), from Ugras and me 2006-10-20 13:53:43 +00:00
QBibitem.h
QBibitemDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QBibitemDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QBibtex.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QBibtex.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QBibtexDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QBibtexDialog.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QBox.C * qt4/QExternal.C: 2006-12-03 01:11:37 +00:00
QBox.h get rid of more utf8 conversions 2006-12-21 20:52:59 +00:00
QBoxDialog.C * src/frontends/qt4/QBoxDialog.C: 2006-11-12 11:25:20 +00:00
QBoxDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QBranch.C Fix problem with non-ascii branch names by converting more stuff to 2006-11-03 15:16:45 +00:00
QBranch.h
QBranchDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QBranchDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QBranches.C * src/frontends/qt4/QBranches.C: 2006-11-04 15:08:53 +00:00
QBranches.h * src/frontends/qt4/QBranches.C: 2006-11-04 15:08:53 +00:00
QChanges.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QChanges.h
QChangesDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QChangesDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QCharacter.C * src/frontends/qt4/QCharacter.C: 2007-01-07 10:24:25 +00:00
QCharacter.h
QCharacterDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QCharacterDialog.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QCitation.C Convert most of the bibtex machinery to docstring. 2006-12-17 10:52:04 +00:00
QCitation.h more cleanup: 2006-12-15 09:58:44 +00:00
QCitationDialog.C Fix rest of bug 3068. 2007-01-08 06:52:20 +00:00
QCitationDialog.h Fix rest of bug 3068. 2007-01-08 06:52:20 +00:00
QCommandBuffer.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
QCommandBuffer.h Fix focus on WorkArea after mini-buffer command. 2006-12-23 17:09:50 +00:00
QCommandEdit.C make macrfos readable again 2006-10-22 14:37:32 +00:00
QCommandEdit.h make macrfos readable again 2006-10-22 14:37:32 +00:00
QDelimiterDialog.C po/de.po: 2006-12-10 10:07:31 +00:00
QDelimiterDialog.h rework mathdelimiter dialog and add size combo... 2006-08-16 14:22:47 +00:00
QDialogView.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QDialogView.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QDocument.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QDocument.h
QDocumentDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QDocumentDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QErrorList.C Fix another non-ascii filename related assertion 2007-01-10 17:18:41 +00:00
QErrorList.h get rid of convenience classes in the following dialogs (and associated implementation files): 2006-05-03 19:51:15 +00:00
QErrorListDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QErrorListDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QERT.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QERT.h
QERTDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QERTDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QExternal.C Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
QExternal.h
QExternalDialog.C * src/frontends/qt4/QBoxDialog.C: 2006-11-12 11:25:20 +00:00
QExternalDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QFloat.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QFloat.h
QFloatDialog.C minimal effort implementation of: 2006-08-25 13:40:01 +00:00
QFloatDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
qfontexample.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
qfontexample.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QGraphics.C Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
QGraphics.h
QGraphicsDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QGraphicsDialog.h * reorganisation of graphics dialog 2006-11-03 11:24:27 +00:00
QGraphicsUi.h
QInclude.C Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
QInclude.h
QIncludeDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QIncludeDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QIndex.C Use the new InsetCommandParams interface (frontend part), from Ugras and me 2006-10-20 13:53:43 +00:00
QIndex.h Patch 1 Log: 2006-10-09 10:35:14 +00:00
QIndexDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QIndexDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QLImage.C Next step of true unicode filenames: Use support::FileName instead of 2006-11-26 21:30:39 +00:00
QLImage.h Next step of true unicode filenames: Use support::FileName instead of 2006-11-26 21:30:39 +00:00
qlkey.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QLMenubar.C * src/MenuBackend.[Ch]: the specialMenu is now a real menu, not a 2007-01-03 11:59:10 +00:00
QLMenubar.h Change MenuBackend and the other menuclasses to store a docstring. Do the required updates to lstrings/convert. 2006-09-09 22:27:22 +00:00
QLog.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QLog.h
QLogDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QLogDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QLPainter.C - Get rid of manifestly expensive debugging output in the most critical path in LyX 2006-11-07 22:17:12 +00:00
QLPainter.h small cleanup while looking for a bug. 2006-10-30 14:15:05 +00:00
QLPopupMenu.C Make the shortcuts work correctly with the mac. 2007-01-04 17:10:24 +00:00
QLPopupMenu.h * QLMenubar.C (macxMenuBarInit): fix workaround for menu merging 2006-12-20 14:28:06 +00:00
QLPrintDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QLPrintDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QLToolbar.C Cleanup Action class: The mother should be the main window (GuiView). This will hopefully fix bug 3107 (Tooltips not showing on main window). 2007-01-22 11:31:42 +00:00
QLToolbar.h Session/Toolbars: 2006-11-02 16:01:36 +00:00
QLyXKeySym.C We use char_type, not size_t for storing UCS4 characters. 2007-01-24 14:01:34 +00:00
QLyXKeySym.h We use char_type, not size_t for storing UCS4 characters. 2007-01-24 14:01:34 +00:00
QMath.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QMath.h
QMathDialog.C Next step of true unicode filenames: Use support::FileName instead of 2006-11-26 21:30:39 +00:00
QMathDialog.h * show symbol panels in proper size when detached from math panel (always layed out in 5 cols) 2006-11-19 17:12:33 +00:00
QMathMatrixDialog.C * src/frontends/qt4/QMathMatrixDialog.C: 2007-01-03 21:51:10 +00:00
QMathMatrixDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QNomencl.C New nomenclature inset from Ugras 2006-11-04 17:55:36 +00:00
QNomencl.h New nomenclature inset from Ugras 2006-11-04 17:55:36 +00:00
QNomenclDialog.C New nomenclature inset from Ugras 2006-11-04 17:55:36 +00:00
QNomenclDialog.h New nomenclature inset from Ugras 2006-11-04 17:55:36 +00:00
QNote.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QNote.h
QNoteDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QNoteDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QParagraph.C convert more GUI strings to docstring 2006-12-22 10:06:40 +00:00
QParagraph.h
QParagraphDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QParagraphDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QPrefs.C This commit is purely mechanical and get rid of lyx_gui.[Ch]. 2006-10-12 14:10:13 +00:00
QPrefs.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QPrefsDialog.C Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
QPrefsDialog.h * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QPrint.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QPrint.h
QRef.C Fix bug 3063, the problem was a recursive call to QRef::gotoRef() (which indirectly call 2007-01-18 21:06:49 +00:00
QRef.h Convert labels to unicode 2006-10-12 10:50:45 +00:00
QRefDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QRefDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QSearch.C convert thesaurus and spellchecker to docstring 2006-12-10 11:52:46 +00:00
QSearch.h convert thesaurus and spellchecker to docstring 2006-12-10 11:52:46 +00:00
QSearchDialog.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
QSearchDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QSendto.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QSendto.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QSendtoDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QSendtoDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
qsetborder.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
qsetborder.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QShowFile.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QShowFile.h
QShowFileDialog.C Qt4 compilation speedup patch by Bo Peng and me. 2006-05-18 08:51:12 +00:00
QShowFileDialog.h
QSpellchecker.C Fix spell two checker bugs. The reason for both bugs was a string->docstring 2006-12-10 19:00:57 +00:00
QSpellchecker.h
QSpellcheckerDialog.C get rid of QT3_SUPPORT and some cleanup 2006-08-17 09:00:11 +00:00
QSpellcheckerDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
Qt2BC.C even more unicode work... 2006-10-09 13:28:32 +00:00
Qt2BC.h even more unicode work... 2006-10-09 13:28:32 +00:00
qt_helpers.C Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
qt_helpers.h Fix several filename and environment variable encoding problems 2007-01-18 20:47:27 +00:00
QTabular.C Fix bug 3067: Special column attributes can contain non-ascii characters, 2007-01-05 17:11:32 +00:00
QTabular.h
QTabularCreate.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QTabularCreate.h
QTabularCreateDialog.C Add new tableinsertwidget 2006-05-31 12:53:05 +00:00
QTabularCreateDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QTabularDialog.C * avoid signal triggered by setChecked(bool) 2007-01-16 12:24:49 +00:00
QTabularDialog.h * avoid signal triggered by setChecked(bool) 2007-01-16 12:24:49 +00:00
QTexinfo.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QTexinfo.h
QTexinfoDialog.C get rid of QT3_SUPPORT and some cleanup 2006-08-17 09:01:25 +00:00
QTexinfoDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QThesaurus.C convert thesaurus and spellchecker to docstring 2006-12-10 11:52:46 +00:00
QThesaurus.h
QThesaurusDialog.C convert thesaurus and spellchecker to docstring 2006-12-10 11:52:46 +00:00
QThesaurusDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QToc.C coding style: fix crash on buffer-switching (2 tabs) + toc-clicking 2007-01-19 22:17:01 +00:00
QToc.h Toc Slider fixes from Ugras Baran. 2006-11-25 22:16:22 +00:00
QTocDialog.C * src/frontends/qt4/QTocDialog.C (updateGui): 2007-01-07 16:39:35 +00:00
QTocDialog.h Toc Slider fixes from Ugras Baran. 2006-11-25 22:16:22 +00:00
qtTimeout.C move everything into namespace lyx 2006-10-21 00:16:43 +00:00
qtTimeout.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
QURLDialog.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
QURLDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QViewSource.C FIXME: remove global variable theApp 2006-11-30 00:04:51 +00:00
QViewSource.h Add more controls to the view-source dialog. 2006-08-04 13:59:12 +00:00
QViewSourceDialog.C * replace many toggled(bool) with changed() signals 2007-01-17 13:06:16 +00:00
QViewSourceDialog.h Add more controls to the view-source dialog. 2006-08-04 13:59:12 +00:00
QVSpace.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QVSpace.h
QVSpaceDialog.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
QVSpaceDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
QWrap.C Patch 1 Log: 2006-10-09 10:35:14 +00:00
QWrap.h
QWrapDialog.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
QWrapDialog.h Make signals and slots to not be defined, and replace them with Q_SIGNALS and Q_SLOTS 2006-06-30 14:37:33 +00:00
README Fix incorrect conversion from QString to std::string. lyxerr output is wrong 2006-12-08 08:57:57 +00:00
socket_callback.C undo last acedential checkin 2006-12-30 10:30:02 +00:00
socket_callback.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00
TocModel.C Toc Slider fixes from Ugras Baran. 2006-11-25 22:16:22 +00:00
TocModel.h Toc Slider fixes from Ugras Baran. 2006-11-25 22:16:22 +00:00
UrlView.C Use the new InsetCommandParams interface (frontend part), from Ugras and me 2006-10-20 13:53:43 +00:00
UrlView.h QURL renamed to UrlView 2006-06-28 12:09:25 +00:00
validators.C remove unneeded conversions 2006-12-21 19:02:17 +00:00
validators.h move everything into namespace lyx 2006-10-21 00:16:43 +00:00

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
form_->changed(). If you are using a more complicated thing anyway,
then remember to call form_->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 is incredibly stupid and sometimes you need 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.

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 form_->slotOK() etc. Refer to close/cancel as close in the source.

Override update_contents() to update the dialog, not update(), and build_dialog(),
not build(). 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.[Ch]              The file that interacts with the controller
QFooDialog.[Ch]        The implementation of the dialog, derived from the generated files
ui/QFooDialog.ui       The designer file
ui/QFooDialogBase.[Ch] Generated files from QFooDialog.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
LA - label
ML -
PB - push button
(FIXME: complete this)


Stuff to be aware of
--------------------

The connect statement in Qt is a macro and its arguments does not follow
the C++ standard as it should. Using the construct "Type const &" as
argument will lead to runtime-errors, use "const Type &" instead.

ex.

--right--

	connect(list, SIGNAL(selected(const QString &)),
		this, SLOT(complete_selected(const QString &)));

--wrong--

	connect(list, SIGNAL(selected(QString const &)),
		this, SLOT(complete_selected(QString const &)));

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

LyX uses a different encoding (UCS4) than Qt (UTF16), therefore there are a
number of conversion functions in qt_helpers.[Ch]. 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.