4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
7 * \author Jürgen Spitzmüller
9 * Full author contact details are available in file CREDITS.
12 #ifndef GUISYMBOLSDIALOG_H
13 #define GUISYMBOLSDIALOG_H
15 #include "DialogView.h"
16 #include "ui_SymbolsUi.h"
21 class QListWidgetItem;
26 class GuiSymbols : public DialogView, public Ui::SymbolsUi
31 GuiSymbols(GuiView & lv);
33 /// Dialog inherited methods
36 void dispatchParams();
37 void enableView(bool enable);
38 bool isBufferDependent() const { return true; }
39 virtual kb_action getLfun() const { return LFUN_SELF_INSERT; }
43 void on_applyPB_clicked();
44 void on_okPB_clicked();
45 void on_closePB_clicked();
46 void on_symbolsLW_itemActivated(QListWidgetItem *);
47 void on_symbolsLW_itemClicked(QListWidgetItem * item);
48 void on_categoryCO_activated(QString const & text);
49 void on_categoryFilterCB_toggled(bool);
50 void on_chosenLE_returnPressed();
51 void on_chosenLE_textChanged(QString const &);
54 /** update the widgets (symbol browser, category combo)
55 * \p combo indicates if the combo box has to be refreshed
56 * as well (which is rather expensive)
58 void updateSymbolList(bool update_combo = true);
59 /// get the unicode block associated with \p c
60 QString const getBlock(char_type c) const;
61 /// the encoding at cursor position
62 std::string encoding_;
63 /// which blocks do we actually include?
64 typedef std::map<QString, QListWidgetItem *> UsedBlocks;
66 UsedBlocks used_blocks;
67 /// list of all symbols
68 typedef std::set<char_type> SymbolsList;
73 } // namespace frontend
76 #endif // GUISYMBOLSDIALOG_H