4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
13 #ifndef GMINI_BUFFER_H
14 #define GMINI_BUFFER_H
16 #include "frontends/Timeout.h"
18 class ControlCommandBuffer;
20 class GMiniBuffer : public SigC::Object
23 GMiniBuffer(GView * view, ControlCommandBuffer & control);
25 void message(std::string const & str);
29 bool onKeyPress(GdkEventKey * event);
30 bool onListKeyPress(GdkEventKey * event);
32 bool onListFocusIn(GdkEventFocus * event);
33 bool onFocusIn(GdkEventFocus * event);
34 bool onFocusOut(GdkEventFocus * event);
37 /// Are we in edit mode?
38 bool isEditMode() const;
39 /// reset buffer to stored input text
41 /// go back to "at rest" message
43 /// go into message mode
45 /// show a temporary message whilst in edit mode
46 void showInfo(Glib::ustring const & info, bool append = true);
47 void setInput(Glib::ustring const & input);
48 ControlCommandBuffer & controller_;
52 boost::scoped_ptr<Timeout> infoTimer_;
53 boost::signals::connection infoCon_;
55 boost::scoped_ptr<Timeout> idleTimer_;
56 boost::signals::connection idleCon_;
57 Glib::ustring storedInput_;
58 /// are we showing an informational temporary message ?
60 boost::scoped_ptr<Timeout> focusTimer_;
62 Gtk::ScrolledWindow scrolledWindow_;
63 Gtk::TreeModelColumn<Glib::ustring> listCol_;
64 Gtk::TreeModel::ColumnRecord listCols_;
65 Glib::RefPtr<Gtk::ListStore> listStore_;
66 Gtk::TreeView listView_;
67 Glib::RefPtr<Gtk::TreeSelection> listSel_;