mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-13 14:32:04 +00:00
0f9678630c
Add them as appropriate to .C files. Rename Voss as Vo�, Juergen as J�rgen and Spitzmueller as Spitzm�ller. Happy compiling. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@7701 a592a061-630c-0410-9148-cb99ea01b6c8
64 lines
1.3 KiB
C++
64 lines
1.3 KiB
C++
// -*- C++ -*-
|
|
/**
|
|
* \file ControlCommandBuffer.h
|
|
* This file is part of LyX, the document processor.
|
|
* Licence details can be found in the file COPYING.
|
|
*
|
|
* \author Lars
|
|
* \author Asger and Jürgen
|
|
* \author John Levon
|
|
*
|
|
* Full author contact details are available in file CREDITS.
|
|
*/
|
|
|
|
#ifndef CONTROLCOMMANDBUFFER_H
|
|
#define CONTROLCOMMANDBUFFER_H
|
|
|
|
#include "support/std_string.h"
|
|
|
|
#include <vector>
|
|
|
|
|
|
class LyXView;
|
|
|
|
/**
|
|
* ControlCommandBuffer
|
|
*
|
|
* This provides methods for the use of a toolkit's
|
|
* minibuffer/command buffer
|
|
*/
|
|
class ControlCommandBuffer {
|
|
public:
|
|
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);
|
|
|
|
/// dispatch a command
|
|
void dispatch(string const & str);
|
|
private:
|
|
/// 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
|