Chapter 1:Introduction
How the Win32 Library Is Structured
How the Win32 Library Is Designed
Chapter 2:Whats In This Volume?
Chapter 3:Using Microsoft Reference Resources
The Microsoft Developer Network (MSDN)
Comparing MSDN and MSDN Online
MSDN Subscriptions
MSDN Library Subscription
MSDN Professional Subscription
MSDN Universal Subscription
PUrchasing an MSDN Subscription
Using MSDN
Navigating MSDN
Quick Tips
Using MSDN Online
Navigating MSDN Online
MSDN Online Features
MSDN Online Registered Users
The Windows Programming Reference Series
Chapter 4:Finding the Developer Resources You Need
Developer Support
Online Resources
Learning Products
Conferences
Other Resources
Chapter 5:Getting the Most Out Of Win32 Technologies:Part 3
RPC Errors
Using pointer_default(unique)and embedded Pointers
A valid switch_is value in an RPC-capable structure
doesn’t ensure a non-NULL Pointer
A NULL DACL affords no protection
Call RpcImpersonateClient()before any security-relevant operation
Starting and stopping impersonation
Always check the result of RpcImpersonateClient()
before a security-relevant operation
Call RpcRevertToSelf()after security-relevant operations
Strings are zero-teminated only when declared with strings in the .idl
Dont copy arbitrary length data into independently-sized buffers
Using size_is may result in a zero-length structure;
it is not safe to dereference this without first checking its length
Calculations in a size_is or length_is specification are
susceptible to overflow
Strict context handles
Kernel-Mode Specifiers
Don’t access user-provided memory without probing
Don’t do multiple user-mode reads without captures
Don’t trust the TEB
Avoid race conditions when modifying kernel data on user request
Dealing with common interfaces for user mode and kernel mode
Validating buffered I/O in device drivers
METHOD_NEITHER requires full probe and capture
Solution Summary
Chapter 6:Bitmaps
About Bitmaps
Bitmap Classifications
Device-Independent Bitmaps
Device-Dependent Bitmaps
Bitmap Header Types
JPEG and PNG Extensions for Specific Bitmap Functions and Structures
Bitmaps Device Contexts,and Drawing Surfaces
Bitmap Creation
Bitmap Rotation
Bitmap Scaling
Bitmaps as Brushes
Bitmap Storage
Bitmap Compression
Alpha Blending
Alpha Values per Pixel
Global Alpha Blending Settings
Smooth Shading
ICM-Enabled Bitmap Functions
Bitmap Reference
Bitmap Functions
Bitmap Structures
Bitmap Macros
Chapter 7:Brushes
About Brushes
Logical Brush Types
Solid Brush
Stock Brush
Hatch Brush
Pattern Block Transfer
ICM-Enabled Brush Functions
Brush Refeerence
Brush Functions
Brush Structures
Chapter 8:Clipping
About Clipping
Clipping Regions
Clip Paths
Clipping Reference
Clipping Functions
Chapter 9:Colors
About Colors
Color Basics
Color Values
Color Approximations and Dithering
Color in Bitmaps
Color Mixing
Color Palettes
Default Palette
Logical Palette
Palette Animation
System Palette
System Palette and Static Colors
Palette Messages
Halftone Palette and Color Adjustment
Color Reference
Color Functions
Color Structures
Color Macros
Color Messages
Chapter 10:Coordinate Spaces and Transformations
About Coordinate Spaces and Transformations
Transformation of Coordinate Spaces
World-Space to Page-Space Transformations
Translation
Scaling
Rotation
Shear
Reflection
Combined World-to-Page Space Transformations
Page-Space to Device-Space Transformations
Mapping Modes and Translations
Predefined Mapping Modes
Application-Defined Mapping Modes
Device-Space to Physical-Device Transformation
Default Transformations
Coordinate Space and Transformation Reference
Coordinate Space and Transformation Functions
Coordinate Space and Transformations Structures
Chapter 11:Device Contexts
About Device Contexts
Graphic Objects
Graphic Modes
Device Context Types
Display Device Contexts
Printer Device Contexts
Memory Device Contexts
Information Device Contexts
Device Context Operations
Operations on Graphic Objects
Cancellation of Drawing Operations
Retrieving Device Data
Saving,Restoring,and Resetting a Device Context
ICM-Enabled Device Context Functions
Device Context Reference
Device Context Functions
Device Context Structures
Device Context Messages
Chapter 12:Filled Shapes
About Filled Shapes
About Ellipses
About Chords
About Pies
About Polygons
Drawing Rectangles
Filled Shape Reference
Filled Shape Functions
Chapter 13:Lines and Curves
About Lines and Curves
Lines
Curves
Combined Lines and Curves
Line and Curve Attributes
Line and Curve Reference
Line and Curve Functions
Chapter 14:Metafiles
About Metafiles
Enhanced-Format Metafiles
Enhanced Metafile Records
Enhanced Metafile Creation
Enhanced Metafie Operations
Windows-Format Metafiles
Metafile Reference
Metafile Functions
Metafile Structures
Enhanced Metafile Structures
Chapter 15:Pianting and Drawing
About Painting and Drawing
When to Draw in a Window
The WM_PAINT Message
The Update Region
Invalidating and Validating the Update Region
Retrieving the Update Region
Excluding the Update Region
Synchronous and Asynchronous Drawing
Drawing Without the WM_PAINT Message
Window Coordinate System
Window Regions
Window Background
Minimized Windows
Resized Windows
Nonclient Area
Child Windows
About Display Device Contexts
Display Device Context Cache
Display Device Context Defaults
Common Display Device Contexts
Private Display Device Contexts
Class Display Device Contexts
Window Display Device Contexts
Parent Display Device Contexts
Window Update Lock
Accumulated Bounding Rectangle
Painting and Drawing Reference
Painting and Drawing Functions
Painting and Drawing Structures
Painting and Drawing Messages
Raster-Operation Codes
Binary Raster Operations
Ternary Raster Operations
Chapter 16:Paths
About Paths
Outlined and Filled Paths
Transformations of Paths
Clip Paths and Graphic Effects
Conversion of Paths to Regions
Curved Paths
Path Reference
Path Functions
Chapter 17:Pens
About Pens
Cosmetic Pens
Geometric Pens
Pen Attributes
Pen Width
Pen Style
Pen Color
Pen Pattern
Pen Hatch
Pen End Cap
Pen Join
ICM-Enabled Pen Functions
Pen Reference
Pen Functions
Pen Structures
Chapter 18:Rectangles
About Rectangles
Rectangle Coordinates
Rectangle Operations
Rectangle Reference
Rectangle Functions
Rectangle Structures
Rectangle Macros
Chapter 19:Regions
About Regions
Region Creation and Selection
Region Operations
Combining Regions
Comparing Regions
Filling Regions
Painting Regions
Inverting Regions
Framing Regions
Retrieving a Bounding Rectangle
Moving Regions
Hit Testing Regions
Region Reference
Region Functions
Region Structures
Appendix A
Appendix B