X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Ffrontends%2Fqt4%2FGuiCommandBuffer.h;h=07370875f31cea00c653f266247bae721cb49a2e;hb=425d092204118ea6c24c28e85fdf03fcf2bb51a4;hp=b3a1004d4e9ebde08a0ec92bf92f040e61c7467f;hpb=ff189f6c706d7e79778c7e241478a1dbe07b96a1;p=lyx.git diff --git a/src/frontends/qt4/GuiCommandBuffer.h b/src/frontends/qt4/GuiCommandBuffer.h index b3a1004d4e..07370875f3 100644 --- a/src/frontends/qt4/GuiCommandBuffer.h +++ b/src/frontends/qt4/GuiCommandBuffer.h @@ -16,6 +16,7 @@ #include "support/docstring.h" +#include #include #include @@ -25,7 +26,6 @@ class QListWidgetItem; namespace lyx { namespace frontend { -class LyXView; class GuiView; class GuiCommandEdit; @@ -43,8 +43,10 @@ public Q_SLOTS: void dispatch(); /// tab-complete void complete(); - /// select-complete - void complete_selected(QListWidgetItem *); + /// show history + void listHistoryUp(); + /// called when an item in a list is selected + void itemSelected(QListWidgetItem *); /// up void up(); /// down @@ -54,8 +56,6 @@ public Q_SLOTS: private: /// owning view GuiView * view_; - /// - LyXView & lv_; /// command widget GuiCommandEdit * edit_; @@ -70,6 +70,11 @@ private: /// hide the command buffer. void hide() const; + /// open a listbox and show the contents of the list. When reversed + /// is true, the contents of the list is filled bottom-up. + void showList(std::vector const & list, + QPoint const & pos, bool reversed = false) const; + /// return the possible completions std::vector const completions(std::string const & prefix, std::string & new_prefix); @@ -85,6 +90,12 @@ private: /// current position in command history std::vector::const_iterator history_pos_; + + /// the button up + QPushButton * upPB; + + /// the button down + QPushButton * downPB; }; } // namespace frontend