Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Framework / MS / Internal / IO / Packaging / fixedPageContentExtractor.cs / 1 / fixedPageContentExtractor.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // Description: // Given a DOM node for a fixed page, enumerates its text content. // // History: // 05/11/2004: [....]: Initial implementation //--------------------------------------------------------------------------- using System; using System.Xml; namespace MS.Internal.IO.Packaging { ////// Implements a sequence of (textContent, precedingDelimiter) pairs for /// a fixed page node. /// internal class FixedPageContentExtractor { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors ////// Initialize a FixedPageContentExtractor from a DOM node. /// internal FixedPageContentExtractor(XmlNode fixedPage) { _fixedPageInfo = new XmlFixedPageInfo(fixedPage); _nextGlyphRun = 0; } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods ////// Return the content of the next glyph run, with a boolean indication /// whether it is separated by a space form the preceding glyph run. /// internal string NextGlyphContent(out bool inline, out uint lcid) { // Right now, we use the simplest possible heuristic for // spacing glyph runs: All pairs of adjacent glyph runs are assumed // to be separated by a word break. inline = false; lcid = 0; // End of page? if (_nextGlyphRun >= _fixedPageInfo.GlyphRunCount) { return null; } // Retrieve inline, lcid and return value from the next glyph run info. GlyphRunInfo glyphRunInfo = _fixedPageInfo.GlyphRunAtPosition(_nextGlyphRun); lcid = glyphRunInfo.LanguageID; // Point to the next glyph run for the next call and return. ++_nextGlyphRun; return glyphRunInfo.UnicodeString; } #endregion Internal Methods //------------------------------------------------------ // // Internal Properties // //------------------------------------------------------ #region Internal Properties ////// Indicates whether no more content can be returned. /// internal bool AtEndOfPage { get { return _nextGlyphRun >= _fixedPageInfo.GlyphRunCount; } } #endregion Internal Properties //----------------------------------------------------- // // Private Fields // //------------------------------------------------------ #region Private Fields private XmlFixedPageInfo _fixedPageInfo; private int _nextGlyphRun; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
![Network programming in C#, Network Programming in VB.NET, Network Programming in .NET](/images/book.jpg)
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- EnumValAlphaComparer.cs
- Label.cs
- _BaseOverlappedAsyncResult.cs
- BitmapEffectrendercontext.cs
- Condition.cs
- DomNameTable.cs
- MenuItemCollectionEditor.cs
- ThreadInterruptedException.cs
- Int16Storage.cs
- MasterPageCodeDomTreeGenerator.cs
- Formatter.cs
- HttpBrowserCapabilitiesWrapper.cs
- StoragePropertyMapping.cs
- RequestResponse.cs
- Page.cs
- xmlfixedPageInfo.cs
- EditorAttributeInfo.cs
- _LocalDataStoreMgr.cs
- XmlSigningNodeWriter.cs
- SQLBinary.cs
- BitmapEffectGeneralTransform.cs
- HashAlgorithm.cs
- ArrayConverter.cs
- Item.cs
- MemberDomainMap.cs
- BrowserCapabilitiesFactory.cs
- RSAPKCS1KeyExchangeDeformatter.cs
- __Error.cs
- ContextMenuStrip.cs
- RegularExpressionValidator.cs
- HtmlImage.cs
- TextEffectCollection.cs
- XmlNodeChangedEventArgs.cs
- SqlCacheDependencyDatabase.cs
- XmlWrappingWriter.cs
- BatchStream.cs
- XMLSchema.cs
- WindowsFormsLinkLabel.cs
- ConversionContext.cs
- RelationshipManager.cs
- ExclusiveCanonicalizationTransform.cs
- UndoEngine.cs
- Attributes.cs
- SplineKeyFrames.cs
- CultureSpecificCharacterBufferRange.cs
- Item.cs
- ReferencedType.cs
- DataMemberAttribute.cs
- ActiveXContainer.cs
- CodeCompileUnit.cs
- XmlWriterDelegator.cs
- XpsSerializerWriter.cs
- DirectoryNotFoundException.cs
- ConfigXmlAttribute.cs
- Utils.cs
- TextEditorCharacters.cs
- ExpandCollapsePattern.cs
- DeflateEmulationStream.cs
- Utils.cs
- ConstraintStruct.cs
- DataTableReaderListener.cs
- EntityReference.cs
- RawStylusInput.cs
- QuaternionAnimationUsingKeyFrames.cs
- XpsS0ValidatingLoader.cs
- Span.cs
- RegisteredHiddenField.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- SqlExpressionNullability.cs
- ParameterRetriever.cs
- StrongNameIdentityPermission.cs
- InputReportEventArgs.cs
- DiscoveryReferences.cs
- UnsignedPublishLicense.cs
- OdbcInfoMessageEvent.cs
- SubordinateTransaction.cs
- IriParsingElement.cs
- DataGridColumnCollection.cs
- AutomationElementCollection.cs
- XmlSchemaInferenceException.cs
- XPathNodeHelper.cs
- WebZone.cs
- DataException.cs
- DateTimeConverter2.cs
- HealthMonitoringSection.cs
- ContentPlaceHolder.cs
- ColorIndependentAnimationStorage.cs
- UpdateTranslator.cs
- DropShadowEffect.cs
- Internal.cs
- SqlDataSourceConfigureSortForm.cs
- BuildManager.cs
- RequiredFieldValidator.cs
- RouteParametersHelper.cs
- BamlWriter.cs
- ArcSegment.cs
- Config.cs
- ISO2022Encoding.cs
- WorkflowServiceNamespace.cs
- ExtractedStateEntry.cs