Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Core / CSharp / System / Windows / Media / PathSegmentCollection.cs / 1 / PathSegmentCollection.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // //--------------------------------------------------------------------------- using MS.Internal; using MS.Internal.PresentationCore; using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.Globalization; using System.Reflection; using System.Runtime.InteropServices; using System.ComponentModel.Design.Serialization; using System.Text; using System.Windows; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using System.Windows.Markup; namespace System.Windows.Media { ////// The class definition for PathSegmentCollection /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] public sealed partial class PathSegmentCollection : Animatable, IList, IList{ /// /// Can serialze "this" to a string. /// This is true iff every segment is stroked. /// internal bool CanSerializeToString() { bool canSerialize = true; for (int i=0; i<_collection.Count; i++) { if (!_collection[i].IsStroked) { canSerialize = false; break; } } return canSerialize; } ////// Creates a string representation of this object based on the format string /// and IFormatProvider passed in. /// If the provider is null, the CurrentCulture is used. /// See the documentation for IFormattable for more information. /// ////// A string representation of this object. /// internal string ConvertToString(string format, IFormatProvider provider) { if (_collection.Count == 0) { return String.Empty; } StringBuilder str = new StringBuilder(); char separator = MS.Internal.TokenizerHelper.GetNumericListSeparator(provider); for (int i=0; i<_collection.Count; i++) { str.Append(_collection[i].ConvertToString(format, provider)); } return str.ToString(); } } } // 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. // // //--------------------------------------------------------------------------- using MS.Internal; using MS.Internal.PresentationCore; using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.Globalization; using System.Reflection; using System.Runtime.InteropServices; using System.ComponentModel.Design.Serialization; using System.Text; using System.Windows; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using System.Windows.Markup; namespace System.Windows.Media { ////// The class definition for PathSegmentCollection /// [Localizability(LocalizationCategory.None, Readability = Readability.Unreadable)] public sealed partial class PathSegmentCollection : Animatable, IList, IList{ /// /// Can serialze "this" to a string. /// This is true iff every segment is stroked. /// internal bool CanSerializeToString() { bool canSerialize = true; for (int i=0; i<_collection.Count; i++) { if (!_collection[i].IsStroked) { canSerialize = false; break; } } return canSerialize; } ////// Creates a string representation of this object based on the format string /// and IFormatProvider passed in. /// If the provider is null, the CurrentCulture is used. /// See the documentation for IFormattable for more information. /// ////// A string representation of this object. /// internal string ConvertToString(string format, IFormatProvider provider) { if (_collection.Count == 0) { return String.Empty; } StringBuilder str = new StringBuilder(); char separator = MS.Internal.TokenizerHelper.GetNumericListSeparator(provider); for (int i=0; i<_collection.Count; i++) { str.Append(_collection[i].ConvertToString(format, provider)); } return str.ToString(); } } } // 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
- SymmetricSecurityBindingElement.cs
- DocumentPageHost.cs
- EventSinkActivity.cs
- UnsafeNativeMethods.cs
- SafeRightsManagementSessionHandle.cs
- Tuple.cs
- MarkupCompilePass2.cs
- ResourceExpressionEditor.cs
- CodeComment.cs
- GlyphElement.cs
- ChangePassword.cs
- ToolStripItemTextRenderEventArgs.cs
- AttributeCollection.cs
- DirectoryNotFoundException.cs
- DayRenderEvent.cs
- LoginCancelEventArgs.cs
- WebPartCatalogCloseVerb.cs
- HtmlLink.cs
- GradientBrush.cs
- RtfControlWordInfo.cs
- NameValuePair.cs
- FlatButtonAppearance.cs
- Partitioner.cs
- EditorPartChrome.cs
- SslStream.cs
- XmlSchemaInferenceException.cs
- RestClientProxyHandler.cs
- EntityClientCacheKey.cs
- OrderedDictionary.cs
- AppModelKnownContentFactory.cs
- Visual3DCollection.cs
- OletxResourceManager.cs
- DataRowView.cs
- UntrustedRecipientException.cs
- TextEncodedRawTextWriter.cs
- DetailsViewCommandEventArgs.cs
- SafeCertificateContext.cs
- XmlSchemaSubstitutionGroup.cs
- SimpleTextLine.cs
- HttpResponseHeader.cs
- MemoryFailPoint.cs
- LoadedOrUnloadedOperation.cs
- HMACMD5.cs
- EventSetter.cs
- RadioButtonBaseAdapter.cs
- MediaScriptCommandRoutedEventArgs.cs
- JournalNavigationScope.cs
- XmlSchemas.cs
- EdmItemCollection.OcAssemblyCache.cs
- ScrollBarAutomationPeer.cs
- regiisutil.cs
- RecordManager.cs
- WebSysDisplayNameAttribute.cs
- MD5.cs
- DiagnosticsConfigurationHandler.cs
- HintTextMaxWidthConverter.cs
- BindingsCollection.cs
- TextRunTypographyProperties.cs
- MarkerProperties.cs
- DNS.cs
- SapiGrammar.cs
- ThicknessAnimation.cs
- LocalBuilder.cs
- AlternateViewCollection.cs
- HttpModuleAction.cs
- ScriptingJsonSerializationSection.cs
- RightsManagementEncryptionTransform.cs
- SHA256.cs
- TypeInfo.cs
- mansign.cs
- CachedPathData.cs
- ServiceModelExtensionElement.cs
- BindingSource.cs
- COSERVERINFO.cs
- IImplicitResourceProvider.cs
- StaticDataManager.cs
- Constants.cs
- lengthconverter.cs
- UserNamePasswordServiceCredential.cs
- ListItemCollection.cs
- DataRow.cs
- GeneralTransform2DTo3D.cs
- HorizontalAlignConverter.cs
- followingsibling.cs
- StdValidatorsAndConverters.cs
- DoubleLinkList.cs
- UmAlQuraCalendar.cs
- ForceCopyBuildProvider.cs
- DbParameterCollectionHelper.cs
- SystemIPInterfaceStatistics.cs
- CallContext.cs
- ServerValidateEventArgs.cs
- GregorianCalendar.cs
- SuppressIldasmAttribute.cs
- ISAPIWorkerRequest.cs
- ColorConvertedBitmapExtension.cs
- DetailsViewAutoFormat.cs
- IdentityManager.cs
- FutureFactory.cs
- WebOperationContext.cs