Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Documents / RtfToken.cs / 1305600 / 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
- GlobalizationAssembly.cs
- Filter.cs
- BaseConfigurationRecord.cs
- StyleCollection.cs
- WebCategoryAttribute.cs
- ParserStreamGeometryContext.cs
- IgnoreFileBuildProvider.cs
- DiscoveryServerProtocol.cs
- ProcessHostMapPath.cs
- MatchingStyle.cs
- XpsColorContext.cs
- WebRequestModulesSection.cs
- Environment.cs
- ManifestResourceInfo.cs
- BitmapEffectInputData.cs
- XPathAncestorIterator.cs
- ReachSerializer.cs
- MissingManifestResourceException.cs
- _ContextAwareResult.cs
- RbTree.cs
- XmlObjectSerializerContext.cs
- RoleService.cs
- RichTextBox.cs
- DeadCharTextComposition.cs
- keycontainerpermission.cs
- InputScopeManager.cs
- ComponentCollection.cs
- ConnectionPointCookie.cs
- Imaging.cs
- Triplet.cs
- ParallelForEach.cs
- UnsafeNativeMethods.cs
- UrlPropertyAttribute.cs
- SizeValueSerializer.cs
- InputReport.cs
- ConstraintEnumerator.cs
- StylusTip.cs
- WebPartsSection.cs
- GeneralTransform2DTo3DTo2D.cs
- SizeFConverter.cs
- TreeViewImageIndexConverter.cs
- MouseButtonEventArgs.cs
- DataServices.cs
- NameValueCollection.cs
- DnsEndpointIdentity.cs
- RelationshipEntry.cs
- DifferencingCollection.cs
- MemoryFailPoint.cs
- WebBrowserDocumentCompletedEventHandler.cs
- DrawingCollection.cs
- OdbcHandle.cs
- unitconverter.cs
- MinimizableAttributeTypeConverter.cs
- ImportOptions.cs
- FixedDSBuilder.cs
- XmlDataContract.cs
- Double.cs
- BrushConverter.cs
- ValueTypeFixupInfo.cs
- AttachedPropertyBrowsableAttribute.cs
- BitmapData.cs
- SafeFileMappingHandle.cs
- ToolStripDropTargetManager.cs
- ObjectTag.cs
- CopyCodeAction.cs
- RangeContentEnumerator.cs
- InputReferenceExpression.cs
- ExpressionHelper.cs
- XNodeValidator.cs
- InitializationEventAttribute.cs
- GroupedContextMenuStrip.cs
- ObjectParameterCollection.cs
- TextSelectionProcessor.cs
- SparseMemoryStream.cs
- CodeAttributeDeclaration.cs
- WebControlParameterProxy.cs
- SignedXml.cs
- XmlDomTextWriter.cs
- DesignTimeResourceProviderFactoryAttribute.cs
- Timer.cs
- sqlinternaltransaction.cs
- SqlTriggerAttribute.cs
- NamespaceDecl.cs
- PagedDataSource.cs
- DiscardableAttribute.cs
- Panel.cs
- RtType.cs
- IdnElement.cs
- Ipv6Element.cs
- ItemDragEvent.cs
- CommandDevice.cs
- GridViewRowEventArgs.cs
- SafeNativeMethods.cs
- FrameworkElement.cs
- DataBoundLiteralControl.cs
- ErrorWrapper.cs
- CodeFieldReferenceExpression.cs
- TextSelectionProcessor.cs
- XslCompiledTransform.cs
- XNodeSchemaApplier.cs