mapping system

I've stumbled on the window and viewport problematic and I don't get it. My first thoughts were, I got a client area, where I set the viewport (size of the viewport and coordinates of the origin) and there I can draw and print out text. But when I'm digging deeper, there is a window-to-viewport transformation. But what kind of window is it? Is it an imaginary window? My application (a window) has its client area, where I set the imaginary window and viewport. But why do I need this window? This is only applied to the MM_ISOMETRIC and MM_ANISOMETRIC mapping modes, the rest is predefined.

Next I thought, that the I can draw only inside this window/viewport defined by its extents, but I've tryed to draw outside the dimensions and its working.

I know, that this system is because of transformation between logical units (mm, cm, m, inch etc.) and device units (pixels), but why when I'm using a screen, which is in pixels?

Can someone help me please to explain it simply but more in detail? :-)
Topic archived. No new replies allowed.