FLTK logo

Re: [fltk.coredev] Exploration: FLTK platform compatible with both Wayland and X11

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: Exploration: FLTK platform compatible with both Wayland and X11 Bill Spitzak Apr 05, 2022  
 
This sounds like exactly what is needed and wanted. I might change the second option name to OPTION_USE_CAIRO for consistency with the others


On Tue, Apr 5, 2022 at 6:14 AM Manolo <manolo.gouy@gmail.com> wrote:


Le jeudi 31 mars 2022 à 18:36:28 UTC+2, Albrecht Schlosser a écrit :
On 3/31/22 16:07 Manolo wrote:
> It's of course necessary to maintain in FLTK 1.4 an X11-only version
> of the code.
> That's necessary for relatively old systems because Wayland requires
> recent Linux versions.
> That's also necessary for Unix-but-not-Linux systems (e.g., NetBSD,
> FreeBSD, Darwin) because there's no Wayland outside Linux at this point.
>
> One possibility to be considered could be as follows:
>
> FLTK 1.4 would propose two "platforms" for Unix systems
>
> 1) the X11 platform, as it's now in the git repo. It would be usable
> on a large set of systems, Linux or Unix, old or new, Darwin, Cygwin.
>
> 2) a new in 1.4 platform which would be for recent Linux systems only,
> and would be a hybrid library with Wayland and X11 backends. Both
> backends would draw with Cairo and use Pango for text.
> That would be a merge of the present wayland and display-cairo branches.
> Maintainers of the FLTK packages in Linux distributions could be told
> to consider using this platform for FLTK 1.4 and above.
> It would be produced with OPTION_USE_WAYLAND under CMake or with
> ./configure --enable-wayland

+1

I believe this is the way to go. As Bill suggested, making the "hybrid"
FLTK library draw with Cairo in both environments (X11 and Wayland)
appears to be the optimal way, particularly because it would (hopefully)
be easier to maintain but also for better compatibility between the X11
and Wayland environments.

One other option I'd like to be considered is the possibility to use the
"classic" X11 platform (i.e. the X11-only FLTK lib) with Cairo as the
drawing interface. This could be a configure/CMake option, I don't think
we'd need both in one X11 only FLTK lib (the default would be X11
drawing as written above).

These things are now available in the wayland branch of my fltk fork

CMake OPTION_USE_WAYLAND produces a hybrid Wayland/X11 library
whose X11 leg draws with Cairo.

The new OPTION_CAIROXLIB produces a X11 library using Cairo to draw
to X11 windows and to offscreen buffers.

OPTION_USE_PANGO produces a X11 library using Xlib to draw and Pango to draw text.

The default run produces a X11 library using Xlib to draw and Xft to draw text.

My proposal would be to use that for FLTK 1.4.
 

--
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/bf5c2357-e721-463e-82b4-4624dec43b3cn%40googlegroups.com.

--
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-8oAg2X9Cj6%2B8uScTHHrASXtJMH3MoL%2BWTeJs9UwnUnp%2BVcg%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'.