Probably better to add the current color to the font stack. [email protected] wrote: > Author: fabien > Date: 2009-01-12 09:14:52 -0800 (Mon, 12 Jan 2009) > New Revision: 6628 > Log: > STR#890 fix attempt: correct imbricATED font color handling. > > Modified: > branches/branch-1.1/src/Fl_Help_View.cxx > > Modified: branches/branch-1.1/src/Fl_Help_View.cxx > =================================================================== > --- branches/branch-1.1/src/Fl_Help_View.cxx 2009-01-12 16:45:55 UTC (rev > 6627) > +++ branches/branch-1.1/src/Fl_Help_View.cxx 2009-01-12 17:14:52 UTC (rev > 6628) > @@ -472,8 +472,8 @@ > // Box to draw... > int underline, // Underline text? > xtra_ww; // Extra width for underlined space > between words > + Fl_Color prev_text_color=FL_RED; // Saved text color before > font color modification > > - > // Draw the scrollbar(s) and box first... > ww = w() ; > hh = h(); > @@ -741,7 +741,8 @@ > else if (strcasecmp(buf, "FONT") == 0) > { > if (get_attr(attrs, "COLOR", attr, sizeof(attr)) != NULL) { > - fl_color(get_color(attr, textcolor_)); > + prev_text_color = textcolor_; > + fl_color( (textcolor_ = get_color(attr, textcolor_)) ); > } > > if (get_attr(attrs, "FACE", attr, sizeof(attr)) != NULL) { > @@ -768,6 +769,7 @@ > } > else if (strcasecmp(buf, "/FONT") == 0) > { > + textcolor_ = prev_text_color; > fl_color(textcolor_); > popfont(font, fsize); > } > > _______________________________________________ > fltk-commit mailing list > [email protected] > http://lists.easysw.com/mailman/listinfo/fltk-commit
-- ______________________________________________________________________ Michael Sweet, Easy Software Products mike at easysw dot com _______________________________________________ fltk-dev mailing list [email protected] http://lists.easysw.com/mailman/listinfo/fltk-dev
