Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / WinForms / Managed / System / WinForms / ToolStripItemImageRenderEventArgs.cs / 1 / ToolStripItemImageRenderEventArgs.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System.Drawing; ////// public class ToolStripItemImageRenderEventArgs : ToolStripItemRenderEventArgs { private Image image = null; private Rectangle imageRectangle = Rectangle.Empty; private bool shiftOnPress = false; public ToolStripItemImageRenderEventArgs(Graphics g, ToolStripItem item, Rectangle imageRectangle) : base(g, item) { this.image = (item.RightToLeftAutoMirrorImage && (item.RightToLeft == RightToLeft.Yes)) ? item.MirroredImage : item.Image; this.imageRectangle = imageRectangle; } /// /// /// This class represents all the information to render the winbar /// public ToolStripItemImageRenderEventArgs(Graphics g, ToolStripItem item, Image image, Rectangle imageRectangle) : base(g, item) { this.image = image; this.imageRectangle = imageRectangle; } ////// /// the string to draw /// public Image Image { get { return image; } } ////// /// the rectangle to draw the Image in /// public Rectangle ImageRectangle { get { return imageRectangle; } } // not public as it currently pertains to button & system renderer. internal bool ShiftOnPress { get { return shiftOnPress; } set { shiftOnPress = 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.Drawing; ////// public class ToolStripItemImageRenderEventArgs : ToolStripItemRenderEventArgs { private Image image = null; private Rectangle imageRectangle = Rectangle.Empty; private bool shiftOnPress = false; public ToolStripItemImageRenderEventArgs(Graphics g, ToolStripItem item, Rectangle imageRectangle) : base(g, item) { this.image = (item.RightToLeftAutoMirrorImage && (item.RightToLeft == RightToLeft.Yes)) ? item.MirroredImage : item.Image; this.imageRectangle = imageRectangle; } /// /// /// This class represents all the information to render the winbar /// public ToolStripItemImageRenderEventArgs(Graphics g, ToolStripItem item, Image image, Rectangle imageRectangle) : base(g, item) { this.image = image; this.imageRectangle = imageRectangle; } ////// /// the string to draw /// public Image Image { get { return image; } } ////// /// the rectangle to draw the Image in /// public Rectangle ImageRectangle { get { return imageRectangle; } } // not public as it currently pertains to button & system renderer. internal bool ShiftOnPress { get { return shiftOnPress; } set { shiftOnPress = 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
- AddToCollection.cs
- LocalValueEnumerator.cs
- SafeViewOfFileHandle.cs
- Size.cs
- FunctionNode.cs
- FunctionParameter.cs
- QilFunction.cs
- FloaterParagraph.cs
- RoleManagerEventArgs.cs
- PolyLineSegment.cs
- InkSerializer.cs
- WmpBitmapDecoder.cs
- FontWeight.cs
- DecoderNLS.cs
- CreateUserWizardStep.cs
- TableItemProviderWrapper.cs
- COM2TypeInfoProcessor.cs
- SafeFileHandle.cs
- FormsAuthenticationEventArgs.cs
- AssociationEndMember.cs
- DecoderReplacementFallback.cs
- InvalidPrinterException.cs
- DataGridViewUtilities.cs
- SerializationFieldInfo.cs
- PersonalizationProviderCollection.cs
- Console.cs
- ConsumerConnectionPointCollection.cs
- EntityWithKeyStrategy.cs
- DesignerToolboxInfo.cs
- DynamicEndpoint.cs
- EntryPointNotFoundException.cs
- ScriptRegistrationManager.cs
- OuterGlowBitmapEffect.cs
- ReadOnlyHierarchicalDataSource.cs
- HostAdapter.cs
- AndCondition.cs
- DataControlField.cs
- OrderedDictionary.cs
- ItemMap.cs
- TextBoxRenderer.cs
- UdpDiscoveryEndpointProvider.cs
- FeatureSupport.cs
- SettingsPropertyIsReadOnlyException.cs
- TextComposition.cs
- SmtpSection.cs
- SelectionProcessor.cs
- Random.cs
- Function.cs
- DescendantOverDescendantQuery.cs
- DeferredReference.cs
- PrimitiveSchema.cs
- DecimalAnimationUsingKeyFrames.cs
- UIElementPropertyUndoUnit.cs
- StylusLogic.cs
- Filter.cs
- XmlEncoding.cs
- XmlBindingWorker.cs
- altserialization.cs
- SequenceNumber.cs
- ActionMessageFilterTable.cs
- Missing.cs
- NavigationPropertyEmitter.cs
- Vertex.cs
- AppDomainUnloadedException.cs
- SqlInternalConnectionTds.cs
- KeyConstraint.cs
- QilReference.cs
- SizeAnimationClockResource.cs
- CommandExpr.cs
- FileCodeGroup.cs
- WebConfigurationHost.cs
- GridViewActionList.cs
- Enum.cs
- ScaleTransform.cs
- SocketException.cs
- RangeExpression.cs
- TransformValueSerializer.cs
- UntypedNullExpression.cs
- Base64Encoder.cs
- CellQuery.cs
- PropertyGrid.cs
- StrokeDescriptor.cs
- InstanceDataCollectionCollection.cs
- ExtensionFile.cs
- GridViewDeletedEventArgs.cs
- XPathDocumentBuilder.cs
- PersonalizationState.cs
- TextWriterTraceListener.cs
- XsltInput.cs
- Rule.cs
- XPathPatternParser.cs
- XamlTreeBuilderBamlRecordWriter.cs
- SqlVersion.cs
- Drawing.cs
- XamlLoadErrorInfo.cs
- StrongNameUtility.cs
- RegexBoyerMoore.cs
- PointHitTestResult.cs
- CriticalFinalizerObject.cs
- SchemaNames.cs