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
- ToolStripSplitStackLayout.cs
- MimeMapping.cs
- WebConfigurationHost.cs
- DictionaryEntry.cs
- MatrixKeyFrameCollection.cs
- XamlBrushSerializer.cs
- CapabilitiesAssignment.cs
- OledbConnectionStringbuilder.cs
- AbandonedMutexException.cs
- Timeline.cs
- wmiprovider.cs
- Wildcard.cs
- DataTableMappingCollection.cs
- ToggleButtonAutomationPeer.cs
- ReadOnlyCollectionBase.cs
- LoadedEvent.cs
- UserControl.cs
- CodeParameterDeclarationExpressionCollection.cs
- RSAOAEPKeyExchangeFormatter.cs
- RoutedPropertyChangedEventArgs.cs
- Serializer.cs
- EncryptedXml.cs
- DesignerSerializerAttribute.cs
- RC2.cs
- PasswordPropertyTextAttribute.cs
- ColorContextHelper.cs
- Propagator.JoinPropagator.cs
- DateTime.cs
- BlurBitmapEffect.cs
- LZCodec.cs
- ControlUtil.cs
- XamlWriter.cs
- CodeNamespaceImport.cs
- HtmlCommandAdapter.cs
- SimpleExpression.cs
- Material.cs
- SpeechEvent.cs
- WebServiceMethodData.cs
- ToolStrip.cs
- ExtendedPropertyDescriptor.cs
- SqlDataReaderSmi.cs
- XmlUrlResolver.cs
- httpserverutility.cs
- OleDbPermission.cs
- SqlUtil.cs
- TimeoutConverter.cs
- ExtendedProperty.cs
- URI.cs
- PageCodeDomTreeGenerator.cs
- BamlResourceDeserializer.cs
- BaseAsyncResult.cs
- Marshal.cs
- TraceHandlerErrorFormatter.cs
- DataControlButton.cs
- Model3DCollection.cs
- AutomationTextAttribute.cs
- EditorAttribute.cs
- StructuredType.cs
- LinkAreaEditor.cs
- CodeAccessSecurityEngine.cs
- Floater.cs
- OdbcDataAdapter.cs
- CustomErrorCollection.cs
- Compensation.cs
- LinqDataSourceStatusEventArgs.cs
- AppSettingsReader.cs
- MulticastDelegate.cs
- WebPartConnectionCollection.cs
- OSFeature.cs
- RC2CryptoServiceProvider.cs
- PixelShader.cs
- SingleObjectCollection.cs
- CssTextWriter.cs
- DataKeyArray.cs
- PolyQuadraticBezierSegment.cs
- ProfileEventArgs.cs
- DelegateSerializationHolder.cs
- LocatorPartList.cs
- PasswordBoxAutomationPeer.cs
- PolyQuadraticBezierSegment.cs
- ComponentRenameEvent.cs
- ItemMap.cs
- OptimizerPatterns.cs
- WindowsTreeView.cs
- ListParaClient.cs
- AuthenticationConfig.cs
- TdsEnums.cs
- KeyboardEventArgs.cs
- KeyboardNavigation.cs
- HttpContext.cs
- MenuDesigner.cs
- IpcChannelHelper.cs
- NameTable.cs
- CalendarData.cs
- Control.cs
- RedirectionProxy.cs
- Rect.cs
- SqlConnectionFactory.cs
- VisualStateGroup.cs
- BuilderPropertyEntry.cs