FLTK logo

Re: [fltk.coredev] Re: RFC: Removal of FL_CFG_* macros and config_lib.h

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.coredev  ]
 
Previous Message ]New Message | Reply ]Next Message ]

Re: Re: RFC: Removal of FL_CFG_* macros and config_lib.h Bill Spitzak Feb 18, 2021  
 
I don't believe anything other than constexpr declared in the headers, or macros are useful for this. Making them look like variables or function calls is really misleading and quite confusing.


On Thu, Feb 18, 2021 at 8:55 AM Albrecht Schlosser <AlbrechtS.fltk@online.de> wrote:
On 2/18/21 3:02 PM Manolo wrote:
>
> On Thursday, February 18, 2021 at 1:52:08 PM UTC+1 Albrecht Schlosser wrote:
>
>     Question 1: keep these runtime features?
>
> I'm not completely sure but my impression is that until FLTK can support
> a build in which
> these global variables (or function results) can take distinct values
> according to the
> application's running context, these variables/functions are not useful.
> They may even give to FLTK
> users a false impression that FLTK supports alternative graphics or
> printing systems.
>
> One expressive situation is under macOS, where FLTK can be built to use
> either the Quartz
> or X11 drawing systems. Any FLTK app uses either one or the other in a
> invariable way.
> Another case arises with the proposed GDI+ branch. There, either GDI+ or
> GDI is used,
> and there's no way for an app to choose between them at run-time.

These runtime info functions (or static class variables as they are
currently) are only meant to give info to the program, not to be changed
at runtime. They would be useful for instance if a program is linked
against a shareable library and can query whether a certain function is
available or on which OS or platform (X11 vs. Quartz on macOS etc.) it
is running.

I'm also not sure what this info would be good for, at least the program
could tell in an warning message "this program needs Cairo support but
the FLTK library it is linked to does not support Cairo" or something
like that.

Matt created these global variables together with all these macros
(config_lib.h) in the pre-driver aera, i.e. in the "fltk-porting" branch
(or whatever that name was) before the new driver model was developed.

You can compare this with the way you can use FL_VERSION macros and you
can query the runtime version with Fl::api_version() etc..

That said, we /could/ remove all this now, before FLTK 1.4 is released
because it would be new in 1.4 (not in 1.3.x).

Useful or not? I'm not sure as well, that's why I asked for opinions and
comments.

--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/d9aa231e-966a-3440-e167-6c3ddb6fb587%40online.de.

--
You received this message because you are subscribed to the Google Groups "fltk.coredev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fltkcoredev+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/CAL-8oAgFErE-7rpMSYAvfb%2BuUt5qCs8M%3D2agdqwK7rWCaGdHCQ%40mail.gmail.com.
Direct Link to Message ]
 
     
Previous Message ]New Message | Reply ]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'.