--
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/2f54295b-a4d4-ecb2-c62b-14668d0fd70f%40online.de.
I'll try that ASAP, but likely not tomorrow because I need to do some
other stuff.
Regarding the code changes: WOW, that's a lot of code!
The following is just for my curiosity:
I'm seeing also that much code has been copied which might not be needed
due to the driver structure. What are your plans, will you do a mass
cleanup when the Wayland code is (almost) finished? I'm asking because
I'm concerned about duplicated code. One example seems to be timer
related code which could be reused rather than duplicated etc. etc.. I
take it that you first copied the entire driver code and are now working
on fleshing out the needed changes and what doesn't need to be changed.
Is that about correct?
Interesting. I see that you added the library to the FLTK repo. Are
there plans to (finally) bundle it or would we take it as a prerequisite
to be installed by developers? Generally I'd prefer the latter, but I
don't know how well it is supported by (Linux) distros. Can you share
your thoughts about this?
This all seems like a good idea.
Using that existing libdecor code is probably an ok start, but I would like to see it done reusing as much functionality from FLTK as possible. It does look like that code is pretty minimal (ie it does not link with GTK) so that is a relief. In the end the FlWindow object would do all of this.
I assume this is using Cairo for rendering? You should, as that is what the titlebar code is using. The Cairo code needs to be fixed up so it is an acceptable backend for FLTK, and use the same cairo api in both the X11 and Wayland versions.
Le dimanche 6 juin 2021 à 21:03:01 UTC+2, Albrecht Schlosser a écrit :
I'll try that ASAP, but likely not tomorrow because I need to do some
other stuff.
I'm looking forward to your feedback.
--
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/eccc8fa7-ccb8-4882-5de4-ca59d6f847df%40online.de.
On 6/7/21 12:03 PM, Albrecht Schlosser wrote:
On 6/7/21 8:44 AM Manolo wrote:
Le dimanche 6 juin 2021 à 21:03:01 UTC+2, Albrecht Schlosser a écrit :
I'll try that ASAP, but likely not tomorrow because I need to do some
other stuff.
I'm looking forward to your feedback.
Well, not really much feedback, I just played with the demo programs. I'm really impressed how well everything is already. Great job!
Conclusion: Using Cairo doesn't seem to be that slow in conjunction with Wayland which uses (AFAICT) memory mapped buffers for communication (rather than sockets or network connections like X11 does). How does "local X11" communicate? Anybody?
On 6/7/21 1:51 PM, Albrecht Schlosser wrote:
There was a good reason Wayland wanted CSD.
What is CSD? Client Server XXX ???
Pretty sure that's "Client Side Decorations"
https://blogs.gnome.org/tbernard/2018/01/26/csd-initiative/
--
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/60E28EC3-E2DE-4B98-B0B9-C8AADA9CE3C3%40gmail.com.
On 6/7/21 2:26 PM, Bill Spitzak wrote:
What I meant for Device was to replace it with code like this:
#if X11#include <X11code.C>#elif Windows#include <Windowscode.C>
I had used that technique in the native file chooser, but it was changed.
That technique was generally recommended IIRC in an old O'Reilly book
on multiple platform code management I've had for decades now.
--
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...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/fltkcoredev/13c59d6a-ef8b-298b-c932-e3858c8803dc%40online.de.
test/doublebuffer runs "faster than ever seen" and there's no noticeable difference between single and double buffer which is what I expected. Manolo, there is no difference, right?
test/glpuzzle does "funny things" (TM) if you let the game rotate (drag the mouse and see). Borders disappear, sometime there's a see-through effect.
Not all cursors appear as they should (test/cursor).
Screen scaling (ctrl/+/-/0) doesn't seem to work yet. Maybe in GL windows though (not sure). I've seen some weird effects.
test/resize-example* programs seem all to crash like this:
$ ./resize-example1
makeWindow:0x22499c0 wl_compositor_create_surface=0x2253bc0 scale=1
Segmentation fault (core dumped)
Oh, and one thing I did not expect:
./configure --enable-wayland --enable-cairo
doesn't work together. There are compilation errors (I don't remember exactly, something about fl_gc and unsupported platform; I could reproduce it but I'd need to reconfigure the build). I take it this is just the platform tests in some header files, but anyway, that's not important at all.
Manolo, well done! It's awesome to see that FLTK can work with Wayland.
Conclusion: Using Cairo doesn't seem to be that slow in conjunction with Wayland which uses (AFAICT) memory mapped buffers for communication (rather than sockets or network connections like X11 does). How does "local X11" communicate? Anybody?
Manolo, would you like me to add CMake support? I'd like to help if I can.
Read through the libdecor code and it appears to be drawing everything directly. There is a "plugin", perhaps with the intention that the style of the window borders can change by changing the plugin, but I don't agree with this as the api to the plugin is going to swiftly grow to a baroque monstrosity, just like every other attempt to control the borders. There was a good reason Wayland wanted CSD. I personally do not see any problem with drawing the window borders ourselves, any complaint that they look different is IMHO not logical if the difference in appearance of every other widget is considered acceptable. Also not using this library will mean a single Wayland surface can be used, instead of two.
Here's an investigation with gdb on program test/hello searching for what context calls static function draw_title_text()from libdecor's src/plugin/cairo/libdecor-cairo.c which draws the text of window titlebars :
1) When a window is first created, libfltk code calls libdecor code which draws the window title :
#0 ... (call stack elided)
2) Each time the window is deactivated or activated, its titlebar gets redrawn.
This is done by libfltk calling libwayland-client.so which calls libffi.so (what is it?)
which calls libdecor-0.1.so to draw the title :
#0 ...
This, I interpret as showing that a shared library plugin is necessary for libdecor. Am I wrong?
libdecor
will look for plugins in the target
directory of the installation. Therefore, when running the demos
directly from the build
directory, no plugins
will be found and the fallback plugin without any decorations
will be used."FLTK could stop pulling in future libdecor updates when we would feel it's becoming'a baroque monstrosity'.I understand that FLTK could do CSD drawing a custom titlebar in the same surface as the window main area.I see this path has not been followed by libdecor. May be it's because libdecor wants to be compatiblewith desktops (and I believe KDE is one) that provide server-side decoration (SSD).
Le lundi 7 juin 2021 à 21:03:45 UTC+2, Albrecht Schlosser a écrit :
test/doublebuffer runs "faster than ever seen" and there's no noticeable difference between single and double buffer which is what I expected. Manolo, there is no difference, right?
Yes. There's no such thing as a Wayland single window because it's not possible with Wayland to draw in the window. All drawing goes to a buffer, and then this buffer is "committed" to Wayland. The two windows of test/doublebuffer follow exactly the same code.
test/glpuzzle does "funny things" (TM) if you let the game rotate (drag the mouse and see). Borders disappear, sometime there's a see-through effect.
Bill's hint below about the z buffer is probably the way to look to fix that. Help needed. I dont know GL.
Not all cursors appear as they should (test/cursor).
Yes, that happens with some Ubuntu themes but not all, and not with Debian, where all cursor shapes work.Cursors are searched in a system folder and some shapes are absent for some Ubuntu themes. Who knows why?
Screen scaling (ctrl/+/-/0) doesn't seem to work yet. Maybe in GL windows though (not sure). I've seen some weird effects.
Wayland was born when HighDPI existed, so it contains natively a way to handle HighDPI in the form of an integer scale whose valuegrows with pixel density. FLTK apps follow this scaling without need for change nor ctrl/+/.
Go to Settings -> Display -> Scale and set it to 200% or 300 % on a large display, you'll see FLTK Wayland apps follow the change.
They're not adaptive while running yet, though.
Manolo, would you like me to add CMake support? I'd like to help if I can.
Yes I do. Many thanks.
But I believe we should first decide whether we want to include Wayland in the FLTK repoand whether we do that as a new branch, or in the main branch, just like Android or Pico.
I would also appreciate feedback about use on a native Linux system (as opposed to a virtual machine).
On 6/8/21 8:52 AM Manolo wrote:
I would also appreciate feedback about use on a native Linux system (as opposed to a virtual machine).
I'll try to test on my bare metal Linux when time permits. I think I did already install 'weston' so I could maybe run it directly on my notebook.
Go to Settings -> Display -> Scale and set it to 200% or 300 % on a large display, you'll see FLTK Wayland apps follow the change.I can't find such a setting in my Ubuntu VM. I only have "Resolution" and "Fractional Scaling" (see screenshot).
FLTK apps don't seem to honor the environment variable FLTK_SCALING_FACTOR completely (see image). The scaling factor is recognized though (scale: 1.30) in both cases.