Make sure fl_size_, fl_font_, and fl_xfont are initialized and used.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2297 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Michael R Sweet
2002-06-08 13:07:19 +00:00
parent 5d7f42585b
commit be16fa3027
4 changed files with 20 additions and 19 deletions
+5 -4
View File
@@ -1,5 +1,5 @@
//
// "$Id: fl_font_mac.cxx,v 1.1.2.6 2002/06/07 19:55:44 easysw Exp $"
// "$Id: fl_font_mac.cxx,v 1.1.2.7 2002/06/08 13:07:19 easysw Exp $"
//
// MacOS font selection routines for the Fast Light Tool Kit (FLTK).
//
@@ -125,10 +125,11 @@ static Fl_FontSize* find(int fnum, int size) {
////////////////////////////////////////////////////////////////
// Public interface:
int fl_font_;
int fl_size_;
int fl_font_ = 0;
int fl_size_ = 0;
void fl_font(int fnum, int size) {
if (fnum == fl_font_ && size == fl_size_) return;
fl_font(find(fnum, size));
}
@@ -154,5 +155,5 @@ void fl_draw(const char* str, int n, int x, int y) {
}
//
// End of "$Id: fl_font_mac.cxx,v 1.1.2.6 2002/06/07 19:55:44 easysw Exp $".
// End of "$Id: fl_font_mac.cxx,v 1.1.2.7 2002/06/08 13:07:19 easysw Exp $".
//
+4 -4
View File
@@ -1,5 +1,5 @@
//
// "$Id: fl_font_win32.cxx,v 1.9.2.3.2.3 2002/03/06 18:11:01 easysw Exp $"
// "$Id: fl_font_win32.cxx,v 1.9.2.3.2.4 2002/06/08 13:07:19 easysw Exp $"
//
// WIN32 font selection routines for the Fast Light Tool Kit (FLTK).
//
@@ -119,8 +119,8 @@ static Fl_FontSize* find(int fnum, int size) {
////////////////////////////////////////////////////////////////
// Public interface:
int fl_font_;
int fl_size_;
int fl_font_ = 0;
int fl_size_ = 0;
//static HDC font_gc;
void fl_font(int fnum, int size) {
@@ -156,5 +156,5 @@ void fl_draw(const char* str, int n, int x, int y) {
//
// End of "$Id: fl_font_win32.cxx,v 1.9.2.3.2.3 2002/03/06 18:11:01 easysw Exp $".
// End of "$Id: fl_font_win32.cxx,v 1.9.2.3.2.4 2002/06/08 13:07:19 easysw Exp $".
//
+5 -5
View File
@@ -1,5 +1,5 @@
//
// "$Id: fl_font_x.cxx,v 1.10.2.2 2002/03/06 19:42:30 easysw Exp $"
// "$Id: fl_font_x.cxx,v 1.10.2.3 2002/06/08 13:07:19 easysw Exp $"
//
// Standard X11 font selection code for the Fast Light Tool Kit (FLTK).
//
@@ -191,9 +191,9 @@ static Fl_FontSize* find(int fnum, int size) {
////////////////////////////////////////////////////////////////
// Public interface:
int fl_font_;
int fl_size_;
XFontStruct* fl_xfont;
int fl_font_ = 0;
int fl_size_ = 0;
XFontStruct* fl_xfont = 0;
static GC font_gc;
void fl_font(int fnum, int size) {
@@ -250,5 +250,5 @@ void fl_draw(const char* str, int n, int x, int y) {
}
//
// End of "$Id: fl_font_x.cxx,v 1.10.2.2 2002/03/06 19:42:30 easysw Exp $".
// End of "$Id: fl_font_x.cxx,v 1.10.2.3 2002/06/08 13:07:19 easysw Exp $".
//
+6 -6
View File
@@ -1,5 +1,5 @@
//
// "$Id: fl_font_xft.cxx,v 1.4.2.6 2002/05/16 02:16:17 easysw Exp $"
// "$Id: fl_font_xft.cxx,v 1.4.2.7 2002/06/08 13:07:19 easysw Exp $"
//
// Xft font code for the Fast Light Tool Kit (FLTK).
//
@@ -86,11 +86,11 @@ Fl_Fontdesc* fl_fonts = built_in_table;
#define current_font (fl_fontsize->font)
int fl_font_;
int fl_size_;
XFontStruct* fl_xfont;
int fl_font_ = 0;
int fl_size_ = 0;
XFontStruct* fl_xfont = 0;
const char* fl_encoding_ = "iso8859-1";
Fl_FontSize* fl_fontsize;
Fl_FontSize* fl_fontsize = 0;
void fl_font(int fnum, int size) {
if (fnum == fl_font_ && size == fl_size_ &&
@@ -226,5 +226,5 @@ void fl_draw(const char *str, int n, int x, int y) {
}
//
// End of "$Id: fl_font_xft.cxx,v 1.4.2.6 2002/05/16 02:16:17 easysw Exp $"
// End of "$Id: fl_font_xft.cxx,v 1.4.2.7 2002/06/08 13:07:19 easysw Exp $"
//