Commit Graph

10037 Commits

Author SHA1 Message Date
ManoloFLTK
2c1effc385 Wayland: Fix Fl_Gl_Window_Driver::newGlWindowDriver() for shared libs 2022-08-30 08:15:21 +02:00
ManoloFLTK
95c851fda1 Set Fl_Graphics_Driver::set_color(Fl_Color, unsigned) used by macOS, Wayland and display-cairo. 2022-08-30 07:58:16 +02:00
Albrecht Schlosser
510f711513 Improve selection of Wayland or X11 backend
Calling fl_disable_wayland() at runtime must have highest priority
before environment variables are considered.
2022-08-29 19:56:18 +02:00
Albrecht Schlosser
746135f0ae X11: Fix rescaling of non-resizable window (issue #491) 2022-08-29 18:55:01 +02:00
ManoloFLTK
1ca767eb13 Hybrid Wayland/X11 : more accurate writing of fl_wl_display(). 2022-08-29 18:49:15 +02:00
ManoloFLTK
9276ade07b Wayland/X11 hybrid: fix crash of test program demo. 2022-08-29 18:34:11 +02:00
Albrecht Schlosser
c20e7d9efc Update dependencies, fix trailing whitespace 2022-08-29 14:26:28 +02:00
ManoloFLTK
c720aae515 Make hybrid Wayland/X11 platform. 2022-08-29 12:15:32 +02:00
ManoloFLTK
28981f6fd3 Wayland/Libdecor: update from upstream
These changes fix issue #474.
2022-08-27 10:15:40 +02:00
Albrecht Schlosser
6a546d4e9c Fix dependencies and whitespace errors
No "real" code changes, but dependencies can affect building.
2022-08-25 22:04:59 +02:00
ManoloFLTK
6064518100 Remove unneeded FL_EXPORT declaration. 2022-08-25 15:48:54 +02:00
ManoloFLTK
feac10ec89 Wayland: reduce the number of platform-specific FL_EXPORT directives. 2022-08-25 10:42:58 +02:00
ManoloFLTK
51e9b28f39 Add FL_EXPORT directives to support building shared libs with -no-undefined 2022-08-24 15:09:30 +02:00
ManoloFLTK
80ecf605ec Wayland: Fix obscure problem when closing file dialog under recent OS versions.
The problem is that the app sometimes stops after closing a file dialog window.
It results in fact from a bug in function draw_title_bar of libdecor-gtk.c that erroneously
calls libdecor_frame_set_max_content_size(). This bug is being proposed to be fixed
by a MR to libdecor.

But moving the libdecor_frame_set_min/max_content_size() calls after the capability changes
hides the bug, and the problem with file dialog doesn't show.
2022-08-23 16:20:47 +02:00
ManoloFLTK
4611327672 Comment-only changes. 2022-08-23 09:04:14 +02:00
ManoloFLTK
1631e39187 Add FL_EXPORT directives erroneously removed at 7deff86. 2022-08-23 09:02:06 +02:00
ManoloFLTK
a70bd69cfb Fix argument of glMatrixMode() call. 2022-08-21 10:14:18 +02:00
ManoloFLTK
d5a1e7feb9 Add static Fl_Wayland_Window_Driver::gl_plugin() member function. 2022-08-20 17:26:02 +02:00
ManoloFLTK
7deff86b5d Remove FL_EXPORT qualifier from platform-specific class declarations. 2022-08-20 10:16:32 +02:00
ManoloFLTK
b24379133f Add int Fl::system(const char *command) static member function. 2022-08-20 09:57:00 +02:00
ManoloFLTK
ce2f024bce Fl_Graphics_Driver: remove unused virtual qualifiers. 2022-08-19 10:47:42 +02:00
ManoloFLTK
6194b736eb Add a few missing virtual members to Fl_Cairo_Graphics_Driver. 2022-08-18 16:22:28 +02:00
ManoloFLTK
2cfb5fcc57 Document Fl_Gl_Window::draw_begin() and draw_end(). 2022-08-18 11:21:35 +02:00
ManoloFLTK
f927a3047c Simplify class Fl_OpenGL_Display_Device. 2022-08-18 08:53:19 +02:00
ManoloFLTK
5227ee09a3 Remove un-necessary Fl_Wayland_Gl_Window_Driver::capture_gl_rectangle(). 2022-08-18 08:10:26 +02:00
Albrecht Schlosser
fd2f076b78 GitLab CI: fix syntax error 2022-08-17 15:29:18 +02:00
ManoloFLTK
cc87fd8def Simplify Fl_Wayland_Gl_Window_Driver::make_current_before() member function. 2022-08-17 15:24:05 +02:00
Albrecht Schlosser
5167aad15c GitLab CI: limit lifetime of artifacts to 8 days
... to save storage space.
2022-08-17 15:16:17 +02:00
ManoloFLTK
1f53b9e203 Wayland platform: improve Fl_Gl_Window resize operations. 2022-08-17 09:26:40 +02:00
ManoloFLTK
d23963af60 Remove useless Fl_Wayland_Window_Driver::show_with_args_begin/end(). 2022-08-15 19:23:57 +02:00
ManoloFLTK
82fa5ea19c Fix Fl_Wayland_Window_Driver::decoration_sizes(). 2022-08-15 18:40:11 +02:00
ManoloFLTK
d325fa504e Replace call to CreateFont() by call to CreateFontW(). 2022-08-13 12:25:04 +02:00
ManoloFLTK
d1d3cc9afa Add virtual Fl_Cairo_Graphics_Driver::cache_size() member function. 2022-08-12 19:47:04 +02:00
Albrecht Schlosser
ab61c03433 Improve automatic documentation generation
This removes the need to edit the copyright year before generating
  the documentation (every year, in several files) and adds some
  technical information (doxygen generation date, doxygen version,
  and FLTK Git revision) in both HTML and PDF docs.

- auto-generate copyright year (current year) used in several places
- include FLTK Git revision in HTML and PDF docs
- include generation date and doxygen version
- replace special html footer which didn't work well with default footer
2022-08-12 17:49:53 +02:00
ManoloFLTK
b8c227a8f2 Fix Fl_Xlib_Graphics_Driver for drawing tiled images.
Conflicting demands arise in the implementation of class Fl_Xlib_Graphics_Driver
for drawing images with the XRender library :

1) Issue #163 leads to use a bilinear filter to draw-and-scale images.
2) This tends to blur the edges of drawn areas which is bad for tiled images
(that is because the edges get alpha values, even for an opaque source image).

