3 * \file ControlCommandBuffer.h
4 * Read the file COPYING
7 * \author Asger and Juergen
10 * Full author contact details are available in file CREDITS
13 #ifndef CONTROLCOMMANDBUFFER_H
14 #define CONTROLCOMMANDBUFFER_H
27 * ControlCommandBuffer
29 * This provides methods for the use of a toolkit's
30 * minibuffer/command buffer
32 class ControlCommandBuffer {
34 ControlCommandBuffer(LyXFunc & lf);
36 /// return the previous history entry if any
37 string const historyUp();
39 /// return the next history entry if any
40 string const historyDown();
42 /// return the possible completions
43 std::vector<string> const completions(string const & prefix, string & new_prefix);
45 /// dispatch a command
46 void dispatch(string const & str);
49 /// controlling lyxfunc
52 /// available command names
53 std::vector<string> commands_;
56 std::vector<string> history_;
58 /// current position in command history
59 std::vector<string>::const_iterator history_pos_;
62 #endif // CONTROLCOMMANDBUFFER_H