Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- WebException.cs
- SchemaManager.cs
- XmlSerializerAssemblyAttribute.cs
- DynamicControl.cs
- WindowsStreamSecurityElement.cs
- RecordConverter.cs
- ClientConvert.cs
- AtomServiceDocumentSerializer.cs
- TextEditorTables.cs
- SwitchLevelAttribute.cs
- RouteValueDictionary.cs
- FixedTextPointer.cs
- coordinatorfactory.cs
- WorkflowServiceBehavior.cs
- BrowserCapabilitiesFactoryBase.cs
- ADMembershipProvider.cs
- HandleRef.cs
- InvokeMethodActivityDesigner.cs
- IntranetCredentialPolicy.cs
- FormViewInsertedEventArgs.cs
- Base64Encoder.cs
- WeakReference.cs
- Message.cs
- XmlNullResolver.cs
- PropertyEmitter.cs
- APCustomTypeDescriptor.cs
- XmlILStorageConverter.cs
- Camera.cs
- SubclassTypeValidator.cs
- ProtectedConfigurationSection.cs
- TemplateBamlTreeBuilder.cs
- DataTableNewRowEvent.cs
- PreviewPageInfo.cs
- PropertyGridView.cs
- dbdatarecord.cs
- ModelPropertyImpl.cs
- SqlClientFactory.cs
- OnOperation.cs
- TextContainerHelper.cs
- XPathArrayIterator.cs
- SqlRewriteScalarSubqueries.cs
- QuerySelectOp.cs
- XsltLoader.cs
- ProxyWebPartManager.cs
- cookiecollection.cs
- DefinitionUpdate.cs
- SizeF.cs
- InfiniteTimeSpanConverter.cs
- ComboBoxRenderer.cs
- WorkflowServiceAttributes.cs
- AutomationPattern.cs
- SmtpSpecifiedPickupDirectoryElement.cs
- XmlQualifiedName.cs
- HostedHttpContext.cs
- WebContext.cs
- GuidTagList.cs
- DbProviderFactoriesConfigurationHandler.cs
- RadioButtonList.cs
- WebPageTraceListener.cs
- OAVariantLib.cs
- printdlgexmarshaler.cs
- EntityProxyFactory.cs
- regiisutil.cs
- QuaternionConverter.cs
- ProviderUtil.cs
- Mutex.cs
- XmlAttribute.cs
- ItemCollection.cs
- ValidatingReaderNodeData.cs
- CodeAttributeArgumentCollection.cs
- XmlSchemaAttributeGroup.cs
- ListManagerBindingsCollection.cs
- Win32Native.cs
- DrawingContext.cs
- OdbcConnectionHandle.cs
- TagMapCollection.cs
- SHA384Cng.cs
- AdCreatedEventArgs.cs
- TcpClientChannel.cs
- ValidatingReaderNodeData.cs
- RSAPKCS1KeyExchangeFormatter.cs
- HwndSource.cs
- TextReader.cs
- RectangleHotSpot.cs
- SQLDouble.cs
- DesignerActionService.cs
- SqlMethodTransformer.cs
- MouseActionConverter.cs
- DataBoundControl.cs
- Registry.cs
- ObjectStateManagerMetadata.cs
- SmtpException.cs
- BigInt.cs
- XsltLibrary.cs
- DataGridTablesFactory.cs
- CacheMemory.cs
- RIPEMD160.cs
- IISMapPath.cs
- TaskForm.cs
- ContentTextAutomationPeer.cs