lyx_mirror/src/frontends/qt4
Michael Schmitt 1e7479247a * src/frontend/qt4/ui/NomenclUi.ui: fix tab order (by Ugras Baran)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18008 a592a061-630c-0410-9148-cb99ea01b6c8
2007-04-25 21:37:43 +00:00
..
ui * src/frontend/qt4/ui/NomenclUi.ui: fix tab order (by Ugras Baran) 2007-04-25 21:37:43 +00:00
Action.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
Action.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
Alert_pimpl.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
BulletsModule.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
BulletsModule.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
ChangeLog
checkedwidgets.C Fix for bug 3215. All changes in src/frontends/qt4/. 2007-04-05 14:58:15 +00:00
checkedwidgets.h Fix for bug 3215. All changes in src/frontends/qt4/. 2007-04-05 14:58:15 +00:00
ColorCache.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
ColorCache.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
Dialogs.C merge QViewSource and QViewSourceDialog 2007-04-24 14:08:53 +00:00
DockView.h
emptytable.C
emptytable.h
FileDialog_private.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
FileDialog_private.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
FileDialog.C
FloatPlacement.C Rename insets/insetxxx to insets/InsetXxx, part 1 2007-04-25 01:24:38 +00:00
FloatPlacement.h
GuiApplication.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiApplication.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiClipboard.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiClipboard.h
GuiFontLoader.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiFontLoader.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiFontMetrics.C
GuiFontMetrics.h
GuiImplementation.C
GuiImplementation.h
GuiSelection.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiSelection.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiView.C * frontends/LyXView.h: 2007-04-21 17:38:43 +00:00
GuiView.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiWorkArea.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
GuiWorkArea.h
iconpalette.C * remove old iconpalette (and rename iconpanel to iconpalette) 2007-04-19 22:01:28 +00:00
iconpalette.h Compilation fixes: 2007-04-20 07:29:02 +00:00
InsertTableWidget.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
InsertTableWidget.h
lengthcombo.C
lengthcombo.h
LyXKeySymFactory.C
Makefile.am more dialog merging 2007-04-25 10:57:54 +00:00
Makefile.dialogs more dialog merging 2007-04-25 10:57:54 +00:00
panelstack.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
panelstack.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
pch.h
QAbout.C merge QAbout and QAboutDialog 2007-04-24 11:32:09 +00:00
QAbout.h merge QAbout and QAboutDialog 2007-04-24 11:32:09 +00:00
QBibitem.C more dialog merging 2007-04-25 08:42:22 +00:00
QBibitem.h more dialog merging 2007-04-25 08:42:22 +00:00
QBibtex.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QBibtex.h more dialog merging 2007-04-25 08:42:22 +00:00
QBox.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QBox.h merge QBox and QBoxDialog 2007-04-24 10:56:22 +00:00
QBranch.C more dialog merging 2007-04-25 08:42:22 +00:00
QBranch.h more dialog merging 2007-04-25 08:42:22 +00:00
QBranches.C
QBranches.h
QChanges.C more dialog merging 2007-04-25 10:25:37 +00:00
QChanges.h more dialog merging 2007-04-25 10:25:37 +00:00
QCharacter.C more dialog merging 2007-04-25 10:57:54 +00:00
QCharacter.h merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QCitation.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QCitation.h
QCitationDialog.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QCitationDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QCommandBuffer.C * QCommandBuffer::complete(): Add connection to QListWidget::itemActivated() in order to select in the help list with "Enter". 2007-04-19 16:43:09 +00:00
QCommandBuffer.h
QCommandEdit.C
QCommandEdit.h
QDelimiterDialog.C Pass the main window (GuiView) to the delimiter dialog so that it is properly handled by the window manager. 2007-04-22 07:54:36 +00:00
QDelimiterDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QDialogView.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QDialogView.h
QDocument.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QDocument.h more dialog merging 2007-04-25 10:25:37 +00:00
QErrorList.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QErrorList.h more dialog merging 2007-04-25 10:25:37 +00:00
QERT.C merge QERT and QERTDialog 2007-04-24 13:47:33 +00:00
QERT.h merge QERT and QERTDialog 2007-04-24 13:47:33 +00:00
QExternal.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QExternal.h more dialog merging 2007-04-25 08:42:22 +00:00
QFloat.C Rename insets/insetxxx to insets/InsetXxx, part 1 2007-04-25 01:24:38 +00:00
QFloat.h
QFloatDialog.C
QFloatDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
qfontexample.C
qfontexample.h
QGraphics.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QGraphics.h
QGraphicsDialog.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QGraphicsDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QGraphicsUi.h
QInclude.C more dialog merging 2007-04-25 10:57:54 +00:00
QInclude.h more dialog merging 2007-04-25 10:57:54 +00:00
QIndex.C more dialog merging 2007-04-25 08:42:22 +00:00
QIndex.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLImage.C
QLImage.h
qlkey.h
QLMenubar.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLMenubar.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLog.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLog.h more Foo/FooDialog merge 2007-04-24 19:37:34 +00:00
QLPainter.C
QLPainter.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLPopupMenu.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLPopupMenu.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLPrintDialog.C
QLPrintDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QLToolbar.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QLToolbar.h * Action.[Ch] 2007-04-19 20:29:27 +00:00
QLyXKeySym.C
QLyXKeySym.h
QMathMatrixDialog.C * removal of math panel 2007-04-19 21:42:42 +00:00
QMathMatrixDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QNomencl.C more dialog merging 2007-04-25 10:57:54 +00:00
QNomencl.h more dialog merging 2007-04-25 10:57:54 +00:00
QNote.C more dialog merging 2007-04-25 10:57:54 +00:00
QNote.h more dialog merging 2007-04-25 10:57:54 +00:00
QParagraph.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QParagraph.h more Foo/FooDialog merge 2007-04-24 19:37:34 +00:00
QPrefs.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QPrefs.h more dialog merging 2007-04-25 10:57:54 +00:00
QPrint.C
QPrint.h
QRef.C more dialog merging 2007-04-25 10:57:54 +00:00
QRef.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QSearch.C merge QSearch and QSearchDialog 2007-04-24 13:27:23 +00:00
QSearch.h merge QSearch and QSearchDialog 2007-04-24 13:27:23 +00:00
QSendto.C more dialog merging 2007-04-25 10:57:54 +00:00
QSendto.h more dialog merging 2007-04-25 10:57:54 +00:00
qsetborder.C
qsetborder.h
QShowFile.C more Foo/FooDialog merge 2007-04-24 19:37:34 +00:00
QShowFile.h more Foo/FooDialog merge 2007-04-24 19:37:34 +00:00
QSpellchecker.C merge QSpellChecker and QSpellcheckerDialog 2007-04-24 15:32:14 +00:00
QSpellchecker.h merge QSpellChecker and QSpellcheckerDialog 2007-04-24 15:32:14 +00:00
Qt2BC.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
Qt2BC.h code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
qt_helpers.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
qt_helpers.h Fix for bug 3215. All changes in src/frontends/qt4/. 2007-04-05 14:58:15 +00:00
QTabular.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QTabular.h merge the tabular/gui related files 2007-04-24 17:46:08 +00:00
QTabularCreate.C merge the tabular/gui related files 2007-04-24 17:46:08 +00:00
QTabularCreate.h merge the tabular/gui related files 2007-04-24 17:46:08 +00:00
QTexinfo.C merge QTexinfo and QTexinfoDialog 2007-04-24 15:10:14 +00:00
QTexinfo.h merge QTexinfo and QTexinfoDialog 2007-04-24 15:10:14 +00:00
QThesaurus.C merge QThesaurus and QThesaurusDialog 2007-04-24 14:35:15 +00:00
QThesaurus.h merge QThesaurus and QThesaurusDialog 2007-04-24 14:35:15 +00:00
QToc.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
QToc.h add GuiView parent to QToc for proper memory management. 2007-04-07 00:04:38 +00:00
qtTimeout.C
qtTimeout.h
QURLDialog.C
QURLDialog.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
QViewSource.C merge QViewSource and QViewSourceDialog 2007-04-24 14:08:53 +00:00
QViewSource.h merge QViewSource and QViewSourceDialog 2007-04-24 14:08:53 +00:00
QVSpace.C merge src/frontends/controllers/biblio, character, frnt_lang, helper_funcs and tex_helpers to frontend_helpers, step 3 2007-04-25 17:53:54 +00:00
QVSpace.h merge QVSpace and QVSpaceDialog 2007-04-24 12:02:27 +00:00
QWrap.C Rename insets/insetxxx to insets/InsetXxx, part 1 2007-04-25 01:24:38 +00:00
QWrap.h merge QWrapDialog and QWrap 2007-04-24 14:59:51 +00:00
README renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
socket_callback.C
socket_callback.h
TocModel.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
TocModel.h
TocWidget.C Fix loop when opening TOC widget in an empty document, basically by Richard Heck. 2007-04-17 10:27:53 +00:00
TocWidget.h renaming in frontends/qt4/ui: s/Q//g 2007-04-24 08:56:28 +00:00
UrlView.C
UrlView.h
validators.C code cosmetics whitespace, unneeded lyx:: qualification, indentation, unneeded destructors and the like 2007-04-25 16:39:21 +00:00
validators.h Fix for bug 3215. All changes in src/frontends/qt4/. 2007-04-05 14:58:15 +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/FooDialog.ui       The designer file
ui/FooDialogBase.[Ch] 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)


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.