Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / TextDecoration.cs / 1305600 / TextDecoration.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // // Description: TextDecoration class // // History: // 10/14/2004: Garyyang Created the file // //--------------------------------------------------------------------------- using System; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Markup; namespace System.Windows { ////// A text decoration /// [Localizability(LocalizationCategory.None)] public sealed partial class TextDecoration : Animatable { ////// Constructor /// public TextDecoration() { } ////// Constructor /// /// The location of the text decoration /// The pen used to draw this text decoration /// The offset of this text decoration to the location /// The unit of the offset /// The unit of the thickness of the pen public TextDecoration( TextDecorationLocation location, Pen pen, double penOffset, TextDecorationUnit penOffsetUnit, TextDecorationUnit penThicknessUnit ) { Location = location; Pen = pen; PenOffset = penOffset; PenOffsetUnit = penOffsetUnit; PenThicknessUnit = penThicknessUnit; } ////// Compare the values of thhe properties in the two TextDecoration objects /// /// The TextDecoration object to be compared against ///True if their property values are equal. 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. /// internal bool ValueEquals(TextDecoration textDecoration) { if (textDecoration == null) return false; // o is either null or not a TextDecoration object. if (this == textDecoration) return true; // reference equality. return ( Location == textDecoration.Location && PenOffset == textDecoration.PenOffset && PenOffsetUnit == textDecoration.PenOffsetUnit && PenThicknessUnit == textDecoration.PenThicknessUnit && (Pen == null ? textDecoration.Pen == null : Pen.Equals( textDecoration.Pen)) ); } } } // 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. // // // // Description: TextDecoration class // // History: // 10/14/2004: Garyyang Created the file // //--------------------------------------------------------------------------- using System; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Markup; namespace System.Windows { ////// A text decoration /// [Localizability(LocalizationCategory.None)] public sealed partial class TextDecoration : Animatable { ////// Constructor /// public TextDecoration() { } ////// Constructor /// /// The location of the text decoration /// The pen used to draw this text decoration /// The offset of this text decoration to the location /// The unit of the offset /// The unit of the thickness of the pen public TextDecoration( TextDecorationLocation location, Pen pen, double penOffset, TextDecorationUnit penOffsetUnit, TextDecorationUnit penThicknessUnit ) { Location = location; Pen = pen; PenOffset = penOffset; PenOffsetUnit = penOffsetUnit; PenThicknessUnit = penThicknessUnit; } ////// Compare the values of thhe properties in the two TextDecoration objects /// /// The TextDecoration object to be compared against ///True if their property values are equal. 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. /// internal bool ValueEquals(TextDecoration textDecoration) { if (textDecoration == null) return false; // o is either null or not a TextDecoration object. if (this == textDecoration) return true; // reference equality. return ( Location == textDecoration.Location && PenOffset == textDecoration.PenOffset && PenOffsetUnit == textDecoration.PenOffsetUnit && PenThicknessUnit == textDecoration.PenThicknessUnit && (Pen == null ? textDecoration.Pen == null : Pen.Equals( textDecoration.Pen)) ); } } } // 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
- UnicodeEncoding.cs
- SqlDependencyListener.cs
- DataGridCheckBoxColumn.cs
- UshortList2.cs
- FontResourceCache.cs
- FrameworkRichTextComposition.cs
- UIHelper.cs
- DebugTrace.cs
- XamlReader.cs
- IntPtr.cs
- DataObjectMethodAttribute.cs
- Int16AnimationBase.cs
- Query.cs
- ToolStripItemClickedEventArgs.cs
- RootProfilePropertySettingsCollection.cs
- ConnectionPointGlyph.cs
- DesignerAttribute.cs
- FreeFormDesigner.cs
- DescendantQuery.cs
- ServerReliableChannelBinder.cs
- MsmqTransportBindingElement.cs
- NgenServicingAttributes.cs
- DataListItemEventArgs.cs
- DataGridViewControlCollection.cs
- Domain.cs
- NativeRecognizer.cs
- DbParameterCollectionHelper.cs
- DataTableMapping.cs
- CollectionDataContract.cs
- ResourceExpression.cs
- SmiContextFactory.cs
- Soap12ProtocolReflector.cs
- WebRequest.cs
- EncryptedKeyIdentifierClause.cs
- PolicyManager.cs
- _OverlappedAsyncResult.cs
- DomainUpDown.cs
- FormViewActionList.cs
- Visitor.cs
- SelectiveScrollingGrid.cs
- RuleEngine.cs
- CodeTypeDeclaration.cs
- ActivityInterfaces.cs
- PropertyFilter.cs
- RequestStatusBarUpdateEventArgs.cs
- BookmarkUndoUnit.cs
- AttributeCollection.cs
- Clock.cs
- TemplateParser.cs
- ListViewAutomationPeer.cs
- ResponseStream.cs
- CodeComment.cs
- Light.cs
- FileSystemInfo.cs
- DiscoveryDocumentSerializer.cs
- ConnectionProviderAttribute.cs
- ContextMenu.cs
- EncoderFallback.cs
- WindowsToolbar.cs
- ResourceDisplayNameAttribute.cs
- FixedSOMPageElement.cs
- WebUtility.cs
- CssClassPropertyAttribute.cs
- Stylesheet.cs
- CodeTypeMemberCollection.cs
- SQLCharsStorage.cs
- ResourceReferenceExpressionConverter.cs
- DtdParser.cs
- StateMachineHistory.cs
- OdbcConnectionHandle.cs
- BufferModesCollection.cs
- Tablet.cs
- MetadataSource.cs
- ApplicationSecurityManager.cs
- DesignerEditorPartChrome.cs
- IApplicationTrustManager.cs
- WbemProvider.cs
- DataControlLinkButton.cs
- DetectRunnableInstancesTask.cs
- ReflectionTypeLoadException.cs
- DataSourceDesigner.cs
- ProgressChangedEventArgs.cs
- GridViewCancelEditEventArgs.cs
- XmlSchemaFacet.cs
- RadialGradientBrush.cs
- InfoCardCryptoHelper.cs
- GcHandle.cs
- ApplicationBuildProvider.cs
- IgnorePropertiesAttribute.cs
- PatternMatcher.cs
- ObjectSet.cs
- RenderDataDrawingContext.cs
- XsdDataContractExporter.cs
- StateBag.cs
- EncodingNLS.cs
- AsyncStreamReader.cs
- SQLBinary.cs
- DataControlImageButton.cs
- UserControlCodeDomTreeGenerator.cs
- SqlBulkCopy.cs