Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / CommonUI / System / Drawing / Printing / PrintPageEvent.cs / 1 / PrintPageEvent.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Drawing.Printing { using System.Diagnostics; using System; using System.Drawing; using System.ComponentModel; using Microsoft.Win32; ////// /// // NOTE: Please keep this class consistent with PaintEventArgs. public class PrintPageEventArgs : EventArgs { private bool hasMorePages; private bool cancel; private Graphics graphics; private readonly Rectangle marginBounds; private readonly Rectangle pageBounds; private readonly PageSettings pageSettings; ///Provides data for the ////// event. /// /// public PrintPageEventArgs(Graphics graphics, Rectangle marginBounds, Rectangle pageBounds, PageSettings pageSettings) { this.graphics = graphics; // may be null, see PrintController this.marginBounds = marginBounds; this.pageBounds = pageBounds; this.pageSettings = pageSettings; } ///Initializes a new instance of the ///class. /// /// public bool Cancel { get { return cancel;} set { cancel = value;} } ///Gets or sets a value indicating whether the print job should be canceled. ////// /// public Graphics Graphics { get { return graphics; } } ////// Gets the ////// used to paint the /// item. /// /// /// public bool HasMorePages { get { return hasMorePages;} set { hasMorePages = value;} } ///Gets or sets a value indicating whether an additional page should /// be printed. ////// /// public Rectangle MarginBounds { get { return marginBounds; } } ///Gets the rectangular area that represents the portion of the page between the margins. ////// /// public Rectangle PageBounds { get { return pageBounds; } } ////// Gets the rectangular area that represents the total area of the page. /// ////// /// public PageSettings PageSettings { get { return pageSettings; } } ///Gets /// the page settings for the current page. ////// /// // We want a way to dispose the GDI+ Graphics, but we don't want to create one // simply to dispose it internal void Dispose() { graphics.Dispose(); } internal void SetGraphics(Graphics value) { this.graphics = value; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //Disposes /// of the resources (other than memory) used by /// the ///. // Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Drawing.Printing { using System.Diagnostics; using System; using System.Drawing; using System.ComponentModel; using Microsoft.Win32; ////// /// // NOTE: Please keep this class consistent with PaintEventArgs. public class PrintPageEventArgs : EventArgs { private bool hasMorePages; private bool cancel; private Graphics graphics; private readonly Rectangle marginBounds; private readonly Rectangle pageBounds; private readonly PageSettings pageSettings; ///Provides data for the ////// event. /// /// public PrintPageEventArgs(Graphics graphics, Rectangle marginBounds, Rectangle pageBounds, PageSettings pageSettings) { this.graphics = graphics; // may be null, see PrintController this.marginBounds = marginBounds; this.pageBounds = pageBounds; this.pageSettings = pageSettings; } ///Initializes a new instance of the ///class. /// /// public bool Cancel { get { return cancel;} set { cancel = value;} } ///Gets or sets a value indicating whether the print job should be canceled. ////// /// public Graphics Graphics { get { return graphics; } } ////// Gets the ////// used to paint the /// item. /// /// /// public bool HasMorePages { get { return hasMorePages;} set { hasMorePages = value;} } ///Gets or sets a value indicating whether an additional page should /// be printed. ////// /// public Rectangle MarginBounds { get { return marginBounds; } } ///Gets the rectangular area that represents the portion of the page between the margins. ////// /// public Rectangle PageBounds { get { return pageBounds; } } ////// Gets the rectangular area that represents the total area of the page. /// ////// /// public PageSettings PageSettings { get { return pageSettings; } } ///Gets /// the page settings for the current page. ////// /// // We want a way to dispose the GDI+ Graphics, but we don't want to create one // simply to dispose it internal void Dispose() { graphics.Dispose(); } internal void SetGraphics(Graphics value) { this.graphics = value; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.Disposes /// of the resources (other than memory) used by /// the ///.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Scene3D.cs
- IntSecurity.cs
- UpdateCompiler.cs
- DispatcherFrame.cs
- OdbcParameter.cs
- input.cs
- XhtmlBasicObjectListAdapter.cs
- ThaiBuddhistCalendar.cs
- OnOperation.cs
- FormClosingEvent.cs
- Propagator.JoinPropagator.SubstitutingCloneVisitor.cs
- KeyFrames.cs
- MenuItemBindingCollection.cs
- HatchBrush.cs
- BamlResourceDeserializer.cs
- SerialReceived.cs
- PeerEndPoint.cs
- ViewGenerator.cs
- InvalidOperationException.cs
- CalendarModeChangedEventArgs.cs
- ServiceOperationInfoTypeConverter.cs
- EventTrigger.cs
- CursorConverter.cs
- HotSpot.cs
- TraceSection.cs
- BindingValueChangedEventArgs.cs
- MappingSource.cs
- UnmanagedHandle.cs
- TempFiles.cs
- LayoutEditorPart.cs
- QueueException.cs
- EncoderReplacementFallback.cs
- FontFamily.cs
- FormViewPageEventArgs.cs
- X509ChainPolicy.cs
- ComponentRenameEvent.cs
- XPathNavigatorKeyComparer.cs
- SqlUserDefinedAggregateAttribute.cs
- DataListItemEventArgs.cs
- GeometryCombineModeValidation.cs
- PreviewKeyDownEventArgs.cs
- ListViewUpdateEventArgs.cs
- SharedRuntimeState.cs
- Literal.cs
- QilParameter.cs
- RelationshipEntry.cs
- ObjectFactoryCodeDomTreeGenerator.cs
- DataGridViewHeaderCell.cs
- VectorAnimationUsingKeyFrames.cs
- Control.cs
- Point3D.cs
- RenderCapability.cs
- SqlDataSourceWizardForm.cs
- DataGridHeaderBorder.cs
- ComplexPropertyEntry.cs
- TextServicesCompartmentEventSink.cs
- ConnectionManagementSection.cs
- ColumnMap.cs
- Configuration.cs
- DoubleCollection.cs
- XamlPoint3DCollectionSerializer.cs
- HtmlMeta.cs
- XmlIlTypeHelper.cs
- WorkItem.cs
- LinqDataSourceSelectEventArgs.cs
- ResourceWriter.cs
- ImpersonationContext.cs
- FamilyMapCollection.cs
- XmlAnyElementAttributes.cs
- FileVersionInfo.cs
- RSAPKCS1KeyExchangeDeformatter.cs
- Main.cs
- DelegatingConfigHost.cs
- DragDeltaEventArgs.cs
- DataPagerCommandEventArgs.cs
- SafeViewOfFileHandle.cs
- TouchFrameEventArgs.cs
- ManifestResourceInfo.cs
- EventLogQuery.cs
- HighlightVisual.cs
- ParameterCollection.cs
- System.Data_BID.cs
- TextBoxBase.cs
- PictureBoxDesigner.cs
- OdbcPermission.cs
- SignerInfo.cs
- WindowsToolbarItemAsMenuItem.cs
- ContourSegment.cs
- ByteAnimationBase.cs
- SudsCommon.cs
- TagPrefixInfo.cs
- Wizard.cs
- OdbcConnectionOpen.cs
- Matrix3D.cs
- InfoCardArgumentException.cs
- ManifestResourceInfo.cs
- ProfilePropertyMetadata.cs
- PlatformCulture.cs
- SystemWebSectionGroup.cs
- SqlVisitor.cs