Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Documents / RtfFormatStack.cs / 1305600 / RtfFormatStack.cs
//---------------------------------------------------------------------------- // // File: RtfFormatStack.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: Rtf format stack. // //--------------------------------------------------------------------------- using System.Collections; using MS.Internal; // Invariant namespace System.Windows.Documents { ////// RtfFormatStack /// internal class RtfFormatStack : ArrayList { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal RtfFormatStack() : base(20) { } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods internal void Push() { FormatState previousFormatState = Top(); FormatState formatState; formatState = previousFormatState != null ? new FormatState(previousFormatState) : new FormatState(); Add(formatState); } internal void Pop() { Invariant.Assert(Count != 0); if (Count > 0) { RemoveAt(Count - 1); } } internal FormatState Top() { return Count > 0 ? EntryAt(Count - 1) : null; } internal FormatState PrevTop(int fromTop) { int index = Count - 1 - fromTop; if (index < 0 || index >= Count) { return null; } return EntryAt(index); } internal FormatState EntryAt(int index) { return (FormatState)this[index]; } #endregion Internal Methods } } // 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
- PropertyTab.cs
- ImageCreator.cs
- TripleDES.cs
- PublisherIdentityPermission.cs
- ListItemConverter.cs
- TextMarkerSource.cs
- glyphs.cs
- SymbolPair.cs
- sapiproxy.cs
- QilTypeChecker.cs
- CqlLexerHelpers.cs
- FixedDocument.cs
- PackUriHelper.cs
- SafeSerializationManager.cs
- IsolatedStorageFileStream.cs
- NavigationHelper.cs
- LabelAutomationPeer.cs
- ThreadStateException.cs
- HitTestParameters3D.cs
- BoundField.cs
- TextTreeUndoUnit.cs
- CompilerLocalReference.cs
- WorkflowItemsPresenter.cs
- ParseHttpDate.cs
- HttpEncoder.cs
- TextureBrush.cs
- AssertFilter.cs
- AmbientProperties.cs
- GeometryValueSerializer.cs
- UserControl.cs
- DocumentAutomationPeer.cs
- HtmlInputPassword.cs
- HebrewCalendar.cs
- SqlNamer.cs
- DrawingImage.cs
- UnmanagedHandle.cs
- DiagnosticEventProvider.cs
- StartUpEventArgs.cs
- UserControlParser.cs
- HebrewNumber.cs
- ModuleBuilder.cs
- PropertyOverridesTypeEditor.cs
- X509RecipientCertificateClientElement.cs
- OperationCanceledException.cs
- PerformanceCounterScope.cs
- WhitespaceRule.cs
- ProjectionCamera.cs
- SingletonConnectionReader.cs
- ExpressionDumper.cs
- ServiceReference.cs
- StringHelper.cs
- FormatVersion.cs
- HandleCollector.cs
- PresentationUIStyleResources.cs
- XmlDataSource.cs
- StyleModeStack.cs
- CodeTypeReference.cs
- ComponentEditorForm.cs
- Int32Collection.cs
- RenderingEventArgs.cs
- PointKeyFrameCollection.cs
- LayoutUtils.cs
- XmlSchemaSequence.cs
- OperationParameterInfo.cs
- AlgoModule.cs
- SqlRecordBuffer.cs
- SynchronizingStream.cs
- HotSpotCollection.cs
- ColorMatrix.cs
- ExpressionList.cs
- NullableDecimalMinMaxAggregationOperator.cs
- ClientScriptManager.cs
- PropertyDescriptorCollection.cs
- ManualResetEvent.cs
- InfiniteIntConverter.cs
- OleDbErrorCollection.cs
- BaseResourcesBuildProvider.cs
- DataGridViewCellStateChangedEventArgs.cs
- TextBox.cs
- MessageFilterTable.cs
- OracleParameterBinding.cs
- Psha1DerivedKeyGenerator.cs
- StrokeCollectionConverter.cs
- EFColumnProvider.cs
- SettingsAttributes.cs
- oledbmetadatacollectionnames.cs
- DocumentSchemaValidator.cs
- SuppressMergeCheckAttribute.cs
- NameValueCollection.cs
- SemaphoreSecurity.cs
- ActivationArguments.cs
- XappLauncher.cs
- HandlerWithFactory.cs
- EntityType.cs
- DecoderNLS.cs
- StorageConditionPropertyMapping.cs
- AssemblyNameUtility.cs
- ProfileEventArgs.cs
- assertwrapper.cs
- ExpressionBinding.cs