[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: x-display-pixel-width/height inconsistency
From: |
grischka |
Subject: |
Re: x-display-pixel-width/height inconsistency |
Date: |
Thu, 21 Mar 2013 01:58:38 +0100 |
User-agent: |
Thunderbird 2.0.0.23 (Windows/20090812) |
The DC has nothing to do with monitors because monitors are just
different coordinates on the same (virtual) screen. (Obviously
since you can drag the window between monitors, even such that
it's partially on two monitors at the same time.)
To get the the size of the monitor where your window is (mostly)
on you can use:
MONITORINFO mi;
HMONITOR hMon;
RECT s;
hmon = MonitorFromWindow(your_hwnd, MONITOR_DEFAULTTONEAREST);
mi.cbSize = sizeof(mi);
if (GetMonitorInfoA(hMon, &mi)) {
s = mi.rcMonitor; // entire screen, or
s = mi.rcWork; // without taskbar
}
--- gr
- Re: x-display-pixel-width/height inconsistency, (continued)
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/19
- Re: x-display-pixel-width/height inconsistency, Dmitry Gutov, 2013/03/19
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/19
- Re: x-display-pixel-width/height inconsistency, Dmitry Gutov, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, Dmitry Gutov, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, Dmitry Gutov, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/21
Re: x-display-pixel-width/height inconsistency,
grischka <=
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, grischka, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/20
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/21
- Re: x-display-pixel-width/height inconsistency, Eli Zaretskii, 2013/03/22
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/22
- Re: x-display-pixel-width/height inconsistency, Eli Zaretskii, 2013/03/23
- Re: x-display-pixel-width/height inconsistency, Jan Djärv, 2013/03/23
- Re: x-display-pixel-width/height inconsistency, YAMAMOTO Mitsuharu, 2013/03/23
- Re: x-display-pixel-width/height inconsistency, Eli Zaretskii, 2013/03/23