Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

font.h

Go to the documentation of this file.
00001 
00002 
00003 //
00004 //      FONT.H                                          (c)     YoY'99                                          WEB: www.aestesis.org
00005 //
00008 #ifndef                                                 _FONT_H_
00009 #define                                                 _FONT_H_
00012 #include                                                <windows.h>
00013 #include                                                "node.h"
00014 #include                                                "point.h"
00015 #include                                                "rectangle.h"
00016 #include                                                "font.h"
00019 
00020 //      If you use directly the variables in the class API, it's at your own risks. Prefer the methods...   
00021 
00024 
00025 #define                                                 guidFONT                                                (Afont::CI.guid)
00026 
00029 
00030 enum
00031 {
00032                                                                 fontNORMAL=0,
00033                                                                 fontBORDER=1
00034 };
00035 
00038 
00039 class Afont : public Anode
00040 {
00041         ALIBOBJ
00042 
00043         int                                                     w;
00044         int                                                     h;
00045         int                                                     e;
00046         char                                            *characters;
00047         class Abitmap                           *bitmap;
00048         struct AScharInfo                       *charInfo;
00049 
00050         ADLL                                            Afont                                                   (char *name, char *filename, int w, int h, char *c, int e=2, int min=30);
00051         ADLL                                            Afont                                                   (char *name, class Aresobj *o, int w, int h, char *c, int e=2, int min=30);
00052         ADLL                                            Afont                                                   (char *name, class Aresobj *o, int e=2, int min=30);
00053         ADLL virtual                            ~Afont                                                  ();
00054 
00055         ADLL virtual bool                       set                                                             (class Abitmap *b, int x, int y, char *s, dword color);
00056         ADLL virtual bool                       set                                                             (class Abitmap *b, int x, int y, char *s, dword colorText, dword colorBorder, int type=fontBORDER);
00057 
00058         ADLL virtual Apoint                     getPosition                                             (char *s, int pos);
00059         ADLL virtual int                        getWidth                                                (char *s);
00060         ADLL virtual int                        getHeight                                               (char *s);
00061         ADLL virtual Arectangle         getRectangle                                    (int x, int y, char *s, int firstChar, int lastChar);
00062 
00063 private:
00064 
00065         void                                            NCcalcChar                                              (int min);
00066 };
00067 
00069 
00070 typedef struct AScharInfo
00071 {
00072         int                                                     w;
00073         int                                                     b;
00074 } ATcharInfo;
00075 
00078 
00079 
00082 #endif                                                  //_FONT_H_

Generated on Tue Nov 20 10:21:25 2001 for elektronika plugz SDK by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001