Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals  

Gui.h

Go to the documentation of this file.
00001 /*
00002  *    gui - [gega user interface] the flexible solution for user interface problems
00003  *    Copyright (C) 2002  Gergely Gati
00004  *
00005  *    This program is free software; you can redistribute it and/or modify
00006  *    it under the terms of the GNU General Public License as published by
00007  *    the Free Software Foundation; version 2 of the License.
00008  *
00009  *    This program is distributed in the hope that it will be useful,
00010  *    but WITHOUT ANY WARRANTY; without even the implied warranty of
00011  *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00012  *    GNU General Public License for more details.
00013  *
00014  *    You should have received a copy of the GNU General Public License
00015  *    along with this program; if not, write to the Free Software
00016  *    Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
00017  *
00018  *    Gergely Gati
00019  *      email:           g.gati@freemail.hu
00020  *      AIM screenname:  GatiGergely
00021  *      ICQ number:      93131690
00022  *
00023  */
00024 #ifndef __GUI_H
00025 #define __GUI_H
00026 
00027 
00028 #include "types.h"
00029 #include "Bases.h"
00030 #include "Tag.h"
00031 #include "port/Glw.h"
00032 
00033 
00034 // Timer flags
00035 #define GUI_TIMER_REPEAT    (1L<<0)
00036 
00037 //newly defined tags BEGIN
00038 #define TAG_GUI_R1              (TAG_USER+100)
00039 #define TAG_GUI_R2              (TAG_USER+101)
00040 #define TAG_GUI_R3              (TAG_USER+102)
00041 #define TAG_GUI_WIN             (TAG_USER+103)
00042 #define TAG_GUI_NAME            ((TAG_USER+104)|TAGT_STRING)
00043 #define TAG_GUI_LEN             (TAG_USER+105)
00044 #define TAG_GUI_CLASS_NAME      ((TAG_USER+106)|TAGT_STRING)
00045 #define TAG_GUI_RECT            (TAG_USER+108)
00046 #define TAG_GUI_X               (TAG_USER+109)
00047 #define TAG_GUI_Y               (TAG_USER+110)
00048 #define TAG_GUI_TIMER_ID        (TAG_USER+111)
00049 #define TAG_GUI_FONT            (TAG_USER+112)
00050 #define TAG_GUI_STR             ((TAG_USER+113)|TAGT_STRING)
00051 #define TAG_GUI_WIDTH           (TAG_USER+114)
00052 #define TAG_GUI_MILLISEC        (TAG_USER+115)
00053 #define TAG_GUI_FLAGS           (TAG_USER+116)
00054 #define TAG_GUI_USERDATA        (TAG_USER+117)
00055 #define TAG_GUI_CALLBACK        (TAG_USER+118)
00056 #define TAG_GUI_FILE            ((TAG_USER+119)|TAGT_STRING)
00057 //newly defined tags END
00058 
00059 u32 gui_Call(int function, u32 firsttag, ...);
00060 u32 gui_CallTL(int function, tag *taglist);
00061 
00062 //Prototypes BEGIN
00063 u32 gui_IsOverlap(u32 firsttag, ...);
00064 u32 gui_IsOverlapTL(tag *taglist);
00065 u32 gui_CalculateOverlap(u32 firsttag, ...);
00066 u32 gui_CalculateOverlapTL(tag *taglist);
00067 u32 gui_LoadFile(u32 firsttag, ...);
00068 u32 gui_LoadFileTL(tag *taglist);
00069 u32 gui_LoadSubgadgetDescriptor(u32 firsttag, ...);
00070 u32 gui_LoadSubgadgetDescriptorTL(tag *taglist);
00071 u32 gui_IsInside(u32 firsttag, ...);
00072 u32 gui_IsInsideTL(tag *taglist);
00073 u32 gui_TimerCancel(u32 firsttag, ...);
00074 u32 gui_TimerCancelTL(tag *taglist);
00075 u32 gui_GetLimitedTextLength(u32 firsttag, ...);
00076 u32 gui_GetLimitedTextLengthTL(tag *taglist);
00077 u32 gui_GetTextFitLength(u32 firsttag, ...);
00078 u32 gui_GetTextFitLengthTL(tag *taglist);
00079 u32 gui_GetTextWrapLength(u32 firsttag, ...);
00080 u32 gui_GetTextWrapLengthTL(tag *taglist);
00081 u32 gui_TimerStart(u32 firsttag, ...);
00082 u32 gui_TimerStartTL(tag *taglist);
00083 u32 gui_UnLoadSubgadgetDescriptor(u32 firsttag, ...);
00084 u32 gui_UnLoadSubgadgetDescriptorTL(tag *taglist);
00085 //u32 gui_CallGadget(u32 firsttag, ...);
00086 //u32 gui_CallGadgetTL(tag *taglist);
00087 //Prototypes END
00088 
00089 //Enum for calling BEGIN
00090 enum gui_functions
00091 {
00092   GUI_ISOVERLAP=GUI_FUNCBASE,
00093   GUI_CALCULATEOVERLAP,
00094   GUI_LOADFILE,
00095   GUI_LOADSUBGADGETDESCRIPTOR,
00096   GUI_ISINSIDE,
00097   GUI_TIMERCANCEL,
00098   GUI_GETLIMITEDTEXTLENGTH,
00099   GUI_GETTEXTFITLENGTH,
00100   GUI_GETTEXTWRAPLENGTH,
00101   GUI_TIMERSTART,
00102   GUI_UNLOADSUBGADGETDESCRIPTOR,
00103   GUI_FUNC_DONE
00104 };
00105 //Enum for calling END
00106 
00107 
00108 typedef struct
00109 {
00110   char *name;
00111   Prefs_t *prefs;
00112   Locale_t *locale;
00113   List_t *windowlist;
00114   Skin_t *skin;
00115   u32 conn;
00116 } gui_App_t;
00117 
00118 
00119 // system only
00120 int gui_Init(void);
00121 void gui_CleanUp(void);
00122 int gui_ServerMain(u32 conn);
00123 int gui_Event(u32 conn, struct glw_Event *event);
00124 void gui_TimerDelete(gui_Timer_t *timer);
00125 
00126 #endif

Generated on Tue Jan 7 12:11:21 2003 for THEGUI by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002