Code:
/ FX-1434 / FX-1434 / 1.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
- XmlNamedNodeMap.cs
- TemplateApplicationHelper.cs
- MemoryRecordBuffer.cs
- DbDataAdapter.cs
- DataList.cs
- AppSettingsExpressionBuilder.cs
- DependencyPropertyConverter.cs
- SubclassTypeValidatorAttribute.cs
- WebPartConnectionsDisconnectVerb.cs
- X509Certificate2Collection.cs
- ConvertersCollection.cs
- TreeNode.cs
- ObjectDataSourceEventArgs.cs
- DataColumnChangeEvent.cs
- CorrelationManager.cs
- ProviderIncompatibleException.cs
- LineServicesRun.cs
- RolePrincipal.cs
- ComponentDispatcher.cs
- ExpandSegmentCollection.cs
- TextRange.cs
- XmlChoiceIdentifierAttribute.cs
- BaseCodeDomTreeGenerator.cs
- DynamicILGenerator.cs
- AspNetRouteServiceHttpHandler.cs
- MarkedHighlightComponent.cs
- ShaderEffect.cs
- TypeResolvingOptionsAttribute.cs
- ToolStripOverflow.cs
- AdCreatedEventArgs.cs
- StringDictionaryWithComparer.cs
- OdbcConnection.cs
- ToolStripDropDownItem.cs
- KeyValuePairs.cs
- DataRowComparer.cs
- SchemaLookupTable.cs
- DataControlPagerLinkButton.cs
- ExecutedRoutedEventArgs.cs
- DrawListViewItemEventArgs.cs
- XmlChoiceIdentifierAttribute.cs
- CodeMethodInvokeExpression.cs
- WebControlAdapter.cs
- DispatcherSynchronizationContext.cs
- LabelEditEvent.cs
- SiteMapNodeCollection.cs
- __Filters.cs
- ThicknessAnimationUsingKeyFrames.cs
- HttpRuntimeSection.cs
- DbConnectionFactory.cs
- EntitySetDataBindingList.cs
- SegmentInfo.cs
- RequiredFieldValidator.cs
- HtmlToClrEventProxy.cs
- WebPartMinimizeVerb.cs
- serverconfig.cs
- RegexRunnerFactory.cs
- Membership.cs
- ByteConverter.cs
- embossbitmapeffect.cs
- XamlDebuggerXmlReader.cs
- DataRecordInfo.cs
- XhtmlTextWriter.cs
- MsmqHostedTransportConfiguration.cs
- ButtonPopupAdapter.cs
- SlipBehavior.cs
- ViewStateModeByIdAttribute.cs
- WebScriptMetadataMessageEncoderFactory.cs
- XPathEmptyIterator.cs
- ServiceReference.cs
- XsdValidatingReader.cs
- NetCodeGroup.cs
- AmbientProperties.cs
- CodeCommentStatement.cs
- WebControl.cs
- ProfileSettings.cs
- WizardForm.cs
- RightsManagementInformation.cs
- TemplateControlCodeDomTreeGenerator.cs
- TextParentUndoUnit.cs
- FormsAuthenticationUserCollection.cs
- HttpCapabilitiesBase.cs
- DataFormat.cs
- SpeechUI.cs
- DbConnectionPoolGroupProviderInfo.cs
- BaseServiceProvider.cs
- QueueProcessor.cs
- SolidColorBrush.cs
- Border.cs
- PrinterSettings.cs
- XmlExpressionDumper.cs
- documentation.cs
- Bits.cs
- DetailsViewDeleteEventArgs.cs
- XmlUTF8TextWriter.cs
- TimeStampChecker.cs
- MinMaxParagraphWidth.cs
- SqlBooleanMismatchVisitor.cs
- XmlStringTable.cs
- DesignerAttribute.cs
- Literal.cs