xobjc_global.h

Go to the documentation of this file.
00001 #define BUILTIN_XOBJC 1
00002 /*
00003  * WinDom: a high level GEM library
00004  * Copyright (c) 1997-2006 windom authors (see AUTHORS file)
00005  *
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the GNU Lesser General Public
00008  * License as published by the Free Software Foundation; either
00009  * version 2.1 of the License, or (at your option) any later version.
00010  *
00011  * This library is distributed in the hope that it will be useful,
00012  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014  * Lesser General Public License for more details.
00015  *
00016  * You should have received a copy of the GNU Lesser General Public
00017  * License along with this library; if not, write to the Free Software
00018  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019  *
00020  * $Source: /cvsroot/windom/htdocs/doc/html/xobjc__global_8h-source.html,v $
00021  *
00022  * CVS info:
00023  *   $Author: bercegeay $
00024  *   $Date: 2006/06/22 11:58:30 $
00025  *   $Revision: 1.5 $
00026  */
00027 
00028 #ifndef _GLOBAL_H_
00029 #define _GLOBAL_H_
00030 
00031 #define MODIF_XEDIT 1
00032 #define __GEMLIB_OLDNAMES
00033 
00034 #ifndef _COMPILER_H
00035 #include <compiler.h>
00036 #endif
00037 
00038 #include <windom/udlib.h>
00039 #ifndef BUILTIN_XOBJC
00040 #include <ldg.h>  /* for ldg_callback */
00041 #define APP_MALLOC(size) ldg_callback(env->app_malloc,(long)(size))
00042 #define APP_FREE(addr)   ldg_callback(env->app_free,addr)
00043 #else
00044 #define APP_MALLOC(size) env->app_malloc(size)
00045 #define APP_FREE(addr)   env->app_free(addr)
00046 #define UDEFTOS 1
00047 #endif
00048 
00049 #define FL3DMASK   0x0600  /* 3D objects AES 3.4    */
00050 
00051 /* extended objects internal to this xobjc lib */
00052 #define XFREESTR    0x0C    /* object G_BUTTON 3D (obspec = free_string) */
00053 #define XTEDINFO    0x0B    /* object G_BOXTEXT & co 3D (obspec = tedinfo) */
00054 #define XBFOBSPEC   0x0A    /* object G_BOXCHAR 3D (obspec = bfobspec) */
00055 
00056 #define IS_FLAGS(pblk,flags) (((pblk)->pb_tree[(pblk)->pb_obj].ob_flags & (flags))?1:0)
00057 #define IS_STATE(pblk,state) (((pblk)->pb_currstate & (state))?1:0)
00058 #define MASK_STATE      (DISABLED|CROSSED|CHECKED|OUTLINED|SHADOWED)
00059 #define STATE8  0x0100
00060 #define STATE9  0x0200
00061 #define STATE10 0x0400
00062 #define STATE11 0x0800
00063 #define STATE12 0x1000
00064 #define STATE13 0x2000
00065 #define STATE14 0x4000
00066 #define STATE15 0x8000
00067 
00068 #define BOLD        0x01
00069 #define LIGHT       0x02
00070 #define ITALIC      0x04
00071 #define ULINE       0x08
00072 #define OUTLINE     0x10
00073 #define SHADOW      0x20
00074 
00075 #define _FSM 0x5F46534DUL
00076 
00077 #define CONF(uldata) ((uldata)->config)
00078 
00079 #define BUT3D_PAT   0
00080 #define ONGLT_PAT   0
00081 #define DIALM_PAT   0
00082 
00083 #define SYSFONT 0
00084 
00085 typedef struct {
00086     OBJECT *rs_trindex;
00087     short __CDECL (*draw_cicon)(long, OBJECT*, long, long, long, long);
00088     short has_fsmgdos;
00089     short vdih;
00090     short nplanes;
00091     UDLIB_CONFIG *config;
00092 } XOBJC_DATA;
00093 
00094 typedef struct {
00095     long        wp_spec;
00096     short       wp_type;
00097     short       wp_oldf;
00098     XOBJC_DATA * wp_uldata;
00099 } W_PARM;
00100 
00101 typedef struct {
00102     TEDINFO *tedinfo;   
00103     char *line;         
00104     short pos;          
00105     short curs;         
00106     short blcbeg;       
00107     short blcend;       
00108     short flags;        
00109     short size;         
00110     short wp_type;      
00111     XOBJC_DATA * wp_uldata; 
00112 } W_XEDIT;
00113 
00114 /* values for W_XEDIT.flags */
00115 #define XEDIT_CURS_ON 0x1
00116 #define XEDIT_BLOC_ON 0x2
00117 
00118 long   _xobjc_extended( OBJECT *, long , long , APPENV *);
00119 void   _xobjc_extfree ( OBJECT *, long , APPENV *);
00120 char * _xobjc_string  ( OBJECT *, long , char *, APPENV *);
00121 long   _xobjc_char    ( OBJECT *, long , long , APPENV *);
00122 long   _xobjc_edit    ( OBJECT *, long , long , short* , long , long, GRECT*, APPENV *);
00123 long   _xobjc_get_edpos( OBJECT *, long , long , long , APPENV *);
00124 long   _xobjc_get_unextended( OBJECT *, int, APPENV *);
00125 
00126 void    _xobjc_xedit_curs( XOBJC_DATA *, OBJECT *, int, GRECT *);
00127 void    _xobjc_xedit_bloc( XOBJC_DATA *, OBJECT *, int, GRECT *);
00128 int     _xobjc_width_curs( XOBJC_DATA *uldata, W_XEDIT *xedit, int curs);
00129 
00130 size_t  _xobjc_realloc_xedit( size_t old, size_t len);
00131 
00132 short __CDECL ub_button( PARMBLK *pblk);
00133 short __CDECL ub_boxtitle( PARMBLK *pblk);
00134 short __CDECL ub_ulinetext( PARMBLK *pblk);
00135 short __CDECL ub_boxcircle( PARMBLK *pblk);
00136 short __CDECL ub_onglet( PARMBLK *pblk);
00137 short __CDECL ub_popuptext( PARMBLK *pblk);
00138 short __CDECL ub_boxchar3d( PARMBLK *pblk);
00139 short __CDECL ub_mntitle( PARMBLK *pblk);
00140 short __CDECL ub_dialmover( PARMBLK *pblk);
00141 short __CDECL ub_multiligne( PARMBLK *pblk);
00142 short __CDECL ub_boxtext3d( PARMBLK *pblk);
00143 short __CDECL ub_editable( PARMBLK *pblk); 
00144 short __CDECL ub_but3d( PARMBLK *pblk);
00145 short __CDECL ub_box3d( PARMBLK *pblk);
00146 short __CDECL ub_ibox3d( PARMBLK *pblk); 
00147 
00148 #include "xobjc_interface.h"
00149 
00150 #endif /* _GLOBAL_H_ */

Generated on Thu Jun 22 11:45:27 2006 for WinDom by  doxygen 1.4.6