]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/xforms/XMiniBuffer.h
Introduce LFUN_PRINT.
[lyx.git] / src / frontends / xforms / XMiniBuffer.h
index 41b5617b220643863efe752cd4311c7c1a86f18c..9ed98d50d27654e385bb212e653cf4f0a893a58b 100644 (file)
@@ -5,22 +5,24 @@
  * Licence details can be found in the file COPYING.
  *
  * \author Lars
- * \author Asger and Juergen
+ * \author Asger and JΓΌrgen
  * \author John Levon
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
 #ifndef XMINIBUFFER_H
 #define XMINIBUFFER_H
 
-#include FORMS_H_LOCATION
+#include "lyx_forms.h"
 
 #include <boost/scoped_ptr.hpp>
+#include <boost/shared_ptr.hpp>
 #include <boost/signals/connection.hpp>
 
+struct fl_freebrowser_;
+typedef fl_freebrowser_ FL_FREEBROWSER;
 
-class DropDown;
 class ControlCommandBuffer;
 class Timeout;
 
@@ -28,15 +30,12 @@ class Timeout;
 class XMiniBuffer {
 public:
        ///
-       XMiniBuffer(XFormsView * o, ControlCommandBuffer & control,
+       XMiniBuffer(ControlCommandBuffer & control,
                    FL_Coord x, FL_Coord y, FL_Coord h, FL_Coord w);
 
        ///
        ~XMiniBuffer();
 
-       /// create drop down
-       void dd_init();
-
        /// repaint the minibuffer
        void redraw();
 
@@ -44,7 +43,7 @@ public:
        int peek_event(FL_OBJECT *, int, int, XEvent * xev);
 
        /// show a message
-       void message(string const & str);
+       void message(std::string const & str);
 
        /// focus the buffer for editing mode
        void focus() { messageMode(false); }
@@ -52,6 +51,9 @@ public:
        /// disable event management
        void freeze();
 
+       /// xforms callback routine
+       void freebrowserCB(int action);
+
 private:
        /// Are we in editing mode?
        bool isEditingMode() const;
@@ -62,29 +64,17 @@ private:
        /// go back to "at rest" message
        void idle_timeout();
 
-       /**
-        * Append "c" to the current input contents when the completion
-        * list is displayed and has focus.
-        */
-       void append_char(char c);
-
-       /// completion selection callback
-       void set_complete_input(string const & str);
-
        /// set the minibuffer content in editing mode
-       void set_input(string const &);
-
-       /// This creates the input widget for the minibuffer
-       FL_OBJECT * create_input_box(int, FL_Coord, FL_Coord, FL_Coord, FL_Coord);
+       void set_input(std::string const &);
 
        /// go into message mode
        void messageMode(bool on = true);
 
        /// show a temporary message whilst in edit mode
-       void show_info(string const & info, string const & input, bool append = true);
+       void show_info(std::string const & info, std::string const & input, bool append = true);
 
        /// the dropdown menu
-       boost::scoped_ptr<DropDown> dropdown_;
+       boost::shared_ptr<FL_FREEBROWSER> freebrowser_;
 
        /// info timer
        boost::scoped_ptr<Timeout> info_timer_;
@@ -100,20 +90,15 @@ private:
        boost::signals::connection result_con;
        ///
        boost::signals::connection keypress_con;
-       /// This is the input widget object
-       FL_OBJECT * the_buffer_;
 
-       /// the input box
-       FL_OBJECT * input_obj_;
+       /// This is the input widget object
+       FL_OBJECT * input_;
 
        /// the controller we use
        ControlCommandBuffer & controller_;
 
-       /// the lyx view
-       XFormsView * view_;
-
        /// stored input when showing info
-       string stored_input_;
+       std::string stored_input_;
 
        /// are we showing an informational temporary message ?
        bool info_shown_;