]> git.lyx.org Git - lyx.git/blobdiff - src/lyxfunc.h
Dekel's patch -- I didn't fix the xforms-0.88 keysyms stuff so it still doesn't finis...
[lyx.git] / src / lyxfunc.h
index f8a8e906e0d8c78705c54453c2943841e19acc9a..ced5a7dc41c0dd6d73b32f27f908bc88be5d68ab 100644 (file)
@@ -6,12 +6,14 @@
 #pragma interface
 #endif
 
+#include FORMS_H_LOCATION
 #include "commandtags.h"
 #include "kbsequence.h"
 #include "insets/lyxinset.h"
 #include "LString.h"
 
 class LyXView;
+class auto_mem_buffer;
 
 /** This class encapsulates all the LyX command operations. 
     This is the class of the LyX's "high level event handler".
@@ -23,10 +25,15 @@ class LyXFunc {
 public:
        /// The status of a function.
        enum func_status {
-               OK = 0, // No problem
+               /// No problem
+               OK = 0,
+               ///
                Unknown = 1,
-               Disabled = 2, // Command cannot be executed
+               /// Command cannot be executed
+               Disabled = 2,
+               ///
                ToggleOn = 4,
+               ///
                ToggleOff = 8
        };
        ///
@@ -39,9 +46,16 @@ public:
        /// The same but uses the name of a lyx command.
        string Dispatch(string const & cmd);
 
-       /// A keyboard event is processed to execute a lyx action. 
-       int  processKeyEvent(XEvent * ev);
+       /// Same again but for xtl buffers.  Still looking for better idea.
+       bool Dispatch(int action, auto_mem_buffer &);
 
+ #if FL_REVISION < 89
+       /// A keyboard event is processed to execute a lyx action. 
+       int processKeyEvent(XEvent * ev);
+ #else
+       ///
+       int processKeySym(KeySym k, unsigned int state);
+ #endif
        ///
        func_status getStatus(int ac) const;
        
@@ -72,7 +86,6 @@ public:
        
        /// Should a hint message be displayed?
        void setHintMessage(bool);
-
 private:
        ///
        LyXView * owner;
@@ -112,6 +125,7 @@ private:
 
        ///
        void doImport(string const &);
+       ///
        void doImportHelper(string const &, string const &, string const &,
                bool func(BufferView *, string const &) );
 
@@ -169,7 +183,7 @@ void LyXFunc::setHintMessage(bool hm)
        show_sc = hm;
 }
 
-
+///
 inline
 void operator|=(LyXFunc::func_status & fs, LyXFunc::func_status f)
 {