FLTK 1.4.0
fl_types.h File Reference

This file contains simple "C"-style type definitions. More...

Go to the source code of this file.

Typedefs

Miscellaneous
typedef unsigned char uchar
 unsigned char
 
typedef unsigned long ulong
 unsigned long
 
typedef char * Fl_String
 Flexible length UTF-8 Unicode text. More...
 
typedef const char * Fl_CString
 Flexible length UTF-8 Unicode read-only string. More...
 
typedef unsigned int Fl_Shortcut
 16-bit Unicode character + 8-bit indicator for keyboard flags. More...
 
typedef unsigned int Fl_Char
 24-bit Unicode character - upper 8 bits are unused
 

Detailed Description

This file contains simple "C"-style type definitions.

Typedef Documentation

◆ Fl_CString

typedef const char* Fl_CString

Flexible length UTF-8 Unicode read-only string.

See also
Fl_String

◆ Fl_Shortcut

typedef unsigned int Fl_Shortcut

16-bit Unicode character + 8-bit indicator for keyboard flags.

Note
This should be 24-bit Unicode character + 8-bit indicator for keyboard flags. The upper 8 bits are currently unused but reserved.

Due to compatibility issues this type and all FLTK shortcuts can only be used with 16-bit Unicode characters (U+0000 .. U+FFFF) and not with the full range of unicode characters (U+0000 .. U+10FFFF).

This is caused by the bit flags FL_SHIFT, FL_CTRL, FL_ALT, and FL_META being all in the range 0x010000 .. 0x400000.

Todo:
Discuss and decide whether we can "shift" these special keyboard flags to the upper byte to enable full 21-bit Unicode characters (U+0000 .. U+10FFFF) plus the keyboard indicator bits as this was originally intended. This would be possible if we could rely on all programs being coded with symbolic names and not hard coded bit values.

◆ Fl_String

typedef char* Fl_String

Flexible length UTF-8 Unicode text.

Todo:
FIXME: temporary (?) typedef to mark UTF-8 and Unicode conversions