Skip to content

Commit

Permalink
Document in detail how screen work areas are computed across platforms (
Browse files Browse the repository at this point in the history
  • Loading branch information
ManoloFLTK committed Dec 31, 2024
1 parent 4ce09ae commit 70729e6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/screen_xywh.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ void Fl::screen_xywh(int &X, int &Y, int &W, int &H, int mx, int my)
that contains the specified screen position \p mx, \p my
\param[out] X,Y,W,H the work area bounding box
\param[in] mx, my the absolute screen position
\see void screen_work_area(int &x, int &y, int &w, int &h, int n)
*/
void Fl::screen_work_area(int &X, int &Y, int &W, int &H, int mx, int my)
{
Expand All @@ -94,6 +95,9 @@ void Fl::screen_work_area(int &X, int &Y, int &W, int &H, int mx, int my)
\param[out] X,Y,W,H the work area bounding box
\param[in] n the screen number (0 to Fl::screen_count() - 1)
\see void screen_xywh(int &x, int &y, int &w, int &h, int mx, int my)
\note Under X11, the screen work area is given values that differ from that screen's bounding box
only if the system contains a single screen. Under Wayland, a screen work area is always
equal to that screen's bounding box.
\note Like all quantities accessible via public APIs of FLTK, values of \p X,Y,W,H
are given in FLTK units, that is, in drawing units divided by the scaling factor of screen \p n.
*/
Expand Down Expand Up @@ -192,7 +196,7 @@ void Fl::screen_xywh(int &X, int &Y, int &W, int &H)
/**
Gets the bounding box of the work area of the screen that contains the mouse pointer.
\param[out] X,Y,W,H the work area bounding box
\see void screen_work_area(int &x, int &y, int &w, int &h, int mx, int my)
\see void screen_work_area(int &x, int &y, int &w, int &h, int n)
*/
void Fl::screen_work_area(int &X, int &Y, int &W, int &H)
{
Expand Down

0 comments on commit 70729e6

Please sign in to comment.