Click here to Skip to main content
15,919,245 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Clearing the edit box in ccombobox Pin
lctrncs29-Sep-06 10:48
lctrncs29-Sep-06 10:48 
GeneralRe: Clearing the edit box in ccombobox Pin
David Crow29-Sep-06 10:55
David Crow29-Sep-06 10:55 
Questiongraphing app help Pin
sys0p27-Sep-06 8:33
sys0p27-Sep-06 8:33 
AnswerRe: graphing app help Pin
Reagan Conservative27-Sep-06 8:46
Reagan Conservative27-Sep-06 8:46 
QuestionHDC coordinate space Pin
anthonym727-Sep-06 6:55
anthonym727-Sep-06 6:55 
AnswerRe: HDC coordinate space Pin
Chris Losinger27-Sep-06 7:15
professionalChris Losinger27-Sep-06 7:15 
GeneralRe: HDC coordinate space Pin
anthonym727-Sep-06 7:35
anthonym727-Sep-06 7:35 
GeneralRe: HDC coordinate space Pin
Shog927-Sep-06 20:17
sitebuilderShog927-Sep-06 20:17 
Screen coordinate space: relative to the screen.
Window coordinate space: relative to the window.
Client coordinate space: relative to the client area of a window (excluding title bar, border, menu, etc.)

For a given HDC, there will be two (potentially different) coordinate systems: device coordinates and logical coordinates.
For device coordinates, the origin, orientation, precision, etc. are determined by the device on which output is to be displayed: for the screen, these are usually relative to the window for which the device context was requested, with (0,0) at the top left, y increasing downwards, with pixel units (contrast with printers, which might have (0,0) at the bottom left, y increasing upwards, units being in something that makes sense for the type of printer). BeginPaint(), for instance, returns a device context for the client area of the window being painted.
Logical coordinates, controlled via SetMapMode(), can have a different origin, orientation, and unit size than those of the device that they eventually map to (MM_TEXT == 1-1 mapping to device units, MM_INCHES == 1" units, bottom left origin, y increases upwards, etc.)

The update region is merely an area within a given window marked as needing to be redrawn. BeginPaint() will set the clipping region to this area and erase it, but it does not determine how coordinates are mapped to the output device - it is useful only as an aid in determining what portion of the window needs to be redrawn (similarly, the clipping region is used to avoid redrawing portions of the screen - initially, it is set to the client area of the window (for client HDCs)).

See also:
Guide to Win32 Paint[^]


----
Scripts i’ve known...
CPhog 1.8.2 - make CP better.
Forum Bookmark 0.2.5 - bookmark forum posts on Pensieve
Print forum 0.1.2 - printer-friendly forums
Expand all 1.0 - Expand all messages
In-place Delete 1.0 - AJAX-style post delete
Syntax 0.1 - Syntax highlighting for code blocks in the forums

GeneralRe: HDC coordinate space Pin
anthonym728-Sep-06 6:13
anthonym728-Sep-06 6:13 
QuestionLinked lists Pin
EvScott27-Sep-06 6:12
EvScott27-Sep-06 6:12 
AnswerRe: Linked lists Pin
Zac Howland27-Sep-06 6:39
Zac Howland27-Sep-06 6:39 
GeneralRe: Linked lists Pin
Jörgen Sigvardsson27-Sep-06 13:46
Jörgen Sigvardsson27-Sep-06 13:46 
AnswerRe: Linked lists Pin
Christian Graus27-Sep-06 11:28
protectorChristian Graus27-Sep-06 11:28 
Questionhow to display a rectangle on the CHtmlView? Pin
blownfire27-Sep-06 5:13
blownfire27-Sep-06 5:13 
AnswerRe: how to display a rectangle on the CHtmlView? Pin
Maximilien27-Sep-06 6:48
Maximilien27-Sep-06 6:48 
QuestionError after call ReadDirectoryChangesW() Pin
Max++27-Sep-06 4:12
Max++27-Sep-06 4:12 
AnswerRe: Error after call ReadDirectoryChangesW() Pin
Chris Losinger27-Sep-06 4:52
professionalChris Losinger27-Sep-06 4:52 
AnswerRe: Error after call ReadDirectoryChangesW() Pin
toxcct27-Sep-06 5:09
toxcct27-Sep-06 5:09 
AnswerRe: Error after call ReadDirectoryChangesW() Pin
David Crow27-Sep-06 5:10
David Crow27-Sep-06 5:10 
AnswerRe: Error after call ReadDirectoryChangesW() Pin
Hamid_RT28-Sep-06 9:23
Hamid_RT28-Sep-06 9:23 
Questionproblem in recording sound on server Pin
itbuff27-Sep-06 3:57
itbuff27-Sep-06 3:57 
QuestionProblem using CList ? Pin
GudduRanchi27-Sep-06 3:34
GudduRanchi27-Sep-06 3:34 
QuestionHow i can prevent right click in windows explorer Pin
sudarshan12427-Sep-06 2:51
sudarshan12427-Sep-06 2:51 
AnswerRe: How i can prevent right click in windows explorer Pin
Chris Losinger27-Sep-06 4:25
professionalChris Losinger27-Sep-06 4:25 
AnswerRe: How i can prevent right click in windows explorer Pin
George L. Jackson27-Sep-06 5:27
George L. Jackson27-Sep-06 5:27 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.