Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / 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
- ProcessHostServerConfig.cs
- Vector3DAnimationUsingKeyFrames.cs
- AffineTransform3D.cs
- Region.cs
- QilParameter.cs
- PolyQuadraticBezierSegment.cs
- ScrollBar.cs
- TdsParserHelperClasses.cs
- DoneReceivingAsyncResult.cs
- MessageContractMemberAttribute.cs
- DESCryptoServiceProvider.cs
- FontFamilyIdentifier.cs
- DrawingBrush.cs
- RoutedCommand.cs
- DynamicDiscoveryDocument.cs
- UriSection.cs
- Track.cs
- SafeSecurityHelper.cs
- Label.cs
- QilDataSource.cs
- OdbcConnectionPoolProviderInfo.cs
- ImageAutomationPeer.cs
- FixedSOMImage.cs
- SingleObjectCollection.cs
- ObjectDataSourceView.cs
- WebServicesDescriptionAttribute.cs
- HttpListenerPrefixCollection.cs
- QueryPageSettingsEventArgs.cs
- QualificationDataItem.cs
- HttpValueCollection.cs
- TypeNameConverter.cs
- Matrix3DConverter.cs
- DataKeyArray.cs
- SchemaCollectionCompiler.cs
- COM2IPerPropertyBrowsingHandler.cs
- WeakKeyDictionary.cs
- Matrix.cs
- ConnectionPoolManager.cs
- BaseTemplateCodeDomTreeGenerator.cs
- WebPermission.cs
- FormsAuthenticationModule.cs
- TemplatedMailWebEventProvider.cs
- ReflectionPermission.cs
- ConfigViewGenerator.cs
- AppModelKnownContentFactory.cs
- DataGridColumnCollection.cs
- KeyEvent.cs
- SemanticAnalyzer.cs
- PeerToPeerException.cs
- XmlDataSourceNodeDescriptor.cs
- PersonalizableAttribute.cs
- PropertyOverridesDialog.cs
- MarkupExtensionParser.cs
- DataColumnPropertyDescriptor.cs
- NativeCppClassAttribute.cs
- ScrollChangedEventArgs.cs
- RangeContentEnumerator.cs
- ReadOnlyHierarchicalDataSourceView.cs
- MetadataProperty.cs
- BindingElementExtensionElement.cs
- ToolboxComponentsCreatedEventArgs.cs
- Pen.cs
- ScriptDescriptor.cs
- EventlogProvider.cs
- XsltConvert.cs
- ZoneMembershipCondition.cs
- HttpApplication.cs
- isolationinterop.cs
- ElementHost.cs
- Pair.cs
- SizeConverter.cs
- EventListenerClientSide.cs
- ByteStreamGeometryContext.cs
- WebPartHeaderCloseVerb.cs
- Stack.cs
- StreamInfo.cs
- SvcMapFile.cs
- WebConfigurationHostFileChange.cs
- StretchValidation.cs
- LockedHandleGlyph.cs
- RuleSettings.cs
- HiddenFieldPageStatePersister.cs
- XmlQueryTypeFactory.cs
- TextHidden.cs
- DataSourceControl.cs
- LinkUtilities.cs
- CannotUnloadAppDomainException.cs
- EdmProviderManifest.cs
- CompareInfo.cs
- EnumValAlphaComparer.cs
- CheckBoxAutomationPeer.cs
- Accessible.cs
- NavigationEventArgs.cs
- PopupEventArgs.cs
- FixedBufferAttribute.cs
- OdbcInfoMessageEvent.cs
- RelationshipWrapper.cs
- ProfileGroupSettings.cs
- DbTransaction.cs
- RijndaelManaged.cs