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
- FtpWebRequest.cs
- ToolStripContainer.cs
- PtsHost.cs
- RectangleGeometry.cs
- ArraySortHelper.cs
- ItemDragEvent.cs
- SystemDiagnosticsSection.cs
- DataGridViewRowEventArgs.cs
- WindowsAuthenticationModule.cs
- PerformanceCounterPermission.cs
- SqlDelegatedTransaction.cs
- ToolBarPanel.cs
- DatatypeImplementation.cs
- HttpCapabilitiesEvaluator.cs
- HtmlTableRowCollection.cs
- PathSegmentCollection.cs
- KeyPullup.cs
- ReachFixedPageSerializer.cs
- CacheEntry.cs
- LocalValueEnumerator.cs
- Style.cs
- Expressions.cs
- PropertyInformationCollection.cs
- ObjectSecurityT.cs
- HttpPostedFileBase.cs
- EntityType.cs
- AdCreatedEventArgs.cs
- UserControlCodeDomTreeGenerator.cs
- TreeBuilderBamlTranslator.cs
- HttpCachePolicy.cs
- ExtentJoinTreeNode.cs
- PropVariant.cs
- SHA384Managed.cs
- AssemblyInfo.cs
- OdbcEnvironmentHandle.cs
- HttpFormatExtensions.cs
- MatrixAnimationUsingPath.cs
- EventToken.cs
- OverrideMode.cs
- StructuralCache.cs
- XmlChoiceIdentifierAttribute.cs
- CodeComment.cs
- Variable.cs
- NativeCppClassAttribute.cs
- DaylightTime.cs
- UnknownWrapper.cs
- DesignerDataTable.cs
- DataControlImageButton.cs
- SqlRewriteScalarSubqueries.cs
- TypeUtils.cs
- InstanceKeyCompleteException.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- WindowsGraphicsCacheManager.cs
- ValidationError.cs
- FormsAuthenticationModule.cs
- ImmutableObjectAttribute.cs
- XmlDomTextWriter.cs
- XmlIterators.cs
- ReadOnlyHierarchicalDataSource.cs
- ScriptingJsonSerializationSection.cs
- Composition.cs
- Timer.cs
- SapiRecoContext.cs
- SystemIPGlobalProperties.cs
- RecordsAffectedEventArgs.cs
- WorkflowMarkupElementEventArgs.cs
- StatusBarDrawItemEvent.cs
- TrackingValidationObjectDictionary.cs
- StoreUtilities.cs
- ModelItem.cs
- ColorTranslator.cs
- ResourcePool.cs
- MailWriter.cs
- SqlInternalConnection.cs
- UIElementParagraph.cs
- AxHost.cs
- EventDescriptor.cs
- XmlSchemaSimpleContentExtension.cs
- RuleRefElement.cs
- SafeFindHandle.cs
- AutomationTextAttribute.cs
- CopyCodeAction.cs
- Validator.cs
- DeclaredTypeValidator.cs
- HwndSubclass.cs
- TextCompositionManager.cs
- WebServiceTypeData.cs
- XmlDataSource.cs
- RightNameExpirationInfoPair.cs
- NotifyParentPropertyAttribute.cs
- Queue.cs
- Validator.cs
- ToolStripContextMenu.cs
- EventItfInfo.cs
- StorageBasedPackageProperties.cs
- HostExecutionContextManager.cs
- hresults.cs
- PropertyDescriptorGridEntry.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- WebConfigurationHostFileChange.cs