Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Framework / System / Windows / Documents / RtfToken.cs / 1 / RtfToken.cs
//---------------------------------------------------------------------------- // // File: RtfToken.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: Rtf token that will specify the rtf token type, control and name. // //--------------------------------------------------------------------------- namespace System.Windows.Documents { ////// Rtf token that include rtf token type, control, name and parameter value. /// internal class RtfToken { #region Internal Consts //----------------------------------------------------- // // Internal Consts // //----------------------------------------------------- internal const long INVALID_PARAMETER = 0x10000000; #endregion Internal Consts //------------------------------------------------------ // // Constructors // //----------------------------------------------------- #region Constructors ////// /// internal RtfToken() { } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //------------------------------------------------------ #region Internal Methods internal void Empty() { _type = RtfTokenType.TokenInvalid; _rtfControlWordInfo = null; _parameter = INVALID_PARAMETER; _text = ""; } #endregion Internal Methods //----------------------------------------------------- // // Internal Properties // //------------------------------------------------------ #region Internal Properties internal RtfTokenType Type { get { return _type; } set { _type = value; } } internal RtfControlWordInfo RtfControlWordInfo { get { return _rtfControlWordInfo; } set { _rtfControlWordInfo = value; } } internal long Parameter { get { return HasParameter ? _parameter : 0; } set { _parameter = value; } } internal string Text { get { return _text; } set { _text = value; } } internal long ToggleValue { get { return HasParameter ? Parameter : 1; } } internal bool FlagValue { get { return (!HasParameter || (HasParameter && Parameter > 0) ? true : false); } } internal bool HasParameter { get { return _parameter != INVALID_PARAMETER; } } #endregion Internal Properties //----------------------------------------------------- // // Private Fields // //----------------------------------------------------- #region Private Fields private RtfTokenType _type; private RtfControlWordInfo _rtfControlWordInfo; private long _parameter; private string _text; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // File: RtfToken.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: Rtf token that will specify the rtf token type, control and name. // //--------------------------------------------------------------------------- namespace System.Windows.Documents { ////// Rtf token that include rtf token type, control, name and parameter value. /// internal class RtfToken { #region Internal Consts //----------------------------------------------------- // // Internal Consts // //----------------------------------------------------- internal const long INVALID_PARAMETER = 0x10000000; #endregion Internal Consts //------------------------------------------------------ // // Constructors // //----------------------------------------------------- #region Constructors ////// /// internal RtfToken() { } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //------------------------------------------------------ #region Internal Methods internal void Empty() { _type = RtfTokenType.TokenInvalid; _rtfControlWordInfo = null; _parameter = INVALID_PARAMETER; _text = ""; } #endregion Internal Methods //----------------------------------------------------- // // Internal Properties // //------------------------------------------------------ #region Internal Properties internal RtfTokenType Type { get { return _type; } set { _type = value; } } internal RtfControlWordInfo RtfControlWordInfo { get { return _rtfControlWordInfo; } set { _rtfControlWordInfo = value; } } internal long Parameter { get { return HasParameter ? _parameter : 0; } set { _parameter = value; } } internal string Text { get { return _text; } set { _text = value; } } internal long ToggleValue { get { return HasParameter ? Parameter : 1; } } internal bool FlagValue { get { return (!HasParameter || (HasParameter && Parameter > 0) ? true : false); } } internal bool HasParameter { get { return _parameter != INVALID_PARAMETER; } } #endregion Internal Properties //----------------------------------------------------- // // Private Fields // //----------------------------------------------------- #region Private Fields private RtfTokenType _type; private RtfControlWordInfo _rtfControlWordInfo; private long _parameter; private string _text; #endregion Private Fields } } // 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
- HttpClientCertificate.cs
- EmptyStringExpandableObjectConverter.cs
- FixUp.cs
- XmlSchemaAnnotated.cs
- WebPartDisplayModeCancelEventArgs.cs
- MarkedHighlightComponent.cs
- SqlProviderServices.cs
- ImageMapEventArgs.cs
- MenuItemBindingCollection.cs
- PartialCachingAttribute.cs
- UserValidatedEventArgs.cs
- ExtenderProvidedPropertyAttribute.cs
- PageAdapter.cs
- DispatchProxy.cs
- ItemCollection.cs
- DirectoryInfo.cs
- OutputCacheEntry.cs
- Journal.cs
- WasAdminWrapper.cs
- MsmqTransportReceiveParameters.cs
- ComponentDispatcher.cs
- ParallelEnumerableWrapper.cs
- Effect.cs
- DynamicField.cs
- NamespaceListProperty.cs
- ErrorEventArgs.cs
- RoutingService.cs
- MetadataCache.cs
- UserNameSecurityToken.cs
- DataViewListener.cs
- XmlDocumentSerializer.cs
- DispatcherHookEventArgs.cs
- SafeNativeMethods.cs
- ImageMapEventArgs.cs
- Wizard.cs
- HttpServerVarsCollection.cs
- ErasingStroke.cs
- AnonymousIdentificationSection.cs
- DescriptionAttribute.cs
- SqlConnectionStringBuilder.cs
- GreenMethods.cs
- BuildProviderAppliesToAttribute.cs
- ContentElementAutomationPeer.cs
- ProfileBuildProvider.cs
- MetabaseServerConfig.cs
- TagMapCollection.cs
- ClientTarget.cs
- RegisteredArrayDeclaration.cs
- MULTI_QI.cs
- EncoderFallback.cs
- Graphics.cs
- ZipIOBlockManager.cs
- DBSqlParserColumnCollection.cs
- Fonts.cs
- CellConstant.cs
- PathSegmentCollection.cs
- DataGrid.cs
- PageThemeParser.cs
- EncryptedKeyIdentifierClause.cs
- CryptographicAttribute.cs
- SettingsPropertyIsReadOnlyException.cs
- TypeTypeConverter.cs
- MultiSelectRootGridEntry.cs
- ToolStripItemTextRenderEventArgs.cs
- Hyperlink.cs
- CalendarDay.cs
- HtmlInputControl.cs
- ServiceDiscoveryElement.cs
- HierarchicalDataTemplate.cs
- TypeSystem.cs
- ReachFixedPageSerializerAsync.cs
- HttpProcessUtility.cs
- ManipulationDeltaEventArgs.cs
- FieldTemplateFactory.cs
- WindowInteractionStateTracker.cs
- InvokePattern.cs
- ElapsedEventArgs.cs
- IconHelper.cs
- SimpleHandlerFactory.cs
- MaskedTextProvider.cs
- XmlChildNodes.cs
- TransformerInfo.cs
- SoapHelper.cs
- XmlEventCache.cs
- ToolStripItemRenderEventArgs.cs
- InputReferenceExpression.cs
- ModuleBuilder.cs
- DocumentPaginator.cs
- RegexParser.cs
- TreeNode.cs
- HorizontalAlignConverter.cs
- XmlParserContext.cs
- UnsafeNetInfoNativeMethods.cs
- ProcessHostServerConfig.cs
- ConfigurationStrings.cs
- DataGridPagerStyle.cs
- ExpanderAutomationPeer.cs
- IncrementalCompileAnalyzer.cs
- AsynchronousChannel.cs
- VerificationAttribute.cs