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
- ComplexTypeEmitter.cs
- HandlerBase.cs
- Material.cs
- HttpStreams.cs
- UserPreference.cs
- ToggleProviderWrapper.cs
- CodeAttachEventStatement.cs
- PageOutputQuality.cs
- cache.cs
- RowUpdatedEventArgs.cs
- PerformanceCounterPermissionEntry.cs
- HierarchicalDataSourceControl.cs
- ChtmlTextBoxAdapter.cs
- PolyLineSegment.cs
- HitTestWithPointDrawingContextWalker.cs
- PackageProperties.cs
- DiagnosticTrace.cs
- TextEditorSpelling.cs
- TimeStampChecker.cs
- AsymmetricKeyExchangeFormatter.cs
- DirectionalLight.cs
- SocketInformation.cs
- BaseParaClient.cs
- MouseGestureValueSerializer.cs
- sqlmetadatafactory.cs
- NavigateEvent.cs
- CircleHotSpot.cs
- Transform3DGroup.cs
- XmlSerializerVersionAttribute.cs
- ObjectDataSource.cs
- PrinterResolution.cs
- WebPartConnection.cs
- ArrangedElementCollection.cs
- ContentElement.cs
- _NativeSSPI.cs
- AxWrapperGen.cs
- ServerValidateEventArgs.cs
- MetadataArtifactLoaderComposite.cs
- WindowsListViewScroll.cs
- DocumentNUp.cs
- Light.cs
- ErrorEventArgs.cs
- WebRequestModulesSection.cs
- PrintDialog.cs
- ObjectTag.cs
- PrivilegeNotHeldException.cs
- QuadraticEase.cs
- HttpModuleAction.cs
- OleStrCAMarshaler.cs
- FileCodeGroup.cs
- WebRequest.cs
- ProcessHostConfigUtils.cs
- StatusBarPanel.cs
- RecognizedPhrase.cs
- SetIterators.cs
- EtwTrace.cs
- CredentialManagerDialog.cs
- DataGridHyperlinkColumn.cs
- XmlSchemaObject.cs
- DelegateInArgument.cs
- DispatcherOperation.cs
- FillErrorEventArgs.cs
- AttachedAnnotation.cs
- PropertyItemInternal.cs
- Properties.cs
- ReferenceEqualityComparer.cs
- WindowsFormsSynchronizationContext.cs
- ImageMapEventArgs.cs
- StackOverflowException.cs
- MimeImporter.cs
- WebPartEditorOkVerb.cs
- DecoderNLS.cs
- LOSFormatter.cs
- CriticalFinalizerObject.cs
- WindowsUserNameCachingSecurityTokenAuthenticator.cs
- DefaultValueConverter.cs
- InvokeProviderWrapper.cs
- TransformConverter.cs
- ComPlusAuthorization.cs
- RefExpr.cs
- DataRecord.cs
- EventEntry.cs
- DefaultMemberAttribute.cs
- CodeTypeParameterCollection.cs
- DataListItem.cs
- WindowsImpersonationContext.cs
- XpsDigitalSignature.cs
- XmlReaderSettings.cs
- ScrollViewerAutomationPeer.cs
- ItemDragEvent.cs
- PrePostDescendentsWalker.cs
- ArrayElementGridEntry.cs
- MimeAnyImporter.cs
- MenuItemStyleCollection.cs
- CssTextWriter.cs
- ConfigurationPermission.cs
- CmsUtils.cs
- Label.cs
- UserThread.cs
- HtmlInputRadioButton.cs