]> git.lyx.org Git - lyx.git/blob - src/mathed/math_support.h
Standardise the header blurb in mathed.
[lyx.git] / src / mathed / math_support.h
1 // -*- C++ -*-
2 /**
3  * \file math_support.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Alejandro Aguilar Sierra
8  * \author André Pönitz
9  *
10  * Full author contact details are available in file CREDITS.
11  */
12
13 #ifndef MATH_SUPPORT_H
14 #define MATH_SUPPORT_H
15
16 #include "LString.h"
17
18 class PainterInfo;
19 class LyXFont;
20 class Dimension;
21 class MathArray;
22
23 void mathed_char_dim(LyXFont const &, unsigned char c, Dimension & dim);
24 int mathed_char_width(LyXFont const &, unsigned char c);
25 int mathed_char_ascent(LyXFont const &, unsigned char c);
26 int mathed_char_descent(LyXFont const &, unsigned char c);
27
28 void mathed_draw_deco(PainterInfo & pi, int x, int y, int w, int h,
29         string const & name);
30
31 void mathed_string_dim(LyXFont const & font, string const & s, Dimension & dim);
32 int mathed_string_width(LyXFont const &, string const & s);
33
34 void drawStr(PainterInfo & pi,
35         LyXFont const &, int x, int y, string const & s);
36 void drawStrRed(PainterInfo & pi, int x, int y, string const & s);
37 void drawStrBlack(PainterInfo & pi, int x, int y, string const & s);
38 void drawChar(PainterInfo & pi, LyXFont const & font, int x, int y, char c);
39
40 void math_font_max_dim(LyXFont const &, int & asc, int & desc);
41
42 void augmentFont(LyXFont & f, string const & cmd);
43
44 bool isFontName(string const & name);
45
46 // converts single cell to string
47 string asString(MathArray const & ar);
48 // converts string to single cell
49 void asArray(string const & str, MathArray & ar);
50
51 #endif