Advanced MFC Programming
Table of Contents
CHAPTER 1. Tool Bar and Dialog Bar
1.1. Adding an Extra Docking Tool Bar
1.2. Imitating the Behavior of Radio Buttons
1.3. Check Box Implementation
1.4. Message Mapping for a Contiguous Range of Command IDs
1.5. Fixing the Size of Tool Bar
1.6. Adding Combo Box to Tool Bar
1.7. Modifying the Default Styles of Tool Bar
1.8. Dialog Bar
1.9. Resizable Dialog Bar
1.10. Adding Flyby and Tool Tip
1.11. Toggling Control Bars On/Off
2.1 Message WM_COMMAND and UPDATE_COMMAND_UI
2.2 Right Click Pop Up Menu
2.3 Updating Menu Dynamically
2.4 Bitmap Check
2.5 System Menu and Bitmap Menu Item
2.6 Owner-Draw Menu
2.7 Changing the Whole Menu Dynamically
3.1 Implementing Static Splitter Windows
3.2 Dynamic Splitter Window
3.3 Customizing the Behavior of Split Bar
3.4 Customizing the Default Appearance
3.5 Splitter Window That Cant be Resized by Tracking
4.1 Bitmap Button: Automatic Method4.2 Bitmap Check Box and Radio Button: Method 1
4.3 Subclass
4.4 Bitmap Check Box and Radio Button: Method 2
4.5 Irregular Shape Bitmap Button
4.6 Making Button Aware of Mouse Position
4.7 Mouse Sensitive Button
5.1 Spin Control
5.2 Customizing the Properties of Spin Control
5.3 Displaying Text Strings in the Buddy Window
5.4 Bitmap Button Buddy
5.5 Slider
5.6 List Box
5.7 Handling List Box Messages
5.8 Combo Box
5.9 Trapping RETURN key strokes for the Combo Box
5.10 Implementing Subclass for the Edit Box of a Combo Box
5.11 Owner Draw List Box and Combo Box
5.12 Tree Control
5.13 Handling Tree Control Messages
5.14 Drag-n-Drop
5.15 List Control
5.16 Tab Control
5.17 Animate Control and Progress Control
6.1 Modeless Dialog Box6.2 Property Sheet
6.3 Modeless Property Sheet
6.4 Sizes
6.5 Customizing Dialog Box Background
6.6 Resizing the Form View
6.7 Tool Tips
6.8 Tool Bar and Status Bar in Dialog Box
CHAPTER 7. Common Dialog Boxes
7.1 File Open and Save Dialog Box
7.2 More Customizations
7.3 Selecting Only Directory
7.4 Adding File Preview
7.5 Color Dialog Box
7.6 Custom Dialog Box Template
7.7 Font Dialog Box
7.8 Customizing Dialog Box Template
7.9 Modeless Common Dialog Boxes
CHAPTER 8. DC, Pen, Brush and Palette
8.0 Device Context & GDI Objects
8.1 Line
8.2 Rectangle and Ellipse
8.3 Curve
8.4 Other Shapes
8.5 Flood Fill
8.6 Pattern Brush
8.7 Color Approximation
8.8 Logical Palette
8.9 Monitoring System Palette
8.10 Palette Animation
8.11 Find Out Device Capability
9.1 Outputting Text Using Different Fonts
9.2 Enumerating Fonts in the System
9.3 Output Text Using CDC::ExtTextOut( )
9.4 One-Line Text Editor, Step 1: Displaying a Static String
9.5 One Line Text Editor, Step 2: Adding Caret
9.6 One Line Text Editor, Step 3: Enabling Input
9.7 One Line Text Editor, Step 4: Caret Moving & Cursor Shape
9.8 One Line Text Editor, Step 5: Selection
9.9 One Line Text Editor, Step 6: Cut, Copy and Paste
9.10 One Line Text Editor, Step 7: Getting Rid of Flickering
10.1 BitBlt and StretchBlt
10.2 Extracting Palette from DIB
1.3 Loading DIB from File
10.4 Saving DDB to File
10.5 Drawing DIB Directly
10.6 Bitmap Format Conversion: 256-color to 24-bit
10.7 Converting 24-bit Format to 256-color Format
10.8 Pixel Manipulation
10.9 DIB Section: Using Both DIB and DDB
10.10 Creating Chiseled Effect
CHAPTER 11. Sample: Simple Paint
11.0 Preparation
11.1 Ratio and Grid
11.2 Color Selection
11.3 Simple Drawing
11.4 Tracker
11.5 Moving the Selected Image
11.6 Region
11.7 Path
11.8 Freeform Selection
11.9 Cut, Copy and Paste
11.10 Palette Change & Flickering
CHAPTER 12. Screen Capturing & Printing
12.1 Capturing the Whole Screen
12.2 Capturing a Specified Window
12.3 Simple Printing
12.4 Fixed Scale Printing
12.5 Printing on Separate Pages
12.6 Customizing Print Dialog Box
CHAPTER 13. Adding Special Features to
Application
13.1 One Instance Application13.2 Creating Applications without Using Document/View Structure
13.3 Implementing Multiple Views
13.4 Multiple Documents Implementation
13.5 Painting Caption Bar
13.6 Irregular Shape Window
13.7 Saving Initial States
13.8 Exchanging User-Defined Messages Among Applications
13.9 Z-Order
13.10 Hook
13.11 Journal Record and Journal Playback Hooks
13.12 Memory Sharing Among Processes
14.1 Edit View
14.2 Rich Edit View
14.3 Simple Explorer, Step 1: Preparation
14.4 Simple Explorer, Step 2: List Drives
14.5 Simple Explorer, Step 3: Listing Directories
14.6 Simple Explorer, Step 4: Displaying Files
14.7 Simple Explorer, Step 5: Displaying Registered Icons
14.8 Simple Explorer, Step 6: Clicking and Double Clicking
14.9 Simple Explorer, Step 7: File Sort
14.10 Using Form View
15.1 DDE Registration15.2 Connecting to Server
15.3 Transaction: Data Request
15.4 Transaction: Advise
15.5 Transactions: Poke and Execute
15.6 Asynchronous Transaction
15.7 Program Manager: A DDE Server
CHAPTER 16. Context Sensitive Help
16.1 Context Sensitive Help for Menu Commands16.2 Context Sensitive Help for Common Controls