summaryrefslogtreecommitdiff
path: root/FL
AgeCommit message (Collapse)Author
2023-01-13Fix for "Rename Fl_X* Fl_Window::i private class member" (#223)ManoloFLTK
2023-01-12Add Fl_Scheme_Choice widget and use it in test programsAlbrecht Schlosser
This widget offers the selection of all known FLTK schemes as a simple widget based on Fl_Choice. Some test and demo programs use Fl_Scheme_Choice to enable the developer or user to switch schemes quickly for comparison. Todo: - add features to add new schemes during runtime (partially done) - update status when the scheme is changed by Fl::scheme("...")
2023-01-12Add the initial version of class Fl_SchemeAlbrecht Schlosser
This basic version of class Fl_Scheme contains only static methods that are needed for Fl_Scheme_Choice and further extensions.
2023-01-11Fix "Compilation warning: 'NSOpenGLContext' on macOS 11" !#646)ManoloFLTK
2023-01-08Add new Fl_Rect::inset(lt,top,rt,bot) methodGreg Ercolano
2023-01-08 Fix "Xrender blurs adjacent images with bilinear scaling" (#633)ManoloFLTK
Many thanks to @wcout for providing this fix. Xrender now draws images in the same way when tiling images or not when FL_RGB_SCALING_BILINEAR is on. This allows to remove static bool Fl_Tiled_Image::drawing_tiled_image() which becomes unused.
2023-01-08Fix missing parameter documentationMatthias Melcher
2023-01-06X11: Optionally copy selection buffer to clipboard (STR 3229)Albrecht Schlosser
The new method Fl::selection_to_clipboard(int) enables copying selection data to the clipboard on X11 if it is set to 1. This feature was requested by STR 3229 and the implementation was inspired by an `xterm` feature named "Select to Clipboard" which can be enabled by 'ctrl + middle mouse button + "Select to Clipboard"' in an xterm window.
2023-01-05Adding Fl::hide_all_windows()Matthias Melcher
2023-01-05Add close buttons for individual tabs in Fl_Tabs (#628)Matthias Melcher
Add close buttons for Fl_Tabs Introducing callback reasons FLUID shows all FL_WHEN_... options Adding Fl_Tabs overflow types Improved test/tabs to show new features
2023-01-05Refactor drawing small circles: add fl_draw_circle()Albrecht Schlosser
This method can be used to draw small circles as part of the GUI. It is independent of the current scheme. Very small circles are approximated by drawing several rectangles.
2023-01-03Clarify and improve Fl::scheme() related documentationAlbrecht Schlosser
2023-01-02Fix a doxygen warning and improve "file list" contentsAlbrecht Schlosser
FL/Fl_Group.H: add `\brief` keyword src/Fl_Group.cxx: fix warning: the '#' in '#include' must be escaped
2022-12-30Use `FL_OVERRIDE` for all overridden virtual methods (#611)Matthias Melcher
FL_OVERRIDE is defined as `override` for C++11 and higher FL_OVERRIDE is defined as `override` for VisualC 2015 and newer Don't interfere with Fl_Widget::override()
2022-12-28Improve and extend fl_contrast() (#370)Albrecht Schlosser
- Add internal fl_contrast_cielab() as the new default. - Keep old function as internal fl_contrast_legacy(). - Add fl_contrast_mode() to switch between fl_contrast() functions. - Add fl_contrast_level() to fine tune fl_contrast() per mode. - Add option to register and use a custom contrast function. - Add test/contrast.cxx test program. - Move all fl_contrast() related code to a new file src/fl_contrast.cxx. - Add fl_lightness() convenience function for perceived lightness. - Add fl_luminance() convenience function for physical luminance.
2022-12-22Fix compilation on old gcc (#606)Matthias Melcher
* Fixing char* use in FLUID * Fixing const cast
2022-12-20Clean up class Fl_String (part of issue #601)Albrecht Schlosser
- remove static variable 'string_count' - improve and document methods debug() and hexdump() This commit does not resolve issue 601 but removes some development leftovers. Methods debug() and hexdump() left for debugging as requested.
2022-12-19Update dependencies, remove trailing whitespaceAlbrecht Schlosser
2022-12-18Added ansi_show_unknown(bool) (default off)Greg Ercolano
It may be useful to some to have the terminal emit an error character to show unknown escape sequences. Off by default, unknown escape sequences are silently ignored. If enabled, '¿' is inserted instead.
2022-12-17ESC sequences can traverse append(), unicode support for backspaceGreg Ercolano
This is basically a rewrite of the ESC handler, keeping state in the class, so ESC sequences can continued between called to append() (such as when reading data from a pipe in blocks). New private class 'Fl_Escape_Seq' handles parsing and state info. It also has careful bounds checking during parsing. Backspace supports Unicode, and the unicode chars can straddle across append() operations as well. Private variables in Fl_Simple_Terminal renamed _xxx to xxx_ to improve CMP compliance.
2022-12-17Add cross-platform fl_close_fd(int fd) to close a file descriptorManoloFLTK
2022-12-17Adding length checks for in-memory image data (see #542) (#592)Matthias Melcher
SVG is now decompressed in memory Bitmap invalid array length handling to return an error RGB Image data reader to return error if image data is too short FLUID: Add size argument to bitmap and JPEG data
2022-12-16Added backspace handling to simple terminal ansi() modeGreg Ercolano
This addresses a comment from MoAlyousef in issue #577 on 12/15/2022 requesting backspace processing.
2022-12-16Derive Fl_Zenity_Native_File_Chooser_Driver from Fl_Kdialog_Native_…ManoloFLTK
Also add Fl::option(OPTION_FNFC_USES_ZENITY)
2022-12-15Rename some Fl_Flex methods for FLTK compliance (#594)Albrecht Schlosser
Change some method names to comply with FLTK style as discussed in fltk.coredev, thread "Fl_Flex method name question". * Rename Fl_Flex::margins(...) to Fl_Flex::margin(...) (use singular form for all margin related methods) * Remove Fl_Flex::setSize() and isSetSize() "backwards compatibility" methods * Rename Fl_Flex::set_size(...) to fixed(...) Note: the latter affects existing (pre-release) fluid (.fl) files: you may want to edit and replace "set_size_tuples" with "fixed_size_tuples"
2022-12-13Fix trailing whitespace and dependenciesAlbrecht Schlosser
2022-12-11Use correct syntax to befriend a classManoloFLTK
2022-12-10Add option to bind images to a widget (#589)Matthias Melcher
Adding image binding to FLUID as well
2022-12-10Docs: add widget screenshot for Fl_Hor_Nice_SliderGreg Ercolano
2022-12-10"Public members Fl::awake_ring_*_ should be private" (#559) - cont'dManoloFLTK
2022-12-09Make Fl_ICO_Image::idcount() constAlbrecht Schlosser
... and fix docs and alignment
2022-12-09Fix for "Public members Fl::awake_ring_*_ should be private" (#559)ManoloFLTK
2022-12-09Add new Wayland-specific fl_wl_compositor() functionManoloFLTK
2022-12-09New Fl_ICO_Image class to read Windows .ico icon filesManoloFLTK
Many thanks to @darealshinji for contributing all the code for this new FLTK image class (see branch Fl_ICO_Image of https://github.com/darealshinji/fltk).
2022-12-05Implement fl_complex_polygon() for OpenGL (#570)Matthias Melcher
2022-11-30Add a unit test for drawing complex shapes (#565)Matthias Melcher
2022-11-30Remove useless fl_matrix member variable of class Fl_Graphics_DriverManoloFLTK
2022-11-30Remove superfluous friend declarations from class Fl_Graphics_DriverManoloFLTK
2022-11-29Fix for issue [Cairo]: Arrows have a "gap" (#561)ManoloFLTK
The problem to fix is that the arrow drawn by draw_arrow1() in src/fl_symbols.cxx displays a faint clear line between the stem and head of the arrow with the Cairo graphics driver. This occurs because draw_arrow1() draws the arrow in 2 steps (a rectangle + a triangle) and the Cairo driver is configured to use antialiasing when filling polygons. The antialiasing produces the faint line between stem and head. Why does draw_arrow1() draw a rectangle + a triangle rather than a 7-vertex polygon? That's because the X11 graphics driver fails with its polygon- drawing function when the polygon is also rotated: the polygon is drawn empty. We want to keep using antialiasing under Cairo for polygons because the result is better with non horizontal/vertical polygon edges. This implementation changes function draw_arrow1() which draws the arrow as a 7-vertex filled polygon except when the graphics driver returns false for its virtual member function can_fill_non_convex_polygon(). In that situation, draw_arrow1() draws, as before, a rectangle + a triangle. The new, virtual member function can_fill_non_convex_polygon() returns true except for the X11 graphics driver. Therefore, draw_arrow1() is effectively unchanged under the X11 driver.
2022-11-27macOS+OpenGL3: remove "warning: gl.h and gl3.h are both included"ManoloFLTK
2022-11-26Local undo per Fl_Text_Buffer and Fl_Input_ (#557)Matthias Melcher
2022-11-26Make the value box size of Fl_Value_Slider user settable (STR 3222)Albrecht Schlosser
For a very simple test program see STR 3222, File 2: https://www.fltk.org/strfiles/3222/value_slider.cxx Known issues: - range checking of the value box size is very limited - resizing the widget does not change the value box size - drawing issues are possible if the value box size and the widget size are not compatible (e.g. value box too large)
2022-11-25Add "Oxy" scheme (STR 2675, STR 3477)Albrecht Schlosser
This commit is similar to the patch given in STR 3477, oxy_v5.diff: https://www.fltk.org/strfiles/3477/oxy_v5.diff ... with modifications, and updated to current FLTK code.
2022-11-24Refactor code to make rounded rectangles accessible (#553)Matthias Melcher
This adds fl_rounded_rect and fl_rounded_rectf so the user can draw rounded rectangles. This uses existing and optimised code that is rearranged.
2022-11-22Refactor and simplify "arrow drawing" in widgetsAlbrecht Schlosser
"Arrows" in widgets are those GUI elements mostly represented by triangles pointing in a particular direction as in scrollbars, choice widgets, some menus, valuators and Fl_Counter widgets. The code has been simplified and standardized such that all these GUI elements are drawn identically per FLTK scheme. Widget authors no longer need to write code to calculate arrow sizes and draw polygons etc. Different schemes can and do implement different drawing functions. Todo: see comments "FIXME_ARROW" in src/Fl_Menu_Button.cxx and src/Fl_Menu.cxx
2022-11-22Enhance Fl_Rect: add inset() and new constructorAlbrecht Schlosser
These new features can be used by widgets that draw inside a rectangle taking the border width into account.
2022-11-22Fix selection extension in Fl_Text_*, issue 196 (#550)Matthias Melcher
Selecting a text range programmatically would not sync some variables with the actual selection. This also fixes a crash bug in macOS when dragging text that was selected by buffer()->select() only.
2022-11-20Replace #if FLTK_USE_X11 by #ifdef FLTK_USE_X11ManoloFLTK
2022-11-17Fix rearranging children in Fl_Scroll (#546)Matthias Melcher
Implement Fl_Scroll::on_move() Fix indexing in Fl_Group::on_move()
2022-11-15Add support of .svgz image files to fluidManoloFLTK
The prototype of the public Fl_SVG_Image constructor is expanded to allow construction from in-memory, gzip'ed binary data.