Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / whidbey / netfxsp / ndp / fx / src / WinForms / Managed / System / WinForms / MeasureItemEvent.cs / 1 / MeasureItemEvent.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; ////// /// This event is sent by controls such as the ListBox or ComboBox that need users /// to tell them how large a given item is to be. /// public class MeasureItemEventArgs : EventArgs { private int itemHeight; private int itemWidth; private int index; private readonly System.Drawing.Graphics graphics; ////// /// public MeasureItemEventArgs(Graphics graphics, int index, int itemHeight) { this.graphics = graphics; this.index = index; this.itemHeight = itemHeight; this.itemWidth = 0; } ///[To be supplied.] ////// /// public MeasureItemEventArgs(Graphics graphics, int index) { this.graphics = graphics; this.index = index; this.itemHeight = 0; this.itemWidth = 0; } ///[To be supplied.] ////// /// A Graphics object to measure relative to. /// public System.Drawing.Graphics Graphics { get { return graphics; } } ////// /// The index of item for which the height/width is needed. /// public int Index { get { return index; } } ////// /// Where the recipient of the event should put the height of the /// item specified by the index. /// public int ItemHeight { get { return itemHeight; } set { itemHeight = value; } } ////// /// Where the recipient of the event should put the width of the /// item specified by the index. /// public int ItemWidth { get { return itemWidth; } set { itemWidth = value; } } } } // 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; ////// /// This event is sent by controls such as the ListBox or ComboBox that need users /// to tell them how large a given item is to be. /// public class MeasureItemEventArgs : EventArgs { private int itemHeight; private int itemWidth; private int index; private readonly System.Drawing.Graphics graphics; ////// /// public MeasureItemEventArgs(Graphics graphics, int index, int itemHeight) { this.graphics = graphics; this.index = index; this.itemHeight = itemHeight; this.itemWidth = 0; } ///[To be supplied.] ////// /// public MeasureItemEventArgs(Graphics graphics, int index) { this.graphics = graphics; this.index = index; this.itemHeight = 0; this.itemWidth = 0; } ///[To be supplied.] ////// /// A Graphics object to measure relative to. /// public System.Drawing.Graphics Graphics { get { return graphics; } } ////// /// The index of item for which the height/width is needed. /// public int Index { get { return index; } } ////// /// Where the recipient of the event should put the height of the /// item specified by the index. /// public int ItemHeight { get { return itemHeight; } set { itemHeight = value; } } ////// /// Where the recipient of the event should put the width of the /// item specified by the index. /// public int ItemWidth { get { return itemWidth; } set { itemWidth = value; } } } } // 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
- ClusterSafeNativeMethods.cs
- InvalidateEvent.cs
- MemberHolder.cs
- StructuredTypeInfo.cs
- SqlReorderer.cs
- Line.cs
- StringConverter.cs
- BinaryMethodMessage.cs
- TagPrefixAttribute.cs
- TextReader.cs
- LinqDataSource.cs
- EntitySetDataBindingList.cs
- ParserContext.cs
- GridPatternIdentifiers.cs
- ListGeneralPage.cs
- QueryCacheEntry.cs
- DbConnectionInternal.cs
- BufferedResponseStream.cs
- ThaiBuddhistCalendar.cs
- unsafenativemethodsother.cs
- Brush.cs
- XsltArgumentList.cs
- DefinitionUpdate.cs
- ReadOnlyDataSourceView.cs
- SizeChangedInfo.cs
- PauseStoryboard.cs
- DbException.cs
- TablePatternIdentifiers.cs
- WebPartEditorCancelVerb.cs
- ByteKeyFrameCollection.cs
- ImageMapEventArgs.cs
- FileDialogPermission.cs
- QuaternionConverter.cs
- SerializationStore.cs
- ToolStripArrowRenderEventArgs.cs
- DataObjectEventArgs.cs
- VisualStyleElement.cs
- DataServiceExpressionVisitor.cs
- SizeConverter.cs
- WindowsIPAddress.cs
- ObjectDataSourceChooseTypePanel.cs
- cookieexception.cs
- MenuScrollingVisibilityConverter.cs
- RoutedEvent.cs
- IndentTextWriter.cs
- RequestCacheEntry.cs
- ComponentTray.cs
- Nullable.cs
- TextBox.cs
- PolyQuadraticBezierSegment.cs
- BatchParser.cs
- CodeSubDirectory.cs
- StructuredCompositeActivityDesigner.cs
- CustomError.cs
- FigureParaClient.cs
- _SslState.cs
- XmlnsCompatibleWithAttribute.cs
- ThreadAttributes.cs
- DataGridViewCellLinkedList.cs
- BitmapSourceSafeMILHandle.cs
- ListItemsCollectionEditor.cs
- StandardRuntimeEnumValidator.cs
- HotCommands.cs
- TextModifier.cs
- RC2.cs
- HtmlInputReset.cs
- OdbcPermission.cs
- CharEntityEncoderFallback.cs
- PropertyStore.cs
- Rijndael.cs
- CheckBoxField.cs
- COM2ICategorizePropertiesHandler.cs
- SmiConnection.cs
- DataGridViewTopLeftHeaderCell.cs
- _ListenerAsyncResult.cs
- RemotingConfigParser.cs
- HijriCalendar.cs
- HttpRequestCacheValidator.cs
- Statements.cs
- DiscardableAttribute.cs
- SQLChars.cs
- OutputScope.cs
- WebAdminConfigurationHelper.cs
- DebugView.cs
- PresentationSource.cs
- TextTreeNode.cs
- ObjectConverter.cs
- AttachedPropertyInfo.cs
- TransformCollection.cs
- SystemResources.cs
- Literal.cs
- TextChange.cs
- BindingValueChangedEventArgs.cs
- WindowsFormsSectionHandler.cs
- RemoteWebConfigurationHostServer.cs
- EncoderFallback.cs
- EventDescriptor.cs
- CallbackValidatorAttribute.cs
- QuestionEventArgs.cs
- Base64Encoder.cs