Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / WinForms / Managed / System / WinForms / DrawTreeNodeEventArgs.cs / 1 / 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
- Paragraph.cs
- precedingsibling.cs
- DetailsViewDeleteEventArgs.cs
- ContainerControl.cs
- CollectionConverter.cs
- StorageAssociationSetMapping.cs
- ReflectionUtil.cs
- ActivityBindForm.Designer.cs
- GenericWebPart.cs
- ToolBar.cs
- isolationinterop.cs
- WindowHideOrCloseTracker.cs
- StrokeNode.cs
- FontFamilyValueSerializer.cs
- ThemeableAttribute.cs
- XmlEncoding.cs
- DataViewManager.cs
- ControlPaint.cs
- CurrentChangedEventManager.cs
- StaticContext.cs
- ScrollBar.cs
- LinearKeyFrames.cs
- DashStyle.cs
- ColumnReorderedEventArgs.cs
- ArrayList.cs
- DecoderNLS.cs
- Pair.cs
- HwndSourceKeyboardInputSite.cs
- Barrier.cs
- SafeLibraryHandle.cs
- HttpConfigurationSystem.cs
- MediaSystem.cs
- Point3D.cs
- DataStorage.cs
- PageSettings.cs
- FigureParaClient.cs
- DataObjectCopyingEventArgs.cs
- ZipIOCentralDirectoryFileHeader.cs
- SynchronousChannelMergeEnumerator.cs
- OrderByQueryOptionExpression.cs
- Roles.cs
- TcpPortSharing.cs
- ValueUnavailableException.cs
- Interop.cs
- CSharpCodeProvider.cs
- NumericUpDownAcceleration.cs
- IteratorDescriptor.cs
- Int64KeyFrameCollection.cs
- BinHexEncoder.cs
- BitmapCodecInfo.cs
- MinimizableAttributeTypeConverter.cs
- UIntPtr.cs
- SelectionEditor.cs
- ComponentCommands.cs
- oledbconnectionstring.cs
- SubMenuStyleCollection.cs
- FormViewUpdatedEventArgs.cs
- XPathParser.cs
- IsolatedStorageFile.cs
- InfoCardRequestException.cs
- SystemIPGlobalProperties.cs
- DispatcherTimer.cs
- HttpListenerRequestUriBuilder.cs
- CornerRadiusConverter.cs
- XmlUTF8TextWriter.cs
- TypeUnloadedException.cs
- ComboBox.cs
- WebAdminConfigurationHelper.cs
- IndexedString.cs
- DesignOnlyAttribute.cs
- WindowsTooltip.cs
- xdrvalidator.cs
- Attributes.cs
- Base64Encoding.cs
- PeerApplicationLaunchInfo.cs
- UserPersonalizationStateInfo.cs
- XmlAttributeProperties.cs
- ToolStripPanelDesigner.cs
- XmlSchemaAppInfo.cs
- AdPostCacheSubstitution.cs
- CustomValidator.cs
- MethodCallExpression.cs
- AssemblyBuilder.cs
- UnhandledExceptionEventArgs.cs
- ListViewItemMouseHoverEvent.cs
- JsonFaultDetail.cs
- EasingFunctionBase.cs
- ServiceModelActivationSectionGroup.cs
- Menu.cs
- DesignerVerbCollection.cs
- InvalidPropValue.cs
- SafeRegistryKey.cs
- SerializationSectionGroup.cs
- RunInstallerAttribute.cs
- ListBindableAttribute.cs
- CopyNodeSetAction.cs
- Separator.cs
- BitmapEncoder.cs
- X509LogoTypeExtension.cs
- PeerNameResolver.cs