FLTK logo

[master] f097141 - Move member q_width from class Fl_Font_Descriptor to Fl_Quartz_Font_Descriptor.

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.commit  ]
 
Previous Message ]Next Message ]

[master] f097141 - Move member q_width from class Fl_Font_Descriptor to Fl_Quartz_Font_Descriptor. "ManoloFLTK" Jul 06, 2022  
 
commit f0971416626f5b2b1e64a8c9bc86734e81a193e8
Author:     ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>
AuthorDate: Wed Jul 6 10:18:40 2022 +0200
Commit:     ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>
CommitDate: Wed Jul 6 10:18:40 2022 +0200

    Move member q_width from class Fl_Font_Descriptor to Fl_Quartz_Font_Descriptor.
    
    That's because this member is used only in Fl_Quartz_Font_Descriptor.

 FL/Fl_Graphics_Driver.H                        | 2 +-
 src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx | 3 +--
 src/drivers/Quartz/Fl_Font.H                   | 1 +
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git FL/Fl_Graphics_Driver.H FL/Fl_Graphics_Driver.H
index 2898aa5..16b39f0 100644
--- FL/Fl_Graphics_Driver.H
+++ FL/Fl_Graphics_Driver.H
@@ -390,7 +390,7 @@ public:
   Fl_Fontsize size; /**< font size */
   Fl_Font_Descriptor(const char* fontname, Fl_Fontsize size);
   FL_EXPORT ~Fl_Font_Descriptor() {}
-  short ascent, descent, q_width;
+  short ascent, descent;
   unsigned int listbase;// base of display list, 0 = none
 };
 
diff --git src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx
index a8f5d90..669f9e8 100644
--- src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx
+++ src/drivers/Cairo/Fl_Cairo_Graphics_Driver.cxx
@@ -1090,10 +1090,9 @@ Fl_Cairo_Font_Descriptor::Fl_Cairo_Font_Descriptor(const char* name, Fl_Fontsize
 #else
   line_height = (pango_font_metrics_get_ascent(metrics) + pango_font_metrics_get_descent(metrics)) * 1.025 + 0.5;
 #endif
-  q_width = 0; // useless;
   pango_font_metrics_unref(metrics);
   g_object_unref(fontset);
-//fprintf(stderr, "[%s](%d) ascent=%d descent=%d q_width=%d\n", name, size, ascent, descent, q_width);
+//fprintf(stderr, "[%s](%d) ascent=%d descent=%d\n", name, size, ascent, descent);
 }
 
 
diff --git src/drivers/Quartz/Fl_Font.H src/drivers/Quartz/Fl_Font.H
index 36f7e25..5e24ce7 100644
--- src/drivers/Quartz/Fl_Font.H
+++ src/drivers/Quartz/Fl_Font.H
@@ -39,6 +39,7 @@ public:
   ATSUTextLayout layout;
   ATSUStyle style;
 # endif
+  short q_width;
 };
 
 extern FL_EXPORT Fl_Fontdesc *fl_fonts; // the table
Direct Link to Message ]
 
     
Previous Message ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.