~ubuntu-branches/ubuntu/breezy/koffice/breezy

« back to all changes in this revision

Viewing changes to kword/filters/mif/treebuild_general.h

  • Committer: Bazaar Package Importer
  • Author(s): Ben Burton
  • Date: 2004-05-09 11:33:00 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20040509113300-vfrdadqsvjfuhn3b
Tags: 1:1.3.1-1
* New upstream bugfix release.
* Built against newer imagemagick (closes: #246623).
* Made koffice-libs/kformula recommend/depend on latex-xft-fonts, which
  provides mathematical fonts that the formula editor can use.  Also
  patched the kformula part to make these fonts the default.
* Changed kword menu hint from "WordProcessors" to "Word processors"
  (closes: #246209).
* Spellchecker configuration is now fixed (closes: #221256, #227568).

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
/* $Id: treebuild_general.h,v 1.5 1999/10/20 10:28:31 kulow Exp $
2
 
 *
3
 
 * This file is part of MIFParse, a MIF parser for Unix.
4
 
 *
5
 
 * Copyright (C) 1998 by Matthias Kalle Dalheimer <kalle@dalheimer.de>
6
 
 */
7
 
 
8
 
#ifndef _TREEBUILD_GENERAL
9
 
#define _TREEBUILD_GENERAL
10
 
 
11
 
#include <qlist.h>
12
 
#include <qstring.h>
13
 
 
14
 
class ShapeRect;
15
 
class BRect;
16
 
class GroupID;
17
 
class DashedPattern;
18
 
class RunAroundGap;
19
 
class RunAroundType;
20
 
class Separation;
21
 
class PenWidth;
22
 
class ObColor;
23
 
class Fill;
24
 
class Unique
25
 
{
26
 
public:
27
 
        Unique( int );
28
 
 
29
 
        int value() const { return _value; }
30
 
 
31
 
private:
32
 
        int _value;
33
 
};
34
 
 
35
 
class FrameID
36
 
{
37
 
public:
38
 
        FrameID( int );
39
 
        int id() const { return _value; }
40
 
 
41
 
private:
42
 
        int _value;
43
 
};
44
 
 
45
 
class Pen
46
 
{
47
 
public:
48
 
        Pen( int );
49
 
 
50
 
private:
51
 
        int _value;
52
 
};
53
 
 
54
 
class String
55
 
{
56
 
public:
57
 
        String( QString );
58
 
 
59
 
        QString value() const { return _value; }
60
 
 
61
 
private:
62
 
        QString _value;
63
 
};
64
 
 
65
 
class Char
66
 
{
67
 
public:
68
 
        Char( QString );
69
 
 
70
 
        QString value() const { return _value; }
71
 
 
72
 
private:
73
 
        QString _value;
74
 
};
75
 
 
76
 
class TextRectID
77
 
{
78
 
public:
79
 
        TextRectID( int );
80
 
        int id() const { return _value; }
81
 
 
82
 
private:
83
 
        int _value;
84
 
};
85
 
 
86
 
class ATbl
87
 
{
88
 
public:
89
 
        ATbl( int );
90
 
 
91
 
private:
92
 
        int _value;
93
 
};
94
 
 
95
 
class AFrame
96
 
{
97
 
public:
98
 
        AFrame( int );
99
 
 
100
 
private:
101
 
        int _value;
102
 
};
103
 
 
104
 
class MType
105
 
{
106
 
public:
107
 
        MType( int );
108
 
 
109
 
private:
110
 
        int _value;
111
 
};
112
 
 
113
 
class MTypeName
114
 
{
115
 
public:
116
 
        MTypeName( const char* );
117
 
 
118
 
private:
119
 
        QString _value;
120
 
};
121
 
 
122
 
class MText
123
 
{
124
 
public:
125
 
        MText( const char* );
126
 
 
127
 
private:
128
 
        QString _value;
129
 
};
130
 
 
131
 
class MCurrPage
132
 
{
133
 
public:
134
 
        MCurrPage( const char* );
135
 
 
136
 
private:
137
 
        QString _value;
138
 
};
139
 
 
140
 
class MarkerElement
141
 
{
142
 
public:
143
 
        enum MarkerElementType { T_Unique, T_MType, T_MTypeName, T_MText,
144
 
                                                         T_MCurrPage };
145
 
 
146
 
        MarkerElement( Unique* element );
147
 
        MarkerElement( MType* element );
148
 
        MarkerElement( MTypeName* element );
149
 
        MarkerElement( MText* element );
150
 
        MarkerElement( MCurrPage* elemente );
151
 
 
152
 
private:
153
 
        MarkerElementType _type;
154
 
 
155
 
        union {
156
 
                Unique* _unique;
157
 
                MType* _mtype;
158
 
                MTypeName* _mtypename;
159
 
                MText* _mtext;
160
 
                MCurrPage* _mcurrpage;
161
 
        };
162
 
};
163
 
 
164
 
typedef QList<MarkerElement> MarkerElementList;
165
 
 
166
 
class Marker
167
 
{
168
 
public:
169
 
        Marker( MarkerElementList* elements );
170
 
 
171
 
private:
172
 
        MarkerElementList* _elements;
173
 
};
174
 
 
175
 
 
176
 
class MarkerTypeCatalog
177
 
{
178
 
        // PENDING(kalle) Stuff missing here
179
 
public:
180
 
};
181
 
 
182
 
class KumihanCatalog
183
 
{
184
 
        //PENDING(kalle) Stuff missing here
185
 
};
186
 
 
187
 
 
188
 
class ShapeRect
189
 
{
190
 
public:
191
 
        ShapeRect( double x, const char* unitx,
192
 
                           double y, const char* unity,
193
 
                           double w, const char* unitw,
194
 
                           double h, const char* unith );
195
 
 
196
 
private:
197
 
        double _x;
198
 
        double _y;
199
 
        double _w;
200
 
        double _h;
201
 
};
202
 
 
203
 
 
204
 
class BRect
205
 
{
206
 
public:
207
 
        BRect( double x, const char* unitx,
208
 
                   double y, const char* unity,
209
 
                   double w, const char* unitw,
210
 
                   double h, const char* unith );
211
 
 
212
 
        double x() const { return _x; }
213
 
        double y() const { return _y; }
214
 
        double width() const { return _w; }
215
 
        double height() const { return _h; }
216
 
 
217
 
private:
218
 
        double _x;
219
 
        double _y;
220
 
        double _w;
221
 
        double _h;
222
 
};
223
 
 
224
 
 
225
 
class RectangleElement
226
 
{
227
 
public:
228
 
        enum RectangleElementType { T_Unique, T_Separation, T_ObColor,
229
 
                                                                T_ShapeRect, T_BRect, T_Pen,
230
 
                                                                T_PenWidth, T_Fill, T_DashedPattern,
231
 
                                                                T_RunAroundGap, T_RunAroundType, T_GroupID };
232
 
 
233
 
        RectangleElement( Unique* element );
234
 
        RectangleElement( Separation* element );
235
 
        RectangleElement( ObColor* element );
236
 
        RectangleElement( ShapeRect* element );
237
 
        RectangleElement( BRect* element );
238
 
        RectangleElement( Fill* element );
239
 
        RectangleElement( Pen* element );
240
 
        RectangleElement( PenWidth* element );
241
 
        RectangleElement( DashedPattern* element );
242
 
        RectangleElement( RunAroundType* element );
243
 
        RectangleElement( RunAroundGap* element );
244
 
        RectangleElement( GroupID* element );
245
 
        
246
 
        RectangleElementType type() const { return _type; }
247
 
 
248
 
private:
249
 
        RectangleElementType _type;
250
 
 
251
 
        union {
252
 
                Unique* _unique;
253
 
                Separation* _separation;
254
 
                ObColor* _obcolor;
255
 
                ShapeRect* _shaperect;
256
 
                BRect* _brect;
257
 
                Fill* _fill;
258
 
                Pen* _pen;
259
 
                PenWidth* _penwidth;
260
 
                DashedPattern* _dashedpattern;
261
 
                RunAroundGap* _runaroundgap;
262
 
                RunAroundType* _runaroundtype;
263
 
                GroupID* _groupid;
264
 
        };
265
 
};
266
 
 
267
 
 
268
 
 
269
 
typedef QList<RectangleElement> RectangleElementList;
270
 
 
271
 
class Rectangle
272
 
{
273
 
public:
274
 
        Rectangle( RectangleElementList* elements );
275
 
 
276
 
        RectangleElementList* elements() const { return _elements; }
277
 
 
278
 
private:
279
 
        RectangleElementList* _elements;
280
 
};
281
 
 
282
 
typedef QList<Rectangle> RectangleList;
283
 
 
284
 
 
285
 
#endif