]> git.lyx.org Git - lyx.git/blob - src/bufferview_funcs.h
tostr -> convert and some bformat work
[lyx.git] / src / bufferview_funcs.h
1 // -*- C++ -*-
2 /**
3  * \file bufferview_funcs.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Lars Gullik Bjønnes
8  * \author Jean-Marc Lasgouttes
9  * \author Angus Leeming
10  *
11  * Full author contact details are available in file CREDITS.
12  */
13
14 #ifndef BUFFERVIEW_FUNCS_H
15 #define BUFFERVIEW_FUNCS_H
16
17 #include <string>
18
19 class LyXFont;
20 class Point;
21 class DocIterator;
22 class BufferView;
23
24
25 namespace bv_funcs {
26
27 /// Set \param data using \param font and \param toggle. Return success.
28 bool font2string(LyXFont const & font, bool toggle, std::string & data);
29
30 /// Set \param font and \param toggle using \param data. Return success.
31 bool string2font(std::string const & data, LyXFont & font, bool & toggle);
32
33 /** Returns the current freefont, encoded as a std::string to be passed to the
34  *  frontends.
35  */
36 std::string const freefont2string();
37
38 Point getPos(DocIterator const & dit);
39
40 enum CurStatus {
41         CUR_INSIDE,
42         CUR_ABOVE,
43         CUR_BELOW
44 };
45
46
47 CurStatus status(BufferView const * bv, DocIterator const & dit);
48
49
50 Point coordOffset(DocIterator const & dit);
51
52
53 } // namespace bv_funcs
54
55 #endif