summaryrefslogtreecommitdiff
path: root/src/screen_xywh.cxx
AgeCommit message (Collapse)Author
2025-03-11Fix "Wayland: Huge menu hiding unexpectedly when moving a mouse (#1115)ManoloFLTK
This commit also computes work-area size for single-display settings.
2024-12-31Document in detail how screen work areas are computed across platforms (#1180)ManoloFLTK
2024-11-17Finish release 1.4.0Albrecht Schlosser
1) Improve and clarify documentation: - update, reformat, and reorder parts of CREDITS.txt - make sure that documentation appears in doxygen docs - add '\since 1.4.0' to documentation of new methods and functions - remove doxygen's '\brief' where not required (we're using JAVADOC_AUTOBRIEF = YES) - clarify screen scaling, scaling factor, and related stuff - add more info about backwards compatibility for X11 specific code 2) Update dependencies
2023-07-15Documentation: add detail about primary monitorManoloFLTK
2023-07-10More detailed documentation of Fl::screen_xywh()ManoloFLTK
2023-07-07Improve documentation of Fl::screen_num(int x, int y)ManoloFLTK
2022-11-28Doc: repeat that screens are numbered starting from 0 in the APIManoloFLTK
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.
2018-06-26Move Fl_Screen_Driver.H from FL/ to src/Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12975 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-09Replace "WIN32" with "_WIN32" or "Windows".Albrecht Schlosser
Replace compiler/preprocessor/platform macro "WIN32" with "_WIN32". Replace "WIN32" in text and documentation with "Windows". Replace "MSWindows" with "Windows". To do: README.Windows.txt (and maybe other documentation as well) needs updates. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12655 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-01-31Replace FL/x.H with FL/platform.H - step 2 (STR #3435).Albrecht Schlosser
This second step replaces FL/x.H with FL/platform.H in all source files. Dependencies have been adjusted as well. This commit completes the replacement of FL/x.H with FL/platform.H. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12641 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-06-17Make Fl_Screen_Driver::get_mouse(int&, int&) return the number of the ↵Manolo Gouy
mouse-containing screen. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12264 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-26Use the FL_DOXYGEN preprocessor variable to remove all Doxygen warningsManolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11232 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-10Fixed Screen Drivers for MSWindowsMatthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11150 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-10Fix Screen Driver implementation for X11Matthias Melcher
- moved stuff around to fit X11 file layout - fixed a few Cocoa variables git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11149 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-10Basic Screen Driver Structure. LIMBO!Matthias Melcher
Creating the basic structure for a screen driver system. OS X works X11 and WinAPI are in limbo and will be fixed in the next hour or so. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11148 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
2016-01-03Updated platform specific #if's to report unimplemented code when compiling ↵Matthias Melcher
with FL_PORTING defined and WIN32 and __APPLE__ undefined> git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@10989 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-06-10Mac OS: remove 5 compilation warnings of this kind:Manolo Gouy
warning: comparison of function 'CGDataConsumerCreateWithCFData' not equal to a null pointer is always true note: prefix with the address-of operator to silence this warning git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10747 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2015-04-14Fix compilation warnings: "... may be used uninitialized".Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10703 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2014-08-21Fix two typos in comments (test commit)Lauri Kasanen
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@10228 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2013-09-22Fixed some odd/misleading code indent issues in this file.Greg Ercolano
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9983 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2013-09-22STR #2860: Mods for full screen support.Greg Ercolano
Applied the fltk-1.3.x-screen_num.patch git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9982 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2012-03-23Fix STR#2641: true fullscreen windows that cover all their screen including ↵Manolo Gouy
menu bar, task bar, dock. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9299 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-09-30About STR#2600 : some code factorization.Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9101 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-09-29Fix STR#2695 & 2697: correct computation of work areas with multiple screens.Manolo Gouy
This introduces 3 new functions static void Fl::screen_work_area(X,Y,W,H) static void Fl::screen_work_area(X,Y,W,H,mx,my) static void Fl::screen_work_area(X,Y,W,H,screen_no) that compute screen work areas and are used by FLTK to position menu windows. The Fl::x(),y(),w(),h() functions are made consistent across platforms: they return the origin/size of the work area of the main screen (as far as possible, see below). On the Mac OS platform, all screen functions reflect changes in screen number and positions without requiring the application to restart. On the X11 platform, I did not find an API to compute the main screen work area in all conditions. What's used does compute the correct work area when there's a single screen, but not when there are several, because it returns an area that encompasses all screens. The implemented workaround is that Fl::x(),y(),w(),h() and Fl::screen_work_area(X,Y,W,H,0) return the exact work area when there's a single screen, and return the full screen area when there are several. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@9084 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-08-18Initial fixes for window position at or beyond (0,0) under win32.Ian MacArthur
This is not the whole story, but is better. We were messing up the initialisation of num_screens on Win32 in that it was being set to a non-zero value by a call to GetSystemMetrics(SM_CMONITORS) but was then subsequently incremented even higher by each iteration call to the screen_cb(...) function, so what we were storing for the screen rectangles was a bit messed up. Under fltk-1.1, the code used to explicitly reset num_screens to zero before starting to iterate the screen_cb(...) function, so that worked OK. I have sort-of restored that behaviour, and removed the (now redundant) call to GetSystemMetrics(SM_CMONITORS) since we *always* enumerate the monitors now to get the per-screen DPI values out. I've also put in a commented out stub where we could store the per-screen work-area, which it seems we do also need now, though I have not yet contrived to actually implement that. Volunteers welcomed... git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8981 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
2011-06-06Fix potential NULL pointer dereference, if !XineramaIsActive(...).Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8783 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-06-03STR 2655: applied commited patch. Looks good to me.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8778 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-05-26#2646: improved queries for screen sizes.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8738 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-05-24Fix STR #2643: derefenced NULL pointer, if Xinerama is available, but inactive.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8733 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-05-23src/screen_xywh.cxx: Fix STR #2637, part 1.Albrecht Schlosser
Fix array bounds error when Xinerama and Xlib disagree about number of screens. Fix setting vertical resolution (dpi) of different monitors. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8727 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-05-23Fix STR #2640: Fl::w() and Fl::h() are documented to return the width and ↵Manolo Gouy
height of the main screen's work area (system-occupied space excluded); Fl::screen_xywh() functions instead compute the full width and height of a screen. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8724 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-04-22Mac OS: exact implementation of the Fl::screen_dpi() function.Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8619 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-03-12Fix STR #2575: use the screen that intersects most of the window when made ↵Manolo Gouy
fullscreen. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8515 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07src/screen_xywh.cxx:Albrecht Schlosser
Fix X11 screen_init() if Xinerama is available, but not active. Still investigating why there are nonsense dpi values under Cygwin/X11, but maybe this is an X server problem. test/hello.cxx: Extended test statements - don't forget to remove before release. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8210 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07fix build with xineramayuri
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8209 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07DPI fixed for X11Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8207 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07DPI fixed for Xinerama?Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8206 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07DPI fixes for MSWindows GDIMatthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8205 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2011-01-07First attempt at finding the screen pixel sizes. Can't test Xinerame, ↵Matthias Melcher
MSWindows, or X11 yet. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8204 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2010-12-18Mac OS: replaced several global functions by new member functions of Mac ↵Manolo Gouy
OS-specific Fl_X class. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@8055 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-29OS X: removed all Carbon and Quickdraw references. Starting with 1.3, we ↵Matthias Melcher
only support Cocoa and Quartz. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@7351 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2009-12-06Moved OS X code base to the more moder Cocoa toolkit thanks to the awesome ↵Matthias Melcher
work of Manolo Gouy (STR #2221). This is a big one! I tested all test applications under 32-bit autoconf and Xcode, and a few apps under 64bit intel. No PPC testing was done. Please verify this patch if you have the machine! git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6951 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-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-10-04Corrected comment inversion in fl screen_xywh() api.Fabien Costantini
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6373 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2008-10-04Completed and corrected Fl and related Fl_Window documentation, added cross ↵Fabien Costantini
references, especially to back compatibility functions to the new ones. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3@6372 ea41ed52-d2ee-0310-a9c1-e6b18d33e121