Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / TextDecorationCollection.cs / 1 / TextDecorationCollection.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: TextDecorationCollection class // // History: // 10/14/2004: [....] Created the file // //--------------------------------------------------------------------------- using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.Globalization; using System.Windows.Media.Animation; using System.Windows.Markup; using MS.Internal.PresentationCore; namespace System.Windows { ////// A collection of text decoration instances /// [TypeConverter(typeof(TextDecorationCollectionConverter))] [Localizability(LocalizationCategory.None, Readability=Readability.Unreadable)] public sealed partial class TextDecorationCollection : Animatable, IList { ////// Compare this collection with another TextDecorations. /// /// the text decoration collection to be compared ///true if two collections of TextDecorations contain equal TextDecoration objects in the /// the same order. false otherwise /// ////// The method doesn't check "full" equality as it can not take into account of all the possible /// values associated with the DependencyObject,such as Animation, DataBinding and Attached property. /// It only compares the public properties to serve the specific Framework's needs in inline property /// management and Editing serialization. /// [FriendAccessAllowed] // used by Framework internal bool ValueEquals(TextDecorationCollection textDecorations) { if (textDecorations == null) return false; // o is either null or not TextDecorations object if (this == textDecorations) return true; // Reference equality. if ( this.Count != textDecorations.Count) return false; // Two counts are different. // To be considered equal, TextDecorations should be same in the exact order. // Order matters because they imply the Z-order of the text decorations on screen. // Same set of text decorations drawn with different orders may have different result. for (int i = 0; i < this.Count; i++) { if (!this[i].ValueEquals(textDecorations[i])) return false; } return true; } ////// Add a collection of text decorations into the current collection /// /// The collection to be added [CLSCompliant(false)] public void Add(IEnumerabletextDecorations) { if (textDecorations == null) { throw new ArgumentNullException("textDecorations"); } foreach(TextDecoration textDecoration in textDecorations) { Add(textDecoration); } } } } // 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
- XmlDataProvider.cs
- ResourceManager.cs
- ProxyHwnd.cs
- ObjectDataSourceFilteringEventArgs.cs
- ProxyWebPartConnectionCollection.cs
- ResourceType.cs
- XmlReader.cs
- MemberJoinTreeNode.cs
- DrawingCollection.cs
- _HelperAsyncResults.cs
- PropertyTabChangedEvent.cs
- _ConnectStream.cs
- PageTheme.cs
- CalendarTable.cs
- RequestSecurityTokenForRemoteTokenFactory.cs
- XmlSchemaSet.cs
- DefaultBindingPropertyAttribute.cs
- NonParentingControl.cs
- DataGridViewCellParsingEventArgs.cs
- MULTI_QI.cs
- DataServiceStreamProviderWrapper.cs
- XmlAttributeCollection.cs
- ContractTypeNameCollection.cs
- XmlSerializerFactory.cs
- ToolStripRenderEventArgs.cs
- ListViewCommandEventArgs.cs
- DispatchWrapper.cs
- ComplexLine.cs
- UIPropertyMetadata.cs
- FamilyCollection.cs
- TextEditorThreadLocalStore.cs
- TextElement.cs
- FileSystemInfo.cs
- GroupByQueryOperator.cs
- TargetParameterCountException.cs
- DataGridViewAutoSizeColumnModeEventArgs.cs
- DefaultMemberAttribute.cs
- ByeOperationCD1AsyncResult.cs
- SqlTriggerContext.cs
- ParameterCollection.cs
- CustomValidator.cs
- XPathNodeInfoAtom.cs
- WebBrowser.cs
- GridViewSortEventArgs.cs
- InheritanceContextChangedEventManager.cs
- ServerValidateEventArgs.cs
- CriticalFinalizerObject.cs
- AliasedExpr.cs
- Int16.cs
- GB18030Encoding.cs
- DocumentPaginator.cs
- TextBox.cs
- WebExceptionStatus.cs
- TextSearch.cs
- WhiteSpaceTrimStringConverter.cs
- CompilerScopeManager.cs
- TextEndOfParagraph.cs
- DataGridParentRows.cs
- FileChangesMonitor.cs
- PenLineJoinValidation.cs
- JsonStringDataContract.cs
- TableCell.cs
- HandleCollector.cs
- odbcmetadatacolumnnames.cs
- RootBrowserWindow.cs
- ProfileParameter.cs
- ExpressionServices.cs
- BitmapEffectGroup.cs
- UnauthorizedWebPart.cs
- ValidationEventArgs.cs
- TypeProvider.cs
- XmlQueryOutput.cs
- StandardCommandToolStripMenuItem.cs
- Vector3dCollection.cs
- BitmapEffectDrawing.cs
- InputLanguageCollection.cs
- SequentialUshortCollection.cs
- SuppressIldasmAttribute.cs
- odbcmetadatafactory.cs
- PageThemeParser.cs
- StylusDevice.cs
- DataGridViewColumnEventArgs.cs
- BindingNavigator.cs
- WebBrowserEvent.cs
- GacUtil.cs
- DataViewSetting.cs
- CorrelationRequestContext.cs
- LinqDataSourceDisposeEventArgs.cs
- handlecollector.cs
- CodePageEncoding.cs
- WebRequestModulesSection.cs
- X509ChainPolicy.cs
- TextComposition.cs
- AttributeCollection.cs
- XPathItem.cs
- RenderData.cs
- _DomainName.cs
- ReceiveContent.cs
- DetailsViewModeEventArgs.cs
- M3DUtil.cs