Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / CommonUI / System / Drawing / Design / PaintValueEventArgs.cs / 1 / PaintValueEventArgs.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Drawing.Design { using System; using System.ComponentModel; using System.Diagnostics; using System.Drawing; ////// /// This object is passed to UITypeEditor.PaintValue. /// It contains all the information needed for the editor to /// paint the given value, including the Rectangle in which /// the drawing should be done, and the Graphics object with which the drawing /// should be done. /// [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.InheritanceDemand, Name="FullTrust")] [System.Security.Permissions.PermissionSetAttribute(System.Security.Permissions.SecurityAction.LinkDemand, Name="FullTrust")] public class PaintValueEventArgs : EventArgs { private readonly ITypeDescriptorContext context; private readonly object valueToPaint; ////// /// The graphics object with which the drawing should be done. /// private readonly Graphics graphics; ////// /// The rectangle outlining the area in which the painting should be /// done. /// private readonly Rectangle bounds; ////// /// Creates a new PaintValueEventArgs with the given parameters. /// public PaintValueEventArgs(ITypeDescriptorContext context, object value, Graphics graphics, Rectangle bounds) { this.context = context; this.valueToPaint = value; this.graphics = graphics; if (graphics == null) throw new ArgumentNullException("graphics"); this.bounds = bounds; } ////// /// The rectangle outlining the area in which the painting should be /// done. /// public Rectangle Bounds { get { return bounds; } } ////// /// ITypeDescriptorContext object for additional information about the context this value appears in. /// public ITypeDescriptorContext Context { get { return context; } } ////// /// Graphics object with which painting should be done. /// public Graphics Graphics { get { return graphics; } } ////// /// The value to paint. /// public object Value { get { return valueToPaint; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- MessageSmuggler.cs
- SiteMembershipCondition.cs
- StrongNameSignatureInformation.cs
- StandardToolWindows.cs
- TagMapInfo.cs
- Rectangle.cs
- ContextDataSource.cs
- DataGridViewRowDividerDoubleClickEventArgs.cs
- CompressionTransform.cs
- SortedDictionary.cs
- GenericUriParser.cs
- QuaternionRotation3D.cs
- DesignerActionUIService.cs
- TargetControlTypeAttribute.cs
- XsltInput.cs
- ScopedKnownTypes.cs
- StatusBarPanel.cs
- PassportPrincipal.cs
- PanelDesigner.cs
- XomlCompiler.cs
- HttpListenerContext.cs
- SQLDateTime.cs
- LambdaCompiler.Logical.cs
- ApplicationDirectoryMembershipCondition.cs
- WebPartZoneAutoFormat.cs
- HostedElements.cs
- TabletCollection.cs
- HttpRawResponse.cs
- WebBrowserBase.cs
- ItemCollection.cs
- DataPointer.cs
- SqlFormatter.cs
- DesignBindingEditor.cs
- DocumentationServerProtocol.cs
- XmlIncludeAttribute.cs
- BrowserInteropHelper.cs
- PerformanceCounterManager.cs
- DataServiceProcessingPipeline.cs
- ActiveXHelper.cs
- CompositeActivityDesigner.cs
- AspNetSynchronizationContext.cs
- Configuration.cs
- ReverseInheritProperty.cs
- ScrollBar.cs
- FormViewUpdateEventArgs.cs
- TypographyProperties.cs
- HierarchicalDataTemplate.cs
- InvalidPropValue.cs
- PropertyNames.cs
- OrderablePartitioner.cs
- QilStrConcatenator.cs
- TextEffect.cs
- ColumnResult.cs
- OdbcReferenceCollection.cs
- SoapMessage.cs
- ControlBindingsConverter.cs
- IntegrationExceptionEventArgs.cs
- ApplyImportsAction.cs
- PtsHost.cs
- UrlAuthFailedErrorFormatter.cs
- Literal.cs
- DragDrop.cs
- AudioFileOut.cs
- InternalConfigHost.cs
- HttpCacheParams.cs
- ReadOnlyNameValueCollection.cs
- SafeArrayTypeMismatchException.cs
- smtppermission.cs
- SystemEvents.cs
- Misc.cs
- OdbcError.cs
- NativeActivityMetadata.cs
- DesignUtil.cs
- LocatorBase.cs
- CustomAttributeBuilder.cs
- RepeatButtonAutomationPeer.cs
- HtmlShim.cs
- DecimalStorage.cs
- WinFormsUtils.cs
- ToolStripComboBox.cs
- HuffModule.cs
- DesignerAttribute.cs
- PrintController.cs
- CodePageEncoding.cs
- ButtonBase.cs
- XmlTextReaderImplHelpers.cs
- TabPage.cs
- HttpWriter.cs
- AmbientLight.cs
- Span.cs
- ResourceManager.cs
- DocumentGrid.cs
- RowVisual.cs
- SecurityTokenAuthenticator.cs
- SqlClientWrapperSmiStream.cs
- EpmSyndicationContentDeSerializer.cs
- Overlapped.cs
- EventHandlingScope.cs
- Misc.cs
- MessageBodyMemberAttribute.cs