Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / Media / DrawingBrush.cs / 1305600 / DrawingBrush.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // // File: DrawingBrush.cs // // Description: This file contains the implementation of DrawingBrush. // The DrawingBrush is a TileBrush which defines its tile content // by use of a Drawing. // // History: // 2003/07/17 : [....] - Created it. // 2003/07/28 : [....] - Renamed it and hooked it up to the unmanaged code. // //--------------------------------------------------------------------------- using MS.Internal; using System; using System.ComponentModel; using System.Diagnostics; using System.Runtime.InteropServices; using System.Windows; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; namespace System.Windows.Media { ////// DrawingBrush - This TileBrush defines its content as a Drawing /// public sealed partial class DrawingBrush : TileBrush { #region Constructors ////// Default constructor for DrawingBrush. The resulting Brush has no content. /// public DrawingBrush() { } ////// DrawingBrush Constructor where the image is set to the parameter's value /// /// The Drawing representing the contents of this Brush. public DrawingBrush(Drawing drawing) { Drawing = drawing; } #endregion Constructors ////// Obtains the current bounds of the brush's content /// /// Output bounds of content protected override void GetContentBounds(out Rect contentBounds) { contentBounds = Drawing.GetBounds(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // // File: DrawingBrush.cs // // Description: This file contains the implementation of DrawingBrush. // The DrawingBrush is a TileBrush which defines its tile content // by use of a Drawing. // // History: // 2003/07/17 : [....] - Created it. // 2003/07/28 : [....] - Renamed it and hooked it up to the unmanaged code. // //--------------------------------------------------------------------------- using MS.Internal; using System; using System.ComponentModel; using System.Diagnostics; using System.Runtime.InteropServices; using System.Windows; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; namespace System.Windows.Media { ////// DrawingBrush - This TileBrush defines its content as a Drawing /// public sealed partial class DrawingBrush : TileBrush { #region Constructors ////// Default constructor for DrawingBrush. The resulting Brush has no content. /// public DrawingBrush() { } ////// DrawingBrush Constructor where the image is set to the parameter's value /// /// The Drawing representing the contents of this Brush. public DrawingBrush(Drawing drawing) { Drawing = drawing; } #endregion Constructors ////// Obtains the current bounds of the brush's content /// /// Output bounds of content protected override void GetContentBounds(out Rect contentBounds) { contentBounds = Drawing.GetBounds(); } } } // 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
- ImmutablePropertyDescriptorGridEntry.cs
- GradientStop.cs
- ScriptReferenceEventArgs.cs
- ExpressionBindingCollection.cs
- TiffBitmapEncoder.cs
- XDeferredAxisSource.cs
- ThemeDictionaryExtension.cs
- XsltSettings.cs
- MetadataItem.cs
- OutputScopeManager.cs
- DirectoryNotFoundException.cs
- NetCodeGroup.cs
- ItemCheckedEvent.cs
- Point3DAnimationBase.cs
- DrawingImage.cs
- UrlMappingCollection.cs
- UseAttributeSetsAction.cs
- PropertyItemInternal.cs
- ToolstripProfessionalRenderer.cs
- StoreAnnotationsMap.cs
- WebPartConnectionsDisconnectVerb.cs
- ObjectStorage.cs
- UrlMappingsModule.cs
- ThemeableAttribute.cs
- WbemProvider.cs
- MouseGestureValueSerializer.cs
- OutputBuffer.cs
- ControlIdConverter.cs
- XmlExceptionHelper.cs
- HttpInputStream.cs
- Msec.cs
- FocusChangedEventArgs.cs
- EndpointDiscoveryBehavior.cs
- ExternalCalls.cs
- DataGridViewColumnConverter.cs
- complextypematerializer.cs
- RadialGradientBrush.cs
- UIElementCollection.cs
- parserscommon.cs
- MsmqPoisonMessageException.cs
- DefaultObjectMappingItemCollection.cs
- PerformanceCounterPermission.cs
- Sentence.cs
- DataGridViewRowPrePaintEventArgs.cs
- BindingsCollection.cs
- SystemIcmpV4Statistics.cs
- ServiceChannel.cs
- _AutoWebProxyScriptHelper.cs
- CodeDomComponentSerializationService.cs
- XmlTextWriter.cs
- AnnotationDocumentPaginator.cs
- RawStylusInputCustomDataList.cs
- XmlElementCollection.cs
- _CommandStream.cs
- WindowsButton.cs
- ColorAnimationUsingKeyFrames.cs
- TextModifierScope.cs
- AttributeProviderAttribute.cs
- XmlEntityReference.cs
- DefaultEventAttribute.cs
- PtsHost.cs
- Validator.cs
- ISAPIApplicationHost.cs
- TaskFactory.cs
- PageThemeParser.cs
- BoolExpression.cs
- RNGCryptoServiceProvider.cs
- ModelTreeManager.cs
- XmlRootAttribute.cs
- Latin1Encoding.cs
- Descriptor.cs
- EditorResources.cs
- CodeDelegateInvokeExpression.cs
- EntityDataSourceContainerNameItem.cs
- DebugTraceHelper.cs
- WrapperSecurityCommunicationObject.cs
- ExpressionPrefixAttribute.cs
- EmulateRecognizeCompletedEventArgs.cs
- TypeLoader.cs
- ToolStripPanelDesigner.cs
- ProcessRequestArgs.cs
- PasswordValidationException.cs
- ServiceContractListItem.cs
- Root.cs
- PageThemeBuildProvider.cs
- Invariant.cs
- WmlControlAdapter.cs
- SqlDataSourceCommandEventArgs.cs
- BackgroundWorker.cs
- DataGridRow.cs
- RTLAwareMessageBox.cs
- EntityDataSourceEntityTypeFilterConverter.cs
- TextBoxLine.cs
- TrustManagerMoreInformation.cs
- Effect.cs
- ExpressionVisitor.cs
- VariableQuery.cs
- RuntimeHelpers.cs
- InputLangChangeEvent.cs
- TextWriterTraceListener.cs