X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Fqt4%2FGuiCharacter.h;h=599807f0ae8a6b1a386a09593256e3cb453a88dc;hb=425d092204118ea6c24c28e85fdf03fcf2bb51a4;hp=faf9716f4c0161aa1167c8c6e07cfe744aa219de;hpb=42015a8ebd17092c9b55c9519015119d04f52218;p=lyx.git diff --git a/src/frontends/qt4/GuiCharacter.h b/src/frontends/qt4/GuiCharacter.h index faf9716f4c..599807f0ae 100644 --- a/src/frontends/qt4/GuiCharacter.h +++ b/src/frontends/qt4/GuiCharacter.h @@ -16,14 +16,15 @@ #include "GuiDialog.h" #include "ui_CharacterUi.h" -#include "qt_helpers.h" // for LanguagePair #include "Font.h" -#include +#include +#ifdef IGNORE +#undef IGNORE +#endif namespace lyx { - namespace frontend { enum FontState { @@ -36,15 +37,23 @@ enum FontState { /// NOUN_TOGGLE, /// + STRIKEOUT_TOGGLE, + /// + UULINE_TOGGLE, + /// + UWAVE_TOGGLE, + /// INHERIT }; +typedef std::pair FamilyPair; typedef std::pair FamilyPair; typedef std::pair SeriesPair; typedef std::pair ShapePair; typedef std::pair SizePair; -typedef std::pair BarPair; -typedef std::pair ColorPair; +typedef std::pair BarPair; +typedef std::pair ColorPair; +typedef std::pair LanguagePair; class GuiCharacter : public GuiDialog, public Ui::CharacterUi { @@ -57,62 +66,31 @@ protected Q_SLOTS: void change_adaptor(); private: - void closeEvent(QCloseEvent * e); - /// Apply changes + /// \name Dialog inherited methods + //@{ void applyView(); - /// update void updateContents(); - - std::vector family; - std::vector series; - std::vector shape; - std::vector size; - std::vector bar; - std::vector color; - std::vector language; - - /// bool initialiseParams(std::string const & data); - /// void clearParams() {} - /// void dispatchParams(); - /// bool isBufferDependent() const { return true; } - /// - kb_action getLfun() const { return LFUN_FONT_FREE_UPDATE; } + FuncCode getLfun() const { return LFUN_TEXTSTYLE_UPDATE; } + void saveSession() const; + void restoreSession(); + //@} /// - void setFamily(FontFamily); - /// - void setSeries(FontSeries); - /// - void setShape(FontShape); - /// - void setSize(FontSize); - /// - void setBar(FontState); - /// - void setColor(ColorCode); - /// - void setLanguage(std::string const &); + void paramsToDialog(Font const & font); - /// - FontFamily getFamily() const; - /// - FontSeries getSeries() const; - /// - FontShape getShape() const; - /// - FontSize getSize() const; - /// - FontState getBar() const; - /// - ColorCode getColor() const; - /// - std::string getLanguage() const; + QList family; + QList series; + QList shape; + QList size; + QList bar; + QList color; + QList language; -private: + /// /// Font font_; ///