Surrounded all #warning's with #if defined(__GNUC__)
to prevent compiling problems on non-gnu compilers. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6687 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
parent
3ed30905a9
commit
a68ea3c069
@ -374,7 +374,9 @@ void Fl_Browser::item_draw(void* v, int X, int Y, int W, int H) const {
|
||||
Fl_Color lcol = textcolor();
|
||||
Fl_Align talign = FL_ALIGN_LEFT;
|
||||
// check for all the @-lines recognized by XForms:
|
||||
//#if defined(__GNUC__)
|
||||
//#warning FIXME This maybe needs to be more UTF8 aware now...?
|
||||
//#endif /*__GNUC__*/
|
||||
while (*str == format_char() && *++str && *str != format_char()) {
|
||||
switch (*str++) {
|
||||
case 'l': case 'L': tsize = 24; break;
|
||||
|
@ -1455,7 +1455,9 @@ void Fl_Help_View::format() {
|
||||
|
||||
popfont(font, fsize, fcolor);
|
||||
|
||||
//#if defined(__GNUC__)
|
||||
//#warning FIXME this isspace & 255 test will probably not work on a utf8 stream... And we use it everywhere!
|
||||
//#endif /*__GNUC__*/
|
||||
while (isspace((*ptr)&255))
|
||||
ptr ++;
|
||||
|
||||
|
@ -340,7 +340,11 @@ void fl_new_ic()
|
||||
XIMStyles* xim_styles = NULL;
|
||||
|
||||
#if USE_XFT
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#warning XFT support here
|
||||
#endif /*__GNUC__*/
|
||||
|
||||
if (!fs) {
|
||||
fnt = NULL;//fl_get_font_xfld(0, 14);
|
||||
if (!fnt) {fnt = "-misc-fixed-*";must_free_fnt=false;}
|
||||
@ -451,7 +455,11 @@ void fl_set_spot(int font, int size, int X, int Y, int W, int H, Fl_Window *win)
|
||||
XFreeFontSet(fl_display, fs);
|
||||
}
|
||||
#if USE_XFT
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#warning XFT support here
|
||||
#endif /*__GNUC__*/
|
||||
|
||||
fnt = NULL; // fl_get_font_xfld(font, size);
|
||||
if (!fnt) {fnt = "-misc-fixed-*";must_free_fnt=false;}
|
||||
fs = XCreateFontSet(fl_display, fnt, &missing_list,
|
||||
|
@ -299,9 +299,9 @@ double fl_width(unsigned int c) {
|
||||
|
||||
void fl_text_extents(const char *c, int n, int &dx, int &dy, int &W, int &H) {
|
||||
|
||||
#if !defined(WIN32) && !defined(sgi) || defined(CYGWIN)
|
||||
#if defined(__GNUC__)
|
||||
#warning fl_text_extents is only a test stub in Xlib build at present
|
||||
#endif
|
||||
#endif /*__GNUC__*/
|
||||
|
||||
W = 0; H = 0;
|
||||
fl_measure(c, W, H, 0);
|
||||
|
@ -554,7 +554,11 @@ static void fl_drawUCS4(const FcChar32 *str, int n, int x, int y) {
|
||||
|
||||
|
||||
void fl_rtl_draw(const char* c, int n, int x, int y) {
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#warning Need to improve this XFT right to left draw function
|
||||
#endif /*__GNUC__*/
|
||||
|
||||
// This actually draws LtoR, but aligned to R edge with the glyph order reversed...
|
||||
// but you can't just byte-rev a UTF-8 string, that isn't valid.
|
||||
// You can reverse a UCS4 string though...
|
||||
|
@ -114,9 +114,10 @@ void glutStrokeString(void* fontID, const unsigned char *string) {
|
||||
* A newline will simply translate the next character's insertion
|
||||
* point back to the start of the line and down one line.
|
||||
*/
|
||||
#if !defined(WIN32) && !defined(sgi) || defined(CYGWIN)
|
||||
|
||||
#if defined(__GNUC__)
|
||||
#warning FIXME This needs to be UTF aware now
|
||||
#endif
|
||||
#endif /*__GNUC__*/
|
||||
|
||||
while ((c = *string++) != 0) {
|
||||
if (c < font->Quantity) {
|
||||
|
@ -49,7 +49,9 @@ int fl_scandir(const char *dirname, struct dirent ***namelist,
|
||||
if (!findIn) return -1;
|
||||
strcpy(findIn, dirname);
|
||||
|
||||
//#if defined(__GNUC__)
|
||||
//#warning FIXME This probably needs to be MORE UTF8 aware now
|
||||
//#endif /*__GNUC__*/
|
||||
for (d = findIn; *d; d++) if (*d=='/') *d='\\';
|
||||
if ((len==0)) { strcpy(findIn, ".\\*"); }
|
||||
if ((len==2)&&findIn[1]==':'&&isalpha(findIn[0])) { *d++ = '\\'; *d = 0; }
|
||||
|
Loading…
Reference in New Issue
Block a user