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

fxdefs.h
1 /********************************************************************************
2 * *
3 * FOX Definitions, Types, and Macros *
4 * *
5 *********************************************************************************
6 * Copyright (C) 1997,2024 by Jeroen van der Zijp. All Rights Reserved. *
7 *********************************************************************************
8 * This library is free software; you can redistribute it and/or modify *
9 * it under the terms of the GNU Lesser General Public License as published by *
10 * the Free Software Foundation; either version 3 of the License, or *
11 * (at your option) any later version. *
12 * *
13 * This library is distributed in the hope that it will be useful, *
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
16 * GNU Lesser General Public License for more details. *
17 * *
18 * You should have received a copy of the GNU Lesser General Public License *
19 * along with this program. If not, see <http://www.gnu.org/licenses/> *
20 ********************************************************************************/
21 #ifndef FXDEFS_H
22 #define FXDEFS_H
23 
24 
25 
26 /******************************** Definitions ********************************/
27 
28 // Placement new
29 #include <new>
30 
31 
32 // Path separator
33 #ifdef WIN32
34 #define PATHSEP '\\'
35 #define PATHSEPSTRING "\\"
36 #define PATHLISTSEP ';'
37 #define PATHLISTSEPSTRING ";"
38 #define ISPATHSEP(c) ((c)=='\\' || (c)=='/')
39 #else
40 #define PATHSEP '/'
41 #define PATHSEPSTRING "/"
42 #define PATHLISTSEP ':'
43 #define PATHLISTSEPSTRING ":"
44 #define ISPATHSEP(c) ((c)=='/')
45 #endif
46 
47 
48 // End Of Line
49 #ifdef WIN32
50 #define ENDLINE "\r\n"
51 #else
52 #define ENDLINE "\n"
53 #endif
54 
55 
56 // Byte order
57 #if !defined(FOX_BIGENDIAN)
58 #if defined(__GNUC__)
59 #if defined(__BYTE_ORDER__)
60 #if (__BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
61 #define FOX_BIGENDIAN 0
62 #else
63 #define FOX_BIGENDIAN 1
64 #endif
65 #else
66 #error "FOX_BIGENDIAN macro not set"
67 #endif
68 #elif defined(_MSC_VER)
69 #define FOX_BIGENDIAN 0
70 #else
71 #error "FOX_BIGENDIAN macro not set"
72 #endif
73 #endif
74 
75 
76 // Shared library support
77 #ifdef WIN32
78 #if defined(__GNUC__)
79 #define FXLOCAL
80 #define FXEXPORT __attribute__ ((dllexport))
81 #define FXIMPORT __attribute__ ((dllimport))
82 #else
83 #define FXLOCAL
84 #define FXEXPORT __declspec(dllexport)
85 #define FXIMPORT __declspec(dllimport)
86 #endif
87 #else
88 #if defined(__GNUC__) && (__GNUC__ >= 4)
89 #define FXLOCAL __attribute__((visibility("hidden")))
90 #define FXEXPORT __attribute__((visibility("default")))
91 #define FXIMPORT __attribute__((visibility("default")))
92 #else
93 #define FXLOCAL
94 #define FXEXPORT
95 #define FXIMPORT
96 #endif
97 #endif
98 
99 
100 // Define FXAPI for DLL builds
101 #ifdef FOXDLL
102 #ifdef FOXDLL_EXPORTS
103 #define FXAPI FXEXPORT
104 #define FXTEMPLATE_EXTERN
105 #else
106 #define FXAPI FXIMPORT
107 #define FXTEMPLATE_EXTERN extern
108 #endif
109 #else
110 #define FXAPI
111 #define FXTEMPLATE_EXTERN
112 #endif
113 
114 // Flag old API as deprecated
115 #if defined(_MSC_VER) && defined(_WIN32)
116 #define FXDEPRECATED __declspec(deprecated)
117 #elif defined(__GNUC__)
118 #define FXDEPRECATED __attribute__((deprecated))
119 #else
120 #define FXDEPRECATED
121 #endif
122 
123 // Data alignment attribute
124 #if defined(__GNUC__)
125 #define __align(x) __attribute__((aligned(x)))
126 #elif defined(_MSC_VER)
127 #define __align(x) __declspec(align(x))
128 #else
129 #define __align(x)
130 #endif
131 
132 // Get alignment of pointer p to b=2^n bytes, returning 0..b-1
133 #define __alignment(p,b) (((FXival)(p))&((b)-1))
134 
135 // Check if pointer p is aligned to b=2^n bytes
136 #define __isaligned(p,b) (__alignment(p,b)==0)
137 
138 // Align pointer to b=2^n bytes
139 #define __alignto(p,b) ((void*)((((FXival)(p))+((FXival)((b)-1)))&~((FXival)((b)-1))))
140 
141 
142 // Thread-local storage attribute
143 #if defined(__GNUC__)
144 #define __threadlocal __thread
145 #elif defined(_MSC_VER)
146 #define __threadlocal __declspec(thread)
147 #else
148 #define __threadlocal
149 #endif
150 
151 // Non-returning function
152 #if defined(__GNUC__)
153 #define __noreturn __attribute__((__noreturn__))
154 #elif (_MSC_VER >= 1400)
155 #define __noreturn __declspec(noreturn)
156 #else
157 #define __noreturn
158 #endif
159 
160 // Branch prediction optimization
161 #if (__GNUC__ >= 3)
162 #define __likely(cond) __builtin_expect(!!(cond),1)
163 #define __unlikely(cond) __builtin_expect(!!(cond),0)
164 #else
165 #define __likely(cond) (!!(cond))
166 #define __unlikely(cond) (!!(cond))
167 #endif
168 
169 // An assumption that compiler may use to optimize
170 #if (__GNUC__ >= 13)
171 #define __assume(expr) __attribute__((__assume__(expr)))
172 #elif (__clang__ >= 14)
173 #define __assume(expr) __builtin_assume(expr)
174 #elif !defined(_MSC_VER)
175 #define __assume(expr)
176 #endif
177 
178 // An unreachable part of code may be optimized away
179 #if (__GNUC__ >= 4)
180 #define __unreachable() __builtin_unreachable()
181 #elif defined(_MSC_VER)
182 #define __unreachable() __assume(false)
183 #else
184 #define __unreachable()
185 #endif
186 
187 // Define parameters not-aliased hint
188 #if defined(__GNUC__)
189 #define __restrict __restrict__
190 #elif !defined(_MSC_VER)
191 #define __restrict
192 #endif
193 
194 // Prefetch address
195 #if (__GNUC__ >= 4) && (defined(__i386__) || defined(__x86_64__))
196 #define __prefetch(addr) __builtin_prefetch((addr),0)
197 #define __prefetchw(addr) __builtin_prefetch((addr),1)
198 #else
199 #define __prefetch(addr)
200 #define __prefetchw(addr)
201 #endif
202 
203 // Standard call calling sequence
204 #ifdef WIN32
205 #ifndef CALLBACK
206 #define CALLBACK __stdcall
207 #endif
208 #endif
209 
210 // C Language calling sequence
211 #ifdef WIN32
212 #ifndef CDECL
213 #define CDECL __cdecl
214 #endif
215 #else
216 #ifndef CDECL
217 #define CDECL
218 #endif
219 #endif
220 
221 // Suppress unused parameter warnings
222 #define FXUNUSED(prm) (void)(prm)
223 
224 // Checking printf and scanf format strings
225 #if defined(_CC_GNU_) || defined(__GNUG__) || defined(__GNUC__)
226 #define FX_PRINTF(fmt,arg) __attribute__((format(printf,fmt,arg)))
227 #define FX_SCANF(fmt,arg) __attribute__((format(scanf,fmt,arg)))
228 #define FX_FORMAT(arg) __attribute__((format_arg(arg)))
229 #else
230 #define FX_PRINTF(fmt,arg)
231 #define FX_SCANF(fmt,arg)
232 #define FX_FORMAT(arg)
233 #endif
234 
235 // Word size issues
236 #if defined(_MSC_VER) || defined(__MINGW32__) // Windows
237 #if defined(_WIN64)
238 #define LLP64 1 // Long longs and pointers are 64 bit
239 #else
240 #define ILP32 1 // Ints, longs, and pointers are 32 bit
241 #endif
242 #elif defined(__LP64__) || defined(_LP64) || (_MIPS_SZLONG == 64) || (__WORDSIZE == 64)
243 #define LP64 1 // Longs and pointers are 64 bit
244 #else
245 #define ILP32 1 // Longs, integers, and pointers are 32 bit
246 #endif
247 
248 // Suffixes for 64-bit constants
249 #if defined(LP64)
250 #define FXLONG(c) c ## L // Long suffix for 64 bit
251 #define FXULONG(c) c ## UL
252 #elif defined(_MSC_VER) && (_MSC_VER < 1900)
253 #define FXLONG(c) c ## i64 // Special suffix for 64 bit
254 #define FXULONG(c) c ## ui64
255 #else
256 #define FXLONG(c) c ## LL // Long long suffix for 64 bit
257 #define FXULONG(c) c ## ULL
258 #endif
259 
260 
261 // Raw event type
262 #ifdef WIN32
263 struct tagMSG;
264 #else
265 union _XEvent;
266 #endif
267 
268 
269 namespace FX {
270 
271 
272 /********************************* Typedefs **********************************/
273 
274 // Forward declarations
275 class FXObject;
276 class FXStream;
277 class FXString;
278 
279 
280 // Streamable types; these are fixed size!
281 typedef char FXchar;
282 typedef signed char FXschar;
283 typedef unsigned char FXuchar;
284 typedef bool FXbool;
285 typedef unsigned short FXushort;
286 typedef short FXshort;
287 typedef unsigned int FXuint;
288 typedef int FXint;
289 typedef float FXfloat;
290 typedef double FXdouble;
291 #if defined(WIN32)
292 typedef unsigned int FXwchar;
293 #if defined(_MSC_VER) && !defined(_NATIVE_WCHAR_T_DEFINED)
294 typedef unsigned short FXnchar;
295 #elif defined(__WATCOMC__) && !defined(_WCHAR_T_DEFINED)
296 typedef long char FXnchar;
297 #else
298 typedef wchar_t FXnchar;
299 #endif
300 #else
301 typedef wchar_t FXwchar;
302 typedef unsigned short FXnchar;
303 #endif
304 #if defined(LP64)
305 typedef long FXlong;
306 typedef unsigned long FXulong;
307 #elif defined(_MSC_VER) && (_MSC_VER < 1900)
308 typedef __int64 FXlong;
309 typedef unsigned __int64 FXulong;
310 #else
311 typedef long long FXlong;
312 typedef unsigned long long FXulong;
313 #endif
314 
315 // Integral types large enough to hold value of a pointer
316 #if defined(LP64) || defined(ILP32) // Long for LP64 and ILP32 models
317 typedef long FXival;
318 typedef unsigned long FXuval;
319 #elif defined(LLP64) // Long long for LLP64 models
320 #if defined(_MSC_VER) && (_MSC_VER < 1900)
321 typedef __int64 FXival;
322 typedef unsigned __int64 FXuval;
323 #else
324 typedef long long FXival;
325 typedef unsigned long long FXuval;
326 #endif
327 #endif
328 
329 // Generic void pointer
330 typedef void* FXptr;
331 
332 
333 // Handle to something in server
334 #ifdef WIN32
335 typedef void* FXID;
336 #else
337 typedef unsigned long FXID;
338 #endif
339 
340 // Time since January 1, 1970 (UTC)
341 typedef FXlong FXTime;
342 
343 // Pixel type (could be color index)
344 typedef unsigned long FXPixel;
345 
346 // RGBA pixel value
347 typedef FXuint FXColor;
348 
349 // Hot key
350 typedef FXuint FXHotKey;
351 
352 // Input source handle type
353 #ifdef WIN32
354 typedef void* FXInputHandle;
355 #else
356 typedef FXint FXInputHandle;
357 #endif
358 
359 // Process handle
360 #if defined(WIN32)
361 typedef void* FXProcessID;
362 #else
363 typedef int FXProcessID;
364 #endif
365 
366 // Thread ID type
367 #if defined(WIN32)
368 typedef void* FXThreadID;
369 #else
370 typedef unsigned long FXThreadID;
371 #endif
372 
373 // Thread-local storage key
374 typedef FXuval FXThreadStorageKey;
375 
376 // Raw event type
377 #ifdef WIN32
378 typedef tagMSG FXRawEvent;
379 #else
380 typedef _XEvent FXRawEvent;
381 #endif
382 
383 
384 // Drag and drop data type
385 #ifdef WIN32
386 typedef FXushort FXDragType;
387 #else
388 typedef FXID FXDragType;
389 #endif
390 
391 
392 // Third logic state: unknown/indeterminate
393 enum { maybe=2 };
394 
395 // A time in the far, far future
396 const FXTime forever=FXLONG(9223372036854775807);
397 
398 // Search modes for search/replace dialogs
399 enum {
400  SEARCH_BACKWARD = 1,
401  SEARCH_FORWARD = 2,
402  SEARCH_NOWRAP = 0,
403  SEARCH_WRAP = 4,
404  SEARCH_EXACT = 0,
405  SEARCH_IGNORECASE = 8,
406  SEARCH_REGEX = 16,
407  SEARCH_PREFIX = 32,
408  SEARCH_SUFFIX = 64,
409  SEARCH_WORDS = 128
410  };
411 
412 /********************************** Macros ***********************************/
413 
415 #define FXBIT(val,b) (((val)>>(b))&1)
416 
418 #define FXABS(val) (((val)>=0)?(val):-(val))
419 
421 #define FXSGN(val) (((val)<0)?-1:1)
422 
424 #define FXSGNZ(val) ((val)<0?-1:(val)>0?1:0)
425 
427 #define FXSGNX(x,b) (((FXint)((x)<<(32-(b))))>>(32-(b)))
428 
430 #define FXMAX(a,b) (((a)>(b))?(a):(b))
431 
433 #define FXMIN(a,b) (((a)>(b))?(b):(a))
434 
436 #define FXMIN3(x,y,z) ((x)<(y)?FXMIN(x,z):FXMIN(y,z))
437 
439 #define FXMAX3(x,y,z) ((x)>(y)?FXMAX(x,z):FXMAX(y,z))
440 
442 #define FXMIN4(x,y,z,w) (FXMIN(FXMIN(x,y),FXMIN(z,w)))
443 
445 #define FXMAX4(x,y,z,w) (FXMAX(FXMAX(x,y),FXMAX(z,w)))
446 
448 #define FXMINMAX(lo,hi,a,b) ((a)<(b)?((lo)=(a),(hi)=(b)):((lo)=(b),(hi)=(a)))
449 
451 #define FXCLAMP(lo,x,hi) ((x)<(lo)?(lo):((x)>(hi)?(hi):(x)))
452 
454 #define FXSWAP(a,b,t) ((t)=(a),(a)=(b),(b)=(t))
455 
457 #define FXLERP(a,b,f) ((a)+((b)-(a))*(f))
458 
460 #define STRUCTOFFSET(str,member) (((char *)(&(((str *)0)->member)))-((char *)0))
461 
463 #define ARRAYNUMBER(array) (sizeof(array)/sizeof(array[0]))
464 
466 #define CONTAINER(ptr,str,mem) ((str*)(((char*)(ptr))-STRUCTOFFSET(str,mem)))
467 
469 #define MKUINT(l,h) ((((FX::FXuint)(l))&0xffff) | (((FX::FXuint)(h))<<16))
470 
472 #define FXSEL(type,id) ((((FX::FXuint)(id))&0xffff) | (((FX::FXuint)(type))<<16))
473 
475 #define FXSELTYPE(s) ((FX::FXushort)(((s)>>16)&0xffff))
476 
478 #define FXSELID(s) ((FX::FXushort)((s)&0xffff))
479 
481 #define FXAVGCOLOR(ca,cb) (((ca)&(cb))+((((ca)^(cb))&0xFEFEFEFE)>>1))
482 
483 
484 // Definitions for big-endian machines
485 #if FOX_BIGENDIAN == 1
486 
488 #define FXRGBA(r,g,b,a) (((FX::FXuint)(FX::FXuchar)(a)) | ((FX::FXuint)(FX::FXuchar)(r)<<8) | ((FX::FXuint)(FX::FXuchar)(g)<<16) | ((FX::FXuint)(FX::FXuchar)(b)<<24))
489 
491 #define FXRGB(r,g,b) (((FX::FXuint)(FX::FXuchar)(r)<<8) | ((FX::FXuint)(FX::FXuchar)(g)<<16) | ((FX::FXuint)(FX::FXuchar)(b)<<24) | 0x000000ff)
492 
494 #define FXREDVAL(rgba) ((FX::FXuchar)(((rgba)>>8)&0xff))
495 
497 #define FXGREENVAL(rgba) ((FX::FXuchar)(((rgba)>>16)&0xff))
498 
500 #define FXBLUEVAL(rgba) ((FX::FXuchar)(((rgba)>>24)&0xff))
501 
503 #define FXALPHAVAL(rgba) ((FX::FXuchar)((rgba)&0xff))
504 
506 #define FXRGBACOMPVAL(rgba,comp) ((FX::FXuchar)(((rgba)>>((comp)<<3))&0xff))
507 
509 #define FXCOLORREF2RGB(ref) (FX::FXuint)((((ref)<<8)&0xff000000) | (((ref)<<8)&0xff0000) | (((ref)<<8)&0xff00) | 0x000000ff)
510 
512 #define FXRGB2COLORREF(rgb) (FX::FXuint)((((rgb)>>8)&0xff0000) | (((rgb)>>8)&0xff00) | (((rgb)>>8)&0xff))
513 
514 #endif
515 
516 
517 // Definitions for little-endian machines
518 #if FOX_BIGENDIAN == 0
519 
521 #define FXRGBA(r,g,b,a) (((FX::FXuint)(FX::FXuchar)(a)<<24) | ((FX::FXuint)(FX::FXuchar)(r)<<16) | ((FX::FXuint)(FX::FXuchar)(g)<<8) | ((FX::FXuint)(FX::FXuchar)(b)))
522 
524 #define FXRGB(r,g,b) (((FX::FXuint)(FX::FXuchar)(r)<<16) | ((FX::FXuint)(FX::FXuchar)(g)<<8) | ((FX::FXuint)(FX::FXuchar)(b)) | 0xff000000)
525 
527 #define FXREDVAL(rgba) ((FX::FXuchar)(((rgba)>>16)&0xff))
528 
530 #define FXGREENVAL(rgba) ((FX::FXuchar)(((rgba)>>8)&0xff))
531 
533 #define FXBLUEVAL(rgba) ((FX::FXuchar)((rgba)&0xff))
534 
536 #define FXALPHAVAL(rgba) ((FX::FXuchar)(((rgba)>>24)&0xff))
537 
539 #define FXRGBACOMPVAL(rgba,comp) ((FX::FXuchar)(((rgba)>>((3-(comp))<<3))&0xff))
540 
542 #define FXCOLORREF2RGB(ref) (FX::FXuint)((((ref)>>16)&0xff) | ((ref)&0xff00) | (((ref)<<16)&0xff0000) | 0xff000000)
543 
545 #define FXRGB2COLORREF(rgb) (FX::FXuint)((((rgb)<<16)&0xff0000) | ((rgb)&0xff00) | (((rgb)>>16)&0xff))
546 
547 #endif
548 
556 #ifndef NDEBUG
557 #define FXASSERT(exp) (__likely(exp)?((void)0):(void)FX::fxassert(#exp,__FILE__,__LINE__))
558 #else
559 #define FXASSERT(exp) ((void)0)
560 #endif
561 
562 
570 #ifndef NDEBUG
571 #define FXVERIFY(exp) (__likely(exp)?((void)0):(void)FX::fxverify(#exp,__FILE__,__LINE__))
572 #else
573 #define FXVERIFY(exp) ((void)(exp))
574 #endif
575 
576 
583 #if (defined(__cplusplus) && (__cplusplus >= 201103L)) || (defined(_MSC_VER) && (_MSC_VER >= 1600))
584 #define FXASSERT_STATIC(expr) static_assert(expr,#expr)
585 #else
586 #define FXASSERT_STATIC(expr) FXASSERT(expr)
587 #endif
588 
589 
593 #define VA_NUM_ARGS(...) VA_NUM_ARGS_IMPL(__VA_ARGS__,32,31,30,29,28,27,26,25,24,23,22,21,20,19,18,17,16,15,14,13,12,11,10,9,8,7,6,5,4,3,2,1)
594 #define VA_NUM_ARGS_IMPL(_0,_1,_2,_3,_4,_5,_6,_7,_8,_9,_10,_11,_12,_13,_14,_15,_16,_17,_18,_19,_20_21,_22,_23,_24,_25,_26,_27,_28,_29,_30,_31,_32,N,...) N
595 
596 
612 #ifndef NDEBUG
613 #define FXTRACE(arguments) FX::fxtrace arguments
614 #else
615 #define FXTRACE(arguments) ((void)0)
616 #endif
617 
624 #define FXMALLOC(ptr,type,no) (FX::fxmalloc((void **)(ptr),sizeof(type)*(no)))
625 
632 #define FXCALLOC(ptr,type,no) (FX::fxcalloc((void **)(ptr),sizeof(type)*(no)))
633 
643 #define FXRESIZE(ptr,type,no) (FX::fxresize((void **)(ptr),sizeof(type)*(no)))
644 
652 #define FXMEMDUP(ptr,src,type,no) (FX::fxmemdup((void **)(ptr),(const void*)(src),sizeof(type)*(no)))
653 
660 #define FXFREE(ptr) (FX::fxfree((void **)(ptr)))
661 
662 /********************************** Globals **********************************/
663 
665 template <typename to_type>
666 static inline to_type* alias_cast(void* ptr){
667  union UNI { to_type dst[1]; };
668  return reinterpret_cast<UNI*>(ptr)->dst;
669  }
670 
672 template <typename to_type>
673 static inline const to_type* alias_cast(const void* ptr){
674  union UNI { to_type dst[1]; };
675  return reinterpret_cast<const UNI*>(ptr)->dst;
676  }
677 
679 extern FXAPI FXbool fxmalloc(void** ptr,FXuval size);
680 
682 extern FXAPI FXbool fxcalloc(void** ptr,FXuval size);
683 
685 extern FXAPI FXbool fxresize(void** ptr,FXuval size);
686 
688 extern FXAPI void fxfree(void** ptr);
689 
691 extern FXAPI FXbool fxmemdup(void** ptr,const void* src,FXuval size);
692 
694 extern FXAPI __noreturn void fxerror(const FXchar* format,...) FX_PRINTF(1,2) ;
695 
697 extern FXAPI void fxwarning(const FXchar* format,...) FX_PRINTF(1,2) ;
698 
700 extern FXAPI void fxmessage(const FXchar* format,...) FX_PRINTF(1,2) ;
701 
703 extern FXAPI void fxassert(const FXchar* expression,const FXchar* filename,unsigned int lineno);
704 
706 extern FXAPI void fxverify(const FXchar* expression,const FXchar* filename,unsigned int lineno);
707 
709 extern FXAPI void fxtrace(FXuint level,const FXchar* format,...) FX_PRINTF(2,3) ;
710 
712 extern FXAPI FXbool fxtoDOS(FXchar*& string,FXint& len);
713 
715 extern FXAPI FXbool fxfromDOS(FXchar*& string,FXint& len);
716 
718 extern FXAPI FXchar *fxstrdup(const FXchar* str);
719 
721 extern FXAPI FXuint fxstrhash(const FXchar* str);
722 
724 extern FXAPI FXival fxstrlcpy(FXchar* dst,const FXchar* src,FXival len);
725 
727 extern FXAPI FXival fxstrlcat(FXchar* dst,const FXchar* src,FXival len);
728 
730 extern FXAPI void fxrgb_to_hsv(FXfloat& h,FXfloat& s,FXfloat& v,FXfloat r,FXfloat g,FXfloat b);
731 
733 extern FXAPI void fxhsv_to_rgb(FXfloat& r,FXfloat& g,FXfloat& b,FXfloat h,FXfloat s,FXfloat v);
734 
736 extern FXAPI void fxrgb_to_hsl(FXfloat& h,FXfloat& s,FXfloat& l,FXfloat r,FXfloat g,FXfloat b);
737 
739 extern FXAPI void fxhsl_to_rgb(FXfloat& r,FXfloat& g,FXfloat& b,FXfloat h,FXfloat s,FXfloat l);
740 
742 extern FXchar* fxencode64(FXchar* dst,FXchar* dstend,const FXchar* src,const FXchar* srcend);
743 
745 extern FXchar* fxdecode64(FXchar* dst,FXchar* dstend,const FXchar* src,const FXchar* srcend);
746 
748 extern FXchar* fxencode85(FXchar* dst,FXchar* dstend,const FXchar* src,const FXchar* srcend);
749 
751 extern FXchar* fxdecode85(FXchar* dst,FXchar* dstend,const FXchar* src,const FXchar* srcend);
752 
754 extern FXAPI FXwchar fxkeysym2ucs(FXwchar sym);
755 
757 extern FXAPI FXwchar fxucs2keysym(FXwchar ucs);
758 
760 extern FXAPI FXint fxparsegeometry(const FXchar *string,FXint& x,FXint& y,FXint& w,FXint& h);
761 
763 extern FXAPI FXbool fxisconsole(const FXchar *path);
764 
766 extern FXAPI const FXuchar fxversion[3];
767 
769 extern FXAPI FXbool getTraceTopic(FXuint topic);
770 
772 extern FXAPI void setTraceTopic(FXuint topic,FXbool flag=true);
773 
775 extern FXAPI void setTraceLevel(FXuint level,FXbool flag=true);
776 
787 extern FXAPI FXbool setTraceTopics(const FXchar* topics,FXbool flag=true);
788 
790 extern FXAPI FXival fxosversion(FXchar version[],FXival len);
791 
792 }
793 
794 #endif
Definition: FX4Splitter.h:28

Copyright © 1997-2022 Jeroen van der Zijp