Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Shapes / path.cs / 1 / path.cs
//---------------------------------------------------------------------------- // File: Path.cs // // Description: // Implementation of Path shape element. // // History: // 05/30/02 - AdSmith - Created. // // Copyright (C) 2003 by Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System.Windows.Shapes; using System.Diagnostics; using System.Windows.Threading; using System.Security; using System.Security.Permissions; using System.Windows; using System.Windows.Media; using System; using MS.Internal.PresentationFramework; namespace System.Windows.Shapes { ////// The Path shape element /// This element (like all shapes) belongs under a Canvas, /// and will be presented by the parent canvas. /// Since a Path is really a path which closes its path /// public sealed class Path : Shape { #region Constructors ////// Instantiates a new instance of a Path. /// public Path() { } #endregion Constructors #region Dynamic Properties ////// Data property /// [CommonDependencyProperty] public static readonly DependencyProperty DataProperty = DependencyProperty.Register( "Data", typeof(Geometry), typeof(Path), new FrameworkPropertyMetadata( null, FrameworkPropertyMetadataOptions.AffectsMeasure | FrameworkPropertyMetadataOptions.AffectsRender), null); ////// Data property /// public Geometry Data { get { return (Geometry)GetValue(DataProperty); } set { SetValue(DataProperty, value); } } #endregion #region Protected Methods and Properties ////// Get the path that defines this shape /// protected override Geometry DefiningGeometry { get { Geometry data = Data; if (data == null) { data = Geometry.Empty; } return data; } } // // This property // 1. Finds the correct initial size for the _effectiveValues store on the current DependencyObject // 2. This is a performance optimization // internal override int EffectiveValuesInitialSize { get { return 13; } } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // File: Path.cs // // Description: // Implementation of Path shape element. // // History: // 05/30/02 - AdSmith - Created. // // Copyright (C) 2003 by Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System.Windows.Shapes; using System.Diagnostics; using System.Windows.Threading; using System.Security; using System.Security.Permissions; using System.Windows; using System.Windows.Media; using System; using MS.Internal.PresentationFramework; namespace System.Windows.Shapes { ////// The Path shape element /// This element (like all shapes) belongs under a Canvas, /// and will be presented by the parent canvas. /// Since a Path is really a path which closes its path /// public sealed class Path : Shape { #region Constructors ////// Instantiates a new instance of a Path. /// public Path() { } #endregion Constructors #region Dynamic Properties ////// Data property /// [CommonDependencyProperty] public static readonly DependencyProperty DataProperty = DependencyProperty.Register( "Data", typeof(Geometry), typeof(Path), new FrameworkPropertyMetadata( null, FrameworkPropertyMetadataOptions.AffectsMeasure | FrameworkPropertyMetadataOptions.AffectsRender), null); ////// Data property /// public Geometry Data { get { return (Geometry)GetValue(DataProperty); } set { SetValue(DataProperty, value); } } #endregion #region Protected Methods and Properties ////// Get the path that defines this shape /// protected override Geometry DefiningGeometry { get { Geometry data = Data; if (data == null) { data = Geometry.Empty; } return data; } } // // This property // 1. Finds the correct initial size for the _effectiveValues store on the current DependencyObject // 2. This is a performance optimization // internal override int EffectiveValuesInitialSize { get { return 13; } } #endregion } } // 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
- XmlArrayItemAttribute.cs
- PrimarySelectionGlyph.cs
- HitTestWithGeometryDrawingContextWalker.cs
- FixedSOMSemanticBox.cs
- IndicCharClassifier.cs
- WebPartHelpVerb.cs
- ZoomingMessageFilter.cs
- ContentPlaceHolder.cs
- EdmType.cs
- CheckBoxAutomationPeer.cs
- DelegatingConfigHost.cs
- DefaultSerializationProviderAttribute.cs
- VirtualDirectoryMappingCollection.cs
- MappedMetaModel.cs
- GACIdentityPermission.cs
- GeneralTransform3DGroup.cs
- XPathBuilder.cs
- LayoutUtils.cs
- WebServiceFaultDesigner.cs
- WinFormsSecurity.cs
- TdsParameterSetter.cs
- DetailsViewCommandEventArgs.cs
- Condition.cs
- DbParameterHelper.cs
- SerializationHelper.cs
- ProfilePropertyMetadata.cs
- FrameworkElementFactoryMarkupObject.cs
- UIElementAutomationPeer.cs
- FileUtil.cs
- PersonalizationDictionary.cs
- WpfKnownTypeInvoker.cs
- OleDbDataReader.cs
- SqlDataSourceQuery.cs
- PopOutPanel.cs
- XsdDateTime.cs
- WindowsGraphicsCacheManager.cs
- SamlSubject.cs
- SQLBinary.cs
- Int16Converter.cs
- ISAPIRuntime.cs
- SecurityContext.cs
- BaseTemplateParser.cs
- RepeaterDesigner.cs
- DateRangeEvent.cs
- MultiTrigger.cs
- VariableQuery.cs
- PathParser.cs
- DataGridViewRowHeightInfoNeededEventArgs.cs
- PermissionToken.cs
- QueryOperationResponseOfT.cs
- CacheMemory.cs
- StylusShape.cs
- Vector.cs
- WebBrowser.cs
- Style.cs
- ErrorFormatter.cs
- AsymmetricAlgorithm.cs
- WorkflowItemPresenter.cs
- CookieProtection.cs
- SurrogateDataContract.cs
- CodeRemoveEventStatement.cs
- UInt64Storage.cs
- Rect3DValueSerializer.cs
- EventToken.cs
- LiteralLink.cs
- PartialCachingAttribute.cs
- WmlTextBoxAdapter.cs
- DataSourceControlBuilder.cs
- PasswordRecovery.cs
- TagNameToTypeMapper.cs
- SchemaCollectionCompiler.cs
- ProcessHost.cs
- FrameworkTemplate.cs
- TextBoxRenderer.cs
- SplitterEvent.cs
- StorageConditionPropertyMapping.cs
- ExpressionSelection.cs
- SqlDataSourceCustomCommandPanel.cs
- ReflectTypeDescriptionProvider.cs
- If.cs
- DataColumn.cs
- DetailsViewModeEventArgs.cs
- CodeExporter.cs
- WebPartDescription.cs
- StickyNote.cs
- PermissionRequestEvidence.cs
- Selector.cs
- BindingContext.cs
- TextBoxBase.cs
- CollectionBuilder.cs
- Trace.cs
- PagerSettings.cs
- DbCommandTree.cs
- AsymmetricAlgorithm.cs
- PointUtil.cs
- _HelperAsyncResults.cs
- ListViewUpdatedEventArgs.cs
- SpecularMaterial.cs
- Menu.cs
- ExecutionEngineException.cs