The Graphics class
The Graphics
class is a wrapper class for a device context. It also provides functionality for drawing lines, rectangles, and ellipses; writing text; saving and restoring graphic states; setting the origin of the device context; and clipping the painting area. The constructor is private since Graphics
objects are intended to be created internally by Small Windows only.
Graphics.h
namespace SmallWindows {
When drawing a line, it can be solid, dashed, dotted, dashed and dotted, as well as dashed and double-dotted:
class Window; enum PenStyle {Solid = PS_SOLID, Dash = PS_DASH, Dot = PS_DOT, DashDot = PS_DASHDOT, DashDotDot =PS_DASHDOTDOT}; class Graphics { private: Graphics(Window* windowPtr, HDC deviceContextHandle);
The Save ...
Get C++ Windows Programming now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.