summaryrefslogtreecommitdiff
path: root/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-02-01 16:32:21 +0100
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2026-02-01 16:32:21 +0100
commite0405d2135939d08289205e3a38df329076e16c1 (patch)
tree4d4facf614ba6062a2df194bd14d2f99021cfad7 /src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
parent4be596a30673a67ee7d5a0bdc8095922a498eed5 (diff)
macOS: remove code present only to support macOS versions 10.3 and 10.4.
This is a first step towards removing the code related to support of old macOS versions that are not compatible with C++11 which FLTK 1.5 requires.
Diffstat (limited to 'src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H')
-rw-r--r--src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H35
1 files changed, 1 insertions, 34 deletions
diff --git a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
index ca1ffce04..0afc7369e 100644
--- a/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
+++ b/src/drivers/Quartz/Fl_Quartz_Graphics_Driver.H
@@ -2,7 +2,7 @@
// Definition of Apple Quartz graphics driver
// for the Fast Light Tool Kit (FLTK).
//
-// Copyright 2010-2022 by Bill Spitzak and others.
+// Copyright 2010-2026 by Bill Spitzak and others.
//
// This library is free software. Distribution and use rights are outlined in
// the file "COPYING" which should have been included with this file. If this
@@ -27,16 +27,6 @@
#include <FL/Fl_Graphics_Driver.H>
#include <ApplicationServices/ApplicationServices.h>
-// condition for the ATSU API to be available at compile time
-#if ( (!defined(__LP64__) || !__LP64__) \
- && MAC_OS_X_VERSION_MAX_ALLOWED < MAC_OS_X_VERSION_10_11 \
- && MAC_OS_X_VERSION_MIN_REQUIRED < MAC_OS_X_VERSION_10_5 \
- )
-#define HAS_ATSU 1
-#else
-#define HAS_ATSU 0
-#endif
-
struct Fl_Fontdesc;
class Fl_Quartz_Font_Descriptor;
@@ -143,30 +133,7 @@ protected:
void set_fontname_in_fontdesc(Fl_Fontdesc *f);
void uncache_pixmap(fl_uintptr_t p) FL_OVERRIDE;
-#if HAS_ATSU && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_5
- enum {use_CoreText = 1, use_ATSU};
- static int CoreText_or_ATSU;
- static void init_CoreText_or_ATSU();
- void draw_CoreText(const char *str, int n, float x, float y);
- double width_CoreText(const UniChar* txt, int n);
- void descriptor_init_CoreText(const char* name, Fl_Fontsize Size, Fl_Quartz_Font_Descriptor *d);
- void text_extents_CoreText(const char*, int n, int& dx, int& dy, int& w, int& h);
- Fl_Font set_fonts_CoreText(const char* xstarname);
-
- void draw_ATSU(const char *str, int n, float x, float y);
- double width_ATSU(const UniChar* txt, int n);
- void descriptor_init_ATSU(const char* name, Fl_Fontsize Size, Fl_Quartz_Font_Descriptor *d);
- void text_extents_ATSU(const char*, int n, int& dx, int& dy, int& w, int& h);
- Fl_Font set_fonts_ATSU(const char* xstarname);
-
- // define 2 kinds of pointers to member function
- typedef void (Fl_Quartz_Graphics_Driver::*pter_to_draw_member)(const char *str, int n, float x, float y);
- typedef double (Fl_Quartz_Graphics_Driver::*pter_to_width_member)(const UniChar *str, int n);
- static pter_to_draw_member CoreText_or_ATSU_draw;
- static pter_to_width_member CoreText_or_ATSU_width;
-#else
void descriptor_init(const char* name, Fl_Fontsize Size, Fl_Quartz_Font_Descriptor *d);
-#endif
void overlay_rect(int x, int y, int w , int h) FL_OVERRIDE;
float override_scale() FL_OVERRIDE;
void restore_scale(float) FL_OVERRIDE;