diff options
| author | Manolo Gouy <Manolo> | 2011-09-29 16:04:24 +0000 |
|---|---|---|
| committer | Manolo Gouy <Manolo> | 2011-09-29 16:04:24 +0000 |
| commit | d9cda5c3aa48da9ef3238d993b34cde7047175d8 (patch) | |
| tree | 751d1c5daa9c837444e53a2ed955dcfb2c6c302f /examples | |
| parent | bc1b17056a44af5890cb2b5ec56cf9fbb72ccea4 (diff) | |
Fix STR#2695 & 2697: correct computation of work areas with multiple screens.
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
Diffstat (limited to 'examples')
0 files changed, 0 insertions, 0 deletions