This commit resolves the conflict adding a means to detect whether the library
is busy drawing a tiled image. If so, the bilinear filter is not applied, drawn areas
don't  have blurred edges, resulting in a nice tiling.

With this commit, these test apps perform correctly:
- tiled_image is correct at all scaling factor values also when modified
to use a depth-3 or a depth-4 Fl_RGB_Image as tile;
- unittests - Drawing Images is correct at all scaling factor values;
- pixmap_browser scales correctly up and down JPEG and PNG images.
2022-08-10 10:53:29 +02:00
Albrecht Schlosser
7d7784d140 GitLab CI/CD: generate pdf documentation
Remove build artifacts from normal builds (libs and executables).
  These were never meant to be provided but forgotten to remove
  after tests.

Try to build fltk.pdf (may be removed later)

Store fltk.pdf in 'public' folder to be available online in docs
  and downloadable as "artifact"
2022-08-09 21:41:31 +02:00
ManoloFLTK
92f6962b59 Fix Fl_Xlib_Graphics_Driver for tiled-depth 3 images.
Modifying test/tiled_image to make it use a depth-3 image for
tiling (rather than an Fl_Pixmap) shows the filter does require
to use PictOpOver as the render op in the XRenderComposite call.
2022-08-09 17:43:48 +02:00
ManoloFLTK
1562396ec0 Fix Fl_Xlib_Graphics_Driver for RGB image drawing under XQuartz. 2022-08-09 16:05:53 +02:00
Albrecht Schlosser
64548e2f3a Improve layout, fix resizing of test/demo
Add an invisible box as resizable() to 'demogrp' to avoid bad resizing
behavior while the debug terminal is enabled. The old version would
disable some buttons including the 'exit' button if the window was
resized to a smaller size.

Simplify the popup menu (remove strcmp()).
2022-08-08 17:35:56 +02:00
Albrecht Schlosser
d20de5bc0a Fix src/Makefile: add missing directory to 'clean' target 2022-08-08 11:33:45 +02:00
Albrecht Schlosser
a5b9cc888b Add option to test Fl_Flex in test/pack.cxx
This new feature demonstrates that Fl_Flex can be used (almost) as
a drop-in replacement of Fl_Pack.

Add missing file to examples/.gitignore.
2022-08-08 11:07:40 +02:00
Albrecht Schlosser
e6c2503453 Add Fl_Flex demo "howto-flex-simple" to examples
This demo program uses an Fl_Flex widget with one row of buttons.
2022-08-07 18:01:59 +02:00
Albrecht Schlosser
713d276b1c Fl_Flex: support different margin sizes, improve docs
Support different margin sizes on all four edges. Default margin
  and gap size is now 0 (compatible with Fl_Pack).

Doxygen: move the description from the constructor to the class
  declaration which constitutes a "description".

Make some methods virtual and/or 'const'.

Clarify demo programs, make them even more "FLTK style".
2022-08-07 16:00:41 +02:00
ManoloFLTK
f5b14397dd Wayland platform: fix declaration of local variable 'scale'. 2022-08-07 10:49:11 +02:00
ManoloFLTK
5dfc64ef32 Wayland platform: move repeated code into Fl_Wayland_Graphics_Driver::buffer_commit(). 2022-08-07 10:43:38 +02:00
ManoloFLTK
b25549ffa7 Wayland: make sure wl_surface_frame() is followed by wl_surface_commit(). 2022-08-06 17:30:44 +02:00
ManoloFLTK
149673863d Wayland: fix regression from 50d26b0 in test/mandelbrot. 2022-08-06 16:50:58 +02:00
ManoloFLTK
33ea30432f Check for error while communicating with Wayland - cont'd. 2022-08-06 10:27:17 +02:00
ManoloFLTK
e73e13120e Check for error while communicating with Wayland. 2022-08-06 10:07:38 +02:00
Albrecht Schlosser
128aa08be8 Improve docs about FLTK coordinate systems
Enlarge the screenshot of test/coordinates for better readability in
html and pdf docs.
2022-08-03 16:39:44 +02:00