summaryrefslogtreecommitdiff
path: root/src/Fl_Widget.cxx
AgeCommit message (Collapse)Author
43 hourswipmaxim nikonov
44 hourswipmaxim nikonov
3 dayswipmaxim nikonov
2025-10-29Add information on Fl_Widget::type_.Matthias Melcher
2025-07-02Remove deprecated methods and functionsAlbrecht Schlosser
In FLTK 1.5 we remove most (but not all) methods and functions that were deprecated in FLTK 1.3 or earlier.
2024-08-27Adding horiizonatl and vertical label marginMatthias Melcher
- sizeof(Fl_Widget) not increased - label positions can be adjusted - try it out in test/label app - full support in FLUD
2024-08-14Adding Fl_Widget::label_image_spacing() (#1039)Matthias Melcher
- May need a better method name. - This makes the gap between the image in a label and the label text user settable. - Can be tested using test/label app
2024-04-26Box types can now defined and draw their own focus frame, STR 2145, #659Matthias Melcher
2023-08-15Improved, yet compatible, widget callback system using macros (#729)Matthias Melcher
* adds FL/fl_callback.macros.H * adds FL_FUNCTION_CALLBACK_n(widget, function, [type, data]) * adds FL_METHOD_CALLBACK_n(widget, class, instance, method, [type, data]) * adds FL_INLINE_CALLBACK_n(widget, [type, name, data], callback_body) * adds `examples/callback` * full documentation
2023-01-08Fix missing parameter documentationMatthias 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
2022-12-10Add option to bind images to a widget (#589)Matthias Melcher
Adding image binding to FLUID as well
2022-11-05Wayland/X11 hybrid: use "bool fl_disable_wayland;" declaration.ManoloFLTK
2022-01-16Rename FL/fl_string.h to FL/fl_string_functions.hAlbrecht Schlosser
This is part 1 of the final fix for a previous name clash on case insensitive file systems (fl_string.h vs. Fl_String.H).
2022-01-14Improve focus box drawing and documentationAlbrecht Schlosser
Add new method Fl_Widget::draw_focus(Fl_Boxtype t, int x, int y, int w, int h, Fl_Color bg) ... with background color for correct contrast testing (in Fl_Tabs) Draw the focus box of the "tabs" of Fl_Tabs widgets with the correct boxtype and background color. Make 'unsigned int visible_focus()' const so it can be used in 'const' methods. Do not draw the focus box if the per-widget focus box option is off.
2020-08-01Implement + deploy fl_strdup()Greg Ercolano
2020-07-06Remove $Id$ tags, update URL's, and moreAlbrecht Schlosser
- remove obsolete svn '$Id$' tags from all source files - update .fl files and generated files accordingly - replace 'http://www.fltk.org' URL's with 'https://...' - replace bug report URL 'str.php' with 'bugs.php' - remove trailing whitespace - fix other whitespace errors flagged by Git - add and/or fix missing or wrong standard headers - convert tabs to spaces in all source files The only relevant code changes are in the fluid/ folder where some .fl files and other source files were used to generate the '$Id' headers and footers.
2017-07-20Improve docs of Fl_Widget::callback() and do_callback().Albrecht Schlosser
Clarify that all variants of do_callback() call clear_changed() after the callback and that 'long Fl_Widget::argument()' may truncate the user_data value on some (particularly Windows 64-bit) platforms. Some code has been reformatted and refactored with better variable names, but there are no effective code changes. Obsolete, inactive code was removed. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12345 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-07-15Allow widget callback to be NULL (STR #2835).Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11812 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-01Add fl_focus_rect function to driver.Matthias Melcher
Focus rectangles are dotted lines. The default implementation uses the dotted line style, However, for systems without line stye, we draw many dots instead. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11110 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-01-04Created pseudo code for all FL_PORTED section so that FLTK compiles and ↵Matthias Melcher
links (Xcode, hello, other C flags: -D FL_PORTING -U __APPLE__ -U __APPLE_QUARTZ__) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@10993 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-12-16Running FLTK in static initializers (cont'd):Manolo Gouy
To make sure that fl_graphics_driver is initialized, it is enough to test whether it is null. This saves the memory cost of a static variable. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10971 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-12-13Allowing to use FLTK objects in static initializers (cont'd).Manolo Gouy
Mac OS: a more convenient position where to initialize the fl_fonts global variable. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10964 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-12-13Allowing to use FLTK objects in static initializers (cont'd).Manolo Gouy
On the Mac platform, it's also necessary to initialize the fl_fonts global variable. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10960 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-12-13Restore the possibility to construct FLTK objects and draw them within ↵Manolo Gouy
static initializers (which run before main() begins in an uncontrolled order). This was failing because calls to drawing functions (e.g., fl_font(f,s);) crashed due to uninitialized fl_graphics_driver global variable. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10959 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-04-05Documentation updates on callbacks and Fl::readqueue().Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10677 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2012-05-07Remove redundant redraw_label() call from copy_label(), STR #2836.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9452 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2012-05-05Fix STR #2836: copy_label() with old label() value failed.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9443 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-07-19Modifications to all LGPL headers for STR #2685.Greg Ercolano
(to clarify static exception LGPL by changing license references) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8864 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-12-02STR#2466: Added copy_tooltip().Greg Ercolano
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7940 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-11-28Fixed Copyright to 2010.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7903 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-03-23Minor fix to do_callback() code.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7321 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-01-16Extended Fl_Widget::align_ flag from 8 bits to full (unsigned) size forAlbrecht Schlosser
later extensions (currently all 8 bits are used). Moved the align_ flag to the internal Fl_Label struct (where it should be). There are no API changes, though. I also reordered a few other variables for better alignment, so that there is no size change of Fl_Widget on 32-bit platforms (currently 84 bytes on Windows/32-bit and probably all 32-bit platforms). git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7013 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-12-23Widgets now remove stale entries from the default callback queue Albrecht Schlosser
(see Fl::readqueue()) when they are deleted (STR #2302) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6977 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-03-24Major documentation update including: now html doc API is sorted, navigation ↵Fabien Costantini
problems/side effects fixed, html tags replaced by proper doxygen commands, parameters command switched from a to p. Includes a pdf update. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6716 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-03-21converted html tags to doxygen commands in documentation/src/subclassing.doxengelsman
this also required tweaking parameter names and doxygen comments in Fl_Widget.H, Fl_Group.H, Fl_Widget.cxx and fl_boxtype.cxx git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6705 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-02-15renamed class Fl_Watch to Fl_Widget_Tracker, as discussed in fltk.development.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6659 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-02-08Added the helper class Fl_Watch to simplify safe handling of widget deletionAlbrecht Schlosser
in callbacks. This is used e.g. in Fl_Widget::do_callback() to prevent accessing widgets after deletion in the callback. Documentation adjusted, Fl_Menu_Button.cxx changed to use Fl_Watch instead of Fl::watch_widget_pointer. Fl::watch_widget_pointer() and Fl::release_widget_pointer() have been modified to use an array without "holes" (NULL pointers) for storing the widget pointers for faster access: Fl::release_widget_pointer() now shifts pointers to close gaps of freed pointers. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6651 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-01-08Widgets now remove themselves from their parent group (if any), when destroyedAlbrecht Schlosser
(STR #1894). Fl_Group::clear() removes widget by widget (one at a time) to allow widgets to remove other related widgets from the same group, when they are deleted. Also fixed a bug in Fl_Value_Input (added a destructor), because it used a non-Fl_Group widget as parent of another widget. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6623 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-01-01Changed Copyright in 'src' directoryMatthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6616 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-12-13Fixed typos and doxygen documentation.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6582 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-10-13Quickdraw removal: option removed from configure, all Qd code removed from ↵Fabien Costantini
sources. Also took this opportunity to sort the ifdef clauses so that USE_X11 shows first. Also added error pragma to enforce proper target checking, thus make even less assumptions. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6423 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-20Fixed some typos and links and added a section about document structureAlbrecht Schlosser
and some more to development.dox. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6320 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-18Doxygen documentation: Fixed most important warnings for the Fl_Widget, ↵Fabien Costantini
Fl_Window, Fl_Valuator classes that should be now a 100% documented. For the rest I drastically reduced the undocumented APIs, but many others (less important) remains. It looks and feels pretty good now :-) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6299 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-16Doxygen documentation : took the opportunity to update copyright info as we ↵Fabien Costantini
modified already in batch almost all sources, added also a fil doxygen command to class headers to harmonize with original matt Fl_Widget dox. format. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6265 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-15Doxygen documentation. Fixed somes typos and also H4 remanent misplaced ↵Fabien Costantini
tags and comments. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6258 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-13WP1 merged from my branch, WP2 reserved, todo list updated.Fabien Costantini
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6231 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-09-10Merging the UTF8 patch, consisting of O'ksi'd s original 1.1.6 patch and ↵Matthias Melcher
additions by Ian. PLEASE BE AWARE that the patch in its current incarnation is a regression in many aspects and further work is required before we can announce Unicode support. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6212 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-08-15Rename type Fl_Font_Size into Fl_Fontsize to comply with other naming in FLTK.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6161 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-08-11Moving more documentation into doxygen formatMatthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6155 ea41ed52-d2ee-0310-a9c1-e6b18d33e121