Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / wpf / src / Core / CSharp / System / Windows / Media / textformatting / TextEndOfLine.cs / 1 / TextEndOfLine.cs
//------------------------------------------------------------------------ // // Microsoft Windows Client Platform // Copyright (C) Microsoft Corporation // // File: TextEndOfLine.cs // // Contents: Implementation of text linebreak control // // Spec: http://team/sites/Avalon/Specs/Text%20Formatting%20API.doc // // Created: 1-2-2004 Worachai Chaoweeraprasit (wchao) // //----------------------------------------------------------------------- using System; using System.Collections; using System.Windows; using SR=MS.Internal.PresentationCore.SR; using SRID=MS.Internal.PresentationCore.SRID; namespace System.Windows.Media.TextFormatting { ////// Specialized text run used to mark the end of a line /// public class TextEndOfLine : TextRun { private int _length; private TextRunProperties _textRunProperties; #region Constructors ////// Construct a linebreak run /// /// number of characters public TextEndOfLine(int length) : this(length, null) {} ////// Construct a linebreak run /// /// number of characters /// linebreak text run properties public TextEndOfLine( int length, TextRunProperties textRunProperties ) { if (length <= 0) throw new ArgumentOutOfRangeException("length", SR.Get(SRID.ParameterMustBeGreaterThanZero)); if (textRunProperties != null && textRunProperties.Typeface == null) throw new ArgumentNullException("textRunProperties.Typeface"); _length = length; _textRunProperties = textRunProperties; } #endregion ////// Reference to character buffer /// public sealed override CharacterBufferReference CharacterBufferReference { get { return new CharacterBufferReference(); } } ////// Character length /// public sealed override int Length { get { return _length; } } ////// A set of properties shared by every characters in the run /// public sealed override TextRunProperties Properties { get { return _textRunProperties; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------ // // Microsoft Windows Client Platform // Copyright (C) Microsoft Corporation // // File: TextEndOfLine.cs // // Contents: Implementation of text linebreak control // // Spec: http://team/sites/Avalon/Specs/Text%20Formatting%20API.doc // // Created: 1-2-2004 Worachai Chaoweeraprasit (wchao) // //----------------------------------------------------------------------- using System; using System.Collections; using System.Windows; using SR=MS.Internal.PresentationCore.SR; using SRID=MS.Internal.PresentationCore.SRID; namespace System.Windows.Media.TextFormatting { ////// Specialized text run used to mark the end of a line /// public class TextEndOfLine : TextRun { private int _length; private TextRunProperties _textRunProperties; #region Constructors ////// Construct a linebreak run /// /// number of characters public TextEndOfLine(int length) : this(length, null) {} ////// Construct a linebreak run /// /// number of characters /// linebreak text run properties public TextEndOfLine( int length, TextRunProperties textRunProperties ) { if (length <= 0) throw new ArgumentOutOfRangeException("length", SR.Get(SRID.ParameterMustBeGreaterThanZero)); if (textRunProperties != null && textRunProperties.Typeface == null) throw new ArgumentNullException("textRunProperties.Typeface"); _length = length; _textRunProperties = textRunProperties; } #endregion ////// Reference to character buffer /// public sealed override CharacterBufferReference CharacterBufferReference { get { return new CharacterBufferReference(); } } ////// Character length /// public sealed override int Length { get { return _length; } } ////// A set of properties shared by every characters in the run /// public sealed override TextRunProperties Properties { get { return _textRunProperties; } } } } // 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
- ContentTextAutomationPeer.cs
- DelegateTypeInfo.cs
- EncryptedData.cs
- SystemColors.cs
- SerializationException.cs
- KeyEvent.cs
- FileUtil.cs
- XsltSettings.cs
- SHA512Cng.cs
- WmfPlaceableFileHeader.cs
- FormViewPageEventArgs.cs
- ReliableSession.cs
- ListView.cs
- InstancePersistenceException.cs
- InstanceDataCollectionCollection.cs
- _ConnectStream.cs
- PlatformNotSupportedException.cs
- PopOutPanel.cs
- InstanceView.cs
- SecureConversationVersion.cs
- WebPartEditorOkVerb.cs
- InputScope.cs
- EntityClassGenerator.cs
- DbModificationClause.cs
- TypeUnloadedException.cs
- WebEvents.cs
- TimeManager.cs
- CompressionTransform.cs
- RootAction.cs
- HybridCollection.cs
- COAUTHIDENTITY.cs
- LocalsItemDescription.cs
- DataGridViewRowsAddedEventArgs.cs
- EnvelopedSignatureTransform.cs
- SchemaMapping.cs
- mansign.cs
- IxmlLineInfo.cs
- ChannelSinkStacks.cs
- GridViewUpdateEventArgs.cs
- TableChangeProcessor.cs
- DSGeneratorProblem.cs
- Collection.cs
- CodeIdentifier.cs
- DataServiceQueryException.cs
- CommandEventArgs.cs
- ShowExpandedMultiValueConverter.cs
- TreeViewImageIndexConverter.cs
- AssemblyBuilder.cs
- ExtentCqlBlock.cs
- DataGridViewHeaderCell.cs
- ReservationNotFoundException.cs
- QilUnary.cs
- PasswordDeriveBytes.cs
- HierarchicalDataSourceIDConverter.cs
- WebServiceBindingAttribute.cs
- SizeAnimation.cs
- ReadOnlyDictionary.cs
- FixedSOMTextRun.cs
- MetadataArtifactLoaderComposite.cs
- CompilerScopeManager.cs
- CRYPTPROTECT_PROMPTSTRUCT.cs
- Annotation.cs
- TransformGroup.cs
- TextReader.cs
- PropertyInfoSet.cs
- SelectionUIService.cs
- CheckBoxBaseAdapter.cs
- COM2IProvidePropertyBuilderHandler.cs
- CompModSwitches.cs
- DrawingBrush.cs
- ProxyAttribute.cs
- DefaultPropertiesToSend.cs
- ContentTypeSettingDispatchMessageFormatter.cs
- TimeoutValidationAttribute.cs
- Interlocked.cs
- VectorAnimation.cs
- TextServicesHost.cs
- HtmlEncodedRawTextWriter.cs
- SpotLight.cs
- ServiceHost.cs
- TrackingMemoryStreamFactory.cs
- WSSecurityPolicy12.cs
- GraphicsPath.cs
- UIElementIsland.cs
- OutKeywords.cs
- SymmetricKey.cs
- AssemblyCollection.cs
- MetadataFile.cs
- ScrollViewer.cs
- IResourceProvider.cs
- _DomainName.cs
- PixelFormat.cs
- TypeReference.cs
- EpmContentDeSerializerBase.cs
- XamlGridLengthSerializer.cs
- DaylightTime.cs
- ViewValidator.cs
- ValidationResult.cs
- Baml6ConstructorInfo.cs
- DefinitionBase.cs