Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / WinForms / Managed / System / WinForms / DrawTreeNodeEventArgs.cs / 1305376 / DrawTreeNodeEventArgs.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System.Diagnostics; using System; using System.ComponentModel; using System.Drawing; using Microsoft.Win32; using System.Windows.Forms.VisualStyles; ////// /// This class contains the information a user needs to paint TreeView nodes. /// public class DrawTreeNodeEventArgs : EventArgs { private readonly Graphics graphics; private readonly TreeNode node; private readonly Rectangle bounds; private readonly TreeNodeStates state; private bool drawDefault; ////// /// Creates a new DrawTreeNodeEventArgs with the given parameters. /// public DrawTreeNodeEventArgs(Graphics graphics, TreeNode node, Rectangle bounds, TreeNodeStates state) { this.graphics = graphics; this.node = node; this.bounds = bounds; this.state = state; this.drawDefault = false; } ////// /// Causes the item do be drawn by the system instead of owner drawn. /// NOTE: In OwnerDrawText mode, setting this to true is same as calling DrawText. /// public bool DrawDefault { get { return drawDefault; } set { drawDefault = value; } } ////// /// Graphics object with which painting should be done. /// public Graphics Graphics { get { return graphics; } } ////// /// The node to be painted. /// public TreeNode Node { get { return node; } } ////// /// The rectangle outlining the area in which the painting should be done. /// public Rectangle Bounds { get { return bounds; } } ////// /// Miscellaneous state information. /// public TreeNodeStates State { get { return state; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System.Diagnostics; using System; using System.ComponentModel; using System.Drawing; using Microsoft.Win32; using System.Windows.Forms.VisualStyles; ////// /// This class contains the information a user needs to paint TreeView nodes. /// public class DrawTreeNodeEventArgs : EventArgs { private readonly Graphics graphics; private readonly TreeNode node; private readonly Rectangle bounds; private readonly TreeNodeStates state; private bool drawDefault; ////// /// Creates a new DrawTreeNodeEventArgs with the given parameters. /// public DrawTreeNodeEventArgs(Graphics graphics, TreeNode node, Rectangle bounds, TreeNodeStates state) { this.graphics = graphics; this.node = node; this.bounds = bounds; this.state = state; this.drawDefault = false; } ////// /// Causes the item do be drawn by the system instead of owner drawn. /// NOTE: In OwnerDrawText mode, setting this to true is same as calling DrawText. /// public bool DrawDefault { get { return drawDefault; } set { drawDefault = value; } } ////// /// Graphics object with which painting should be done. /// public Graphics Graphics { get { return graphics; } } ////// /// The node to be painted. /// public TreeNode Node { get { return node; } } ////// /// The rectangle outlining the area in which the painting should be done. /// public Rectangle Bounds { get { return bounds; } } ////// /// Miscellaneous state information. /// public TreeNodeStates State { get { return state; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- figurelength.cs
- FragmentQueryProcessor.cs
- PageContentAsyncResult.cs
- MonthChangedEventArgs.cs
- _SSPISessionCache.cs
- SafeLocalMemHandle.cs
- ConnectionInterfaceCollection.cs
- LineSegment.cs
- FaultReasonText.cs
- DataGridBoolColumn.cs
- SiteMapPath.cs
- FlowDocumentFormatter.cs
- DataGridViewAutoSizeColumnsModeEventArgs.cs
- ItemCollection.cs
- Translator.cs
- SharedStatics.cs
- UIAgentAsyncEndRequest.cs
- BeginStoryboard.cs
- HtmlMobileTextWriter.cs
- MachineKeyValidationConverter.cs
- WriteableBitmap.cs
- BasicDesignerLoader.cs
- ToolStripItemImageRenderEventArgs.cs
- WebPageTraceListener.cs
- CodeAttributeArgumentCollection.cs
- GetIndexBinder.cs
- RNGCryptoServiceProvider.cs
- _UriTypeConverter.cs
- MouseEventArgs.cs
- TypedOperationInfo.cs
- XPathDescendantIterator.cs
- DataColumnPropertyDescriptor.cs
- DateRangeEvent.cs
- ProjectionPath.cs
- GridLength.cs
- OdbcConnectionPoolProviderInfo.cs
- FixedSOMElement.cs
- DataGridViewToolTip.cs
- SafeHandle.cs
- ConnectionPoolManager.cs
- HttpClientCertificate.cs
- ColorConvertedBitmap.cs
- LingerOption.cs
- NameTable.cs
- StreamWithDictionary.cs
- SecurityPolicySection.cs
- PathFigure.cs
- NotifyIcon.cs
- MetricEntry.cs
- XmlAnyElementAttributes.cs
- UIElement3D.cs
- LocalServiceSecuritySettings.cs
- SystemGatewayIPAddressInformation.cs
- CounterCreationDataCollection.cs
- TokenBasedSet.cs
- DataServiceContext.cs
- HtmlFormParameterReader.cs
- RtfToXamlReader.cs
- WindowsSpinner.cs
- NameValueConfigurationCollection.cs
- NoClickablePointException.cs
- SoapObjectInfo.cs
- SafeNativeHandle.cs
- CheckBoxList.cs
- RegisteredScript.cs
- jithelpers.cs
- FrameworkEventSource.cs
- PeerNameRecordCollection.cs
- SmiEventSink_DeferedProcessing.cs
- MenuItemBindingCollection.cs
- BitmapDownload.cs
- EntityDataSourceContainerNameConverter.cs
- DeferredSelectedIndexReference.cs
- CompilationUtil.cs
- OracleSqlParser.cs
- SolidColorBrush.cs
- BindableTemplateBuilder.cs
- ObjectDataSourceFilteringEventArgs.cs
- DesignerLabelAdapter.cs
- RtfToXamlLexer.cs
- ForAllOperator.cs
- XmlElementAttribute.cs
- InputGestureCollection.cs
- RegistryPermission.cs
- Logging.cs
- RadioButtonFlatAdapter.cs
- StylusButton.cs
- OracleDateTime.cs
- WebConvert.cs
- ProcessThreadDesigner.cs
- HttpHeaderCollection.cs
- WebCategoryAttribute.cs
- KnownBoxes.cs
- DateTimeOffset.cs
- EntityWrapperFactory.cs
- JsonReaderDelegator.cs
- PreProcessInputEventArgs.cs
- BaseResourcesBuildProvider.cs
- LoginName.cs
- TextStore.cs