]> git.lyx.org Git - features.git/blobdiff - src/frontends/controllers/ControlCommandBuffer.h
Replace LString.h with support/std_string.h,
[features.git] / src / frontends / controllers / ControlCommandBuffer.h
index 796d6b4bf99c8d050c21fb09282c58fc4781e2a6..4cbf30721e505ae7851a47bf2452dc5a5b28e95d 100644 (file)
@@ -6,58 +6,58 @@
  *
  * \author Lars
  * \author Asger and Juergen
- * \author John Levon 
+ * \author John Levon
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
 #ifndef CONTROLCOMMANDBUFFER_H
 #define CONTROLCOMMANDBUFFER_H
 
-#include "LString.h"
+#include "support/std_string.h"
 
 #include <vector>
 
-#ifdef __GNUG__
-#pragma interface
-#endif
 
-class LyXFunc;
+class LyXView;
 
 /**
  * ControlCommandBuffer
  *
  * This provides methods for the use of a toolkit's
- * minibuffer/command buffer 
+ * minibuffer/command buffer
  */
 class ControlCommandBuffer {
 public:
-       ControlCommandBuffer(LyXFunc & lf);
-       
+       ControlCommandBuffer(LyXView & lv);
+
        /// return the previous history entry if any
        string const historyUp();
 
        /// return the next history entry if any
        string const historyDown();
 
+       /// return the font and depth in the active BufferView as a message.
+       string const getCurrentState() const;
+
        /// return the possible completions
-       std::vector<string> const completions(string const & prefix, string & new_prefix);
+       std::vector<string> const completions(string const & prefix,
+                                             string & new_prefix);
+
        /// dispatch a command
        void dispatch(string const & str);
 private:
-       /// controlling lyxfunc
-       LyXFunc & lyxfunc_;
-       
+       /// controlling LyXView
+       LyXView & lv_;
+
        /// available command names
        std::vector<string> commands_;
+
        /// command history
        std::vector<string> history_;
 
        /// current position in command history
        std::vector<string>::const_iterator history_pos_;
 };
+
 #endif // CONTROLCOMMANDBUFFER_H