Re: [fltk.coredev] RFC: API for screen sizes on mobile devices

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: RFC: API for screen sizes on mobile devices "'melcher.... 15:28 Sep 02 top right image

Albrecht Schlosser schrieb am Mittwoch, 2. September 2020 um 13:27:49 UTC+2:
On 9/2/20 10:21 AM 'melcher...' via fltk.coredev wrote:
I'm -1 on such API's as Fl::hint(int, int, int...). They are confusing
and hard to implement (need switch(..) etc.). Also, extension of the API
using other datatypes would be possible but less obvious.

I'd propose to introduce a new (static?) object type like Fl_Screen or
similar with virtual methods that can easily be extended (one method per
logical function).

An Fl_Screen class array with some accessor would also solve the increasing number of Fl::screen_...() methods.
The methods above could then be:


Preferably inside a if (platform==Android) { ... }. On a desktop machine, those calls alone would be misleading, even if they are not implemented in the driver. But yeah, ok. I see your point.

The device type would not be necessary because it would be "known" by
the (virtual) method implementation.
This is consistent with the current driver model and getter methods
would be very simple to call, supposedly only in driver related code parts.

OK, makes sense. I'll have to implement an automated version of this first anyway, and then I will get back to a possible API.

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
To view this discussion on the web visit
Direct Link to Message ]
bottom left image   bottom right image
Previous Message ]New Message | Reply ]Next Message ]

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