GDI+ Programming : Creating Custom Controls Using C#

by ; ;
Format: Trade Paper
Pub. Date: 2002-06-01
Publisher(s): Springer-Verlag New York Inc
List Price: $52.49

Rent Book

Select for Price
There was a problem. Please try again later.

New Book

We're Sorry
Sold Out

Used Book

We're Sorry
Sold Out

eBook

We're Sorry
Not Available

How Marketplace Works:

  • This item is offered by an independent seller and not shipped from our warehouse
  • Item details like edition and cover design may differ from our description; see seller's comments before ordering.
  • Sellers much confirm and ship within two business days; otherwise, the order will be cancelled and refunded.
  • Marketplace purchases cannot be returned to eCampus.com. Contact the seller directly for inquiries; if no response within two days, contact customer service.
  • Additional shipping costs apply to Marketplace purchases. Review shipping costs at checkout.

Summary

Provides accessible, comprehensive GDI+ coverage for business applications. Oriented towards a business applications audience and developers using both Windows Forms and Web Forms. Softcover.

Table of Contents

Introductionp. 1
Who is this Book For?p. 2
What Does this Book Cover?p. 2
What You Need to Use this Bookp. 4
Style Conventionsp. 5
Customer Support and Feedbackp. 6
Source Code and Updatesp. 6
Erratap. 6
Technical Supportp. 7
p2p.wrox.comp. 7
An Overview of GDI+ and Custom Controlsp. 11
GDI+ and .NETp. 12
What is GDI+?p. 13
The GDI+ Namespacesp. 16
Custom Controlsp. 17
Building Windows Forms Custom Controlsp. 17
Web Forms Custom Controlsp. 18
Creating Generic Code for both Windows Forms and Web Formsp. 20
A First Examplep. 20
Summaryp. 35
Drawing Surfacesp. 37
Drawing Surfacesp. 38
Raster-based and Vector-based Drawing Surfacesp. 38
The Characteristics of a Drawing Surfacep. 39
The Color Structurep. 41
Drawing Surfaces in Different Environmentsp. 44
A Summary of Drawing Surfacesp. 46
The Graphics Classp. 47
The GDI+ Coordinate Systemp. 51
Summaryp. 62
Pens and Brushesp. 65
Drawing with the Pen Objectp. 66
Controlling Properties of the Penp. 67
The Pens Classp. 75
Filling with the Brush Objectp. 76
Using the Brush Classesp. 76
The Brushes Classp. 90
Creating a Pen from a Brushp. 90
A Note about Performancep. 91
Summaryp. 92
Text and Fontsp. 95
An Overview of Text and Fontsp. 96
Working with Fonts in GDI+p. 97
Drawing Basic Textp. 101
Formatting Textp. 103
Font Stylesp. 104
Lines, Alignment, and Orientationp. 105
Dealing with Fontsp. 114
Finding Available Fontsp. 114
Font Metrics and Precision Text Placementp. 115
Quality of Textp. 121
Summaryp. 127
Imagesp. 131
An Overview of Image Handlingp. 132
The Image, Bitmap, and Metafile Classesp. 132
Different Types of Bitmapp. 135
Encoders and Decodersp. 136
Pixel Formatp. 138
Displaying Imagesp. 141
Checking the Size and Resolutionp. 142
Changing the Resolution of a Bitmapp. 145
Image Resizing and Interpolationp. 146
Manipulating Imagesp. 148
Cropping an Imagep. 148
Skewing, Reflecting, and Rotating an Imagep. 149
Cloning an Imagep. 151
Getting a Thumbnail of an Imagep. 152
Creating and Drawing into an Imagep. 153
Creating a New Bitmapp. 153
Double-bufferingp. 156
Working with Alpha in Imagesp. 157
Getting and Setting Pixelsp. 160
Setting Alpha for an Entire Imagep. 162
Playing an Animationp. 165
Converting a BMP to a JPEGp. 167
Summaryp. 169
GraphicsPaths and Regionsp. 171
What are GraphicsPaths and Regions?p. 171
The GraphicsPath Classp. 172
The Region Classp. 181
Summaryp. 187
Clipping and Invalidationp. 191
The Clipping Regionp. 192
Cropping with the Clipping Regionp. 192
Selective Repainting with the Clipping Regionp. 198
Clipping at the Pixel Levelp. 207
Invalidationp. 209
Using State in our Controlp. 209
How Invalidation Worksp. 210
A Few Clipping Tipsp. 214
Summaryp. 215
Transformationsp. 219
Transformations in GDI+p. 219
Coordinate Systems and Transformationsp. 221
World Transformationsp. 222
Invalidation and Clippingp. 235
Transformations and Custom Controlsp. 236
Summaryp. 236
Printingp. 239
The Printing Processp. 240
The Printing-related Classes in GDI+p. 241
How is a Document Printed or Print-previewed?p. 242
Using the Printing Classesp. 243
A Simple Printing Examplep. 244
Selecting the Unit of Measurementp. 254
Default Graphics Unitsp. 255
The Ruler Printing Examplep. 256
Printing Metricsp. 258
Displaying Printing Metricsp. 260
Controlling the Printer Drawing Surfacep. 262
Where the User Changes the Settingsp. 266
Summaryp. 267
An Alternative Coordinate Systemp. 271
Defining the Problemp. 272
The Outline Model Coordinate Systemp. 276
The GraphicsOM Classp. 276
Creating a 3D Effectp. 282
Summaryp. 286
Architecture and Design of Windows Forms Custom Controlsp. 289
Basic Principlesp. 290
What is a Component?p. 291
What is a Custom Control?p. 294
Building a Windows Forms Custom Controlp. 295
The Simple Custom Control Samplep. 295
Using a Custom Controlp. 297
Creating a Test Applicationp. 299
Adding Properties to our Custom Controlp. 301
Custom Control with Properties Examplep. 301
Creating a Test Applicationp. 305
Default Values of Propertiesp. 306
Custom Control with Default Property Values Samplep. 306
Focusp. 310
Focus Cuesp. 310
Steps to Implement a Focusable Controlp. 311
Focusable Control Examplep. 312
Creating a Test Applicationp. 320
Generating Eventsp. 322
Overview of Delegates and Eventsp. 322
Events Examplep. 323
Create a Test Applicationp. 326
Deriving from an Existing Controlp. 327
NumberTextBox Examplep. 327
Creating the Controlp. 328
Creating a Test Applicationp. 332
Composite Custom Controlsp. 333
DataButtons Examplep. 334
Create a Test Applicationp. 336
Designing Components and Custom Controlsp. 337
Advantages of Non-Procedural Constructsp. 338
Designing Components Using this Philosophyp. 339
Designing Eventsp. 340
Summaryp. 340
Design-Time Supportp. 343
Basic Conceptsp. 343
Editing Properties in the Properties Windowp. 344
Editing the Control in the Design Viewp. 346
Categorizing Properties and Eventsp. 347
Improved Editing in the Properties Windowp. 348
The NumberRange Structp. 350
The TypeConverter-Derived Classp. 351
The NumberTextBoxA Controlp. 356
Creating a Test Applicationp. 358
Debugging Design-Time Codep. 358
Creating a Modal Dialog Box Property Editorp. 359
The NumberTextBoxB Controlp. 360
The NumberRangeDialogp. 361
The NumberRangeEditorp. 363
Creating a Test Applicationp. 366
Creating a Drop-Down Property Editorp. 367
The NumberRangeDropDown Controlp. 367
The NumberRangeEditorp. 371
Creating a Test Applicationp. 372
Implementing a Custom Designerp. 373
The SimpleBlankControlp. 374
The SimpleLineControlp. 376
Summaryp. 382
Scrollingp. 385
Building a Scrolling Samplep. 386
Setting the Scrollbar Positionp. 387
Drawing in a Viewportp. 388
Scrolling Techniquesp. 389
Which Approach do I Use?p. 390
Placing a Non-Scrollable Control in a Panelp. 392
Smooth Scrollingp. 393
The SmoothScrollableControl Samplep. 393
Testing the Controlp. 400
Summaryp. 401
Mouse Events and Cursorsp. 403
Mouse Eventsp. 404
Mouse Cursorsp. 405
Standard Mouse Cursorsp. 406
The CursorsExamplep. 406
Custom Mouse Cursorsp. 408
Hit Testing and Drawing During Mouse Eventsp. 409
The HitTestExamplep. 410
Mouse Event Routingp. 414
The RoutingMouseEvents Samplep. 415
Handling the CaptureChanged Eventp. 418
GDI and BitBltp. 421
Why Use GDI?p. 422
Using BitBlt()p. 423
The Simple BitBltExamplep. 424
Drawing While Draggingp. 425
The AlphaDragExamplep. 425
Drag-Scrollingp. 432
Demonstrating the 'Wiggle-the-Mouse Bug'p. 433
Removing the Wiggle Bugp. 441
Summaryp. 443
GDI+ Images in ASP.NETp. 445
Internet Information Services (IIS)p. 446
Documentationp. 448
Security and Virtual Directoriesp. 449
Reading and Serving Imagesp. 450
Streamsp. 452
Reading an Image from a Remote Web Serverp. 453
Mixing HTML and Dynamic Imagesp. 455
Modifying Imagesp. 457
Creating a New Imagep. 462
Pie Chartsp. 466
Summaryp. 469
Creating Custom ASP.NET Server Controlsp. 471
Custom Controlsp. 472
Creating an ASP.NET User Controlp. 473
User Control Propertiesp. 475
A Custom Button User Controlp. 476
Creating a Thumbnail Controlp. 481
Making a Thumbnailp. 481
Creating a Custom Controlp. 484
Creating a Thumbnail Picture Galleryp. 486
Design-Time Supportp. 488
Creating a Toolbox Iconp. 488
Other Design-Time Featuresp. 489
Summaryp. 490
Web Services and GDI+p. 493
What are Web Services?p. 493
How can GDI+ be used with a Web Service?p. 494
A Simple Web Servicep. 495
The Hello World Web Servicep. 495
Returning an Image URLp. 498
The Image URL Web Servicep. 501
Returning Image Datap. 503
Summaryp. 507
Indexp. 509
Table of Contents provided by Syndetics. All Rights Reserved.

An electronic version of this book is available through VitalSource.

This book is viewable on PC, Mac, iPhone, iPad, iPod Touch, and most smartphones.

By purchasing, you will be able to view this book online, as well as download it, for the chosen number of days.

Digital License

You are licensing a digital product for a set duration. Durations are set forth in the product description, with "Lifetime" typically meaning five (5) years of online access and permanent download to a supported device. All licenses are non-transferable.

More details can be found here.

A downloadable version of this book is available through the eCampus Reader or compatible Adobe readers.

Applications are available on iOS, Android, PC, Mac, and Windows Mobile platforms.

Please view the compatibility matrix prior to purchase.