From 915ea80f4590280e431fb4ebbec0c6496b9a054e Mon Sep 17 00:00:00 2001 From: ManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com> Date: Wed, 22 Jan 2025 18:44:13 +0100 Subject: Windows: replace "Arial" by "Microsoft Sans Serif" for the FL_HELVETICA font family Users who need the old behavior for strict backwards compatibility under Windows can load the previous (Arial) font at program startup with only a few lines of code: #ifdef _WIN32 // reset Windows fonts to pre-1.4.2 state Fl::set_font(FL_HELVETICA, " Arial"); Fl::set_font(FL_HELVETICA + 1, "BArial"); Fl::set_font(FL_HELVETICA + 2, "IArial"); Fl::set_font(FL_HELVETICA + 3, "PArial"); #endif --- src/drivers/GDI/Fl_GDI_Graphics_Driver_font.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/drivers/GDI/Fl_GDI_Graphics_Driver_font.cxx b/src/drivers/GDI/Fl_GDI_Graphics_Driver_font.cxx index c5a6e0308..f350dcd40 100644 --- a/src/drivers/GDI/Fl_GDI_Graphics_Driver_font.cxx +++ b/src/drivers/GDI/Fl_GDI_Graphics_Driver_font.cxx @@ -1,7 +1,7 @@ // // Windows font utilities for the Fast Light Tool Kit (FLTK). // -// Copyright 1998-2018 by Bill Spitzak and others. +// Copyright 1998-2025 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 @@ -280,10 +280,10 @@ Fl_GDI_Font_Descriptor::~Fl_GDI_Font_Descriptor() { // WARNING: if you add to this table, you must redefine FL_FREE_FONT // in Enumerations.H & recompile!! static Fl_Fontdesc built_in_table[] = { -{" Arial"}, -{"BArial"}, -{"IArial"}, -{"PArial"}, + {" Microsoft Sans Serif"}, + {"BMicrosoft Sans Serif"}, + {"IMicrosoft Sans Serif"}, + {"PMicrosoft Sans Serif"}, {" Courier New"}, {"BCourier New"}, {"ICourier New"}, -- cgit v1.2.3