Code

A simple layout document as to what, why and how is cppification.
[inkscape.git] / src / box3d-side.h
1 #ifndef __BOX3D_SIDE_H__
2 #define __BOX3D_SIDE_H__
4 /*
5  * 3D box face implementation
6  *
7  * Authors:
8  *   Maximilian Albert <Anhalter42@gmx.de>
9  *
10  * Copyright (C) 2007  Authors
11  *
12  * Released under GNU GPL, read the file 'COPYING' for more information
13  */
15 #include "sp-polygon.h"
16 #include "axis-manip.h"
18 #define SP_TYPE_BOX3D_SIDE            (box3d_side_get_type ())
19 #define SP_BOX3D_SIDE(obj)            (G_TYPE_CHECK_INSTANCE_CAST ((obj), SP_TYPE_BOX3D_SIDE, Box3DSide))
20 #define SP_BOX3D_SIDE_CLASS(klass)    (G_TYPE_CHECK_CLASS_CAST ((klass), SP_TYPE_BOX3D_SIDE, Box3DSideClass))
21 #define SP_IS_BOX3D_SIDE(obj)         (G_TYPE_CHECK_INSTANCE_TYPE ((obj), SP_TYPE_BOX3D_SIDE))
22 #define SP_IS_BOX3D_SIDE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), SP_TYPE_BOX3D_SIDE))
24 class SPBox3D;
25 class Box3DSide;
26 class Box3DSideClass;
27 class Persp3D;
29 // FIXME: Would it be better to inherit from SPPath instead?
30 struct Box3DSide : public SPPolygon {
31     Box3D::Axis dir1;
32     Box3D::Axis dir2;
33     Box3D::FrontOrRear front_or_rear;
34         long long int getFaceId();
35         static Box3DSide * createBox3DSide(SPBox3D *box);
36 };
38 struct Box3DSideClass {
39     SPPolygonClass parent_class;
40 };
42 GType box3d_side_get_type (void);
44 void box3d_side_position_set (Box3DSide *side); // FIXME: Replace this by box3d_side_set_shape??
45 //void box3d_side_apply_style (Box3DSide *side);
46 gchar *box3d_side_axes_string(Box3DSide *side);
47 Persp3D *box3d_side_perspective(Box3DSide *side);
49 Inkscape::XML::Node *box3d_side_convert_to_path(Box3DSide *side);
51 #endif /* __BOX3D_SIDE_H__ */
53 /*
54   Local Variables:
55   mode:c++
56   c-file-style:"stroustrup"
57   c-file-offsets:((innamespace . 0)(inline-open . 0)(case-label . +))
58   indent-tabs-mode:nil
59   fill-column:99
60   End:
61 */
62 // vim: filetype=cpp:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:encoding=utf-8:textwidth=99 :