Class: TDocumentTextMenu

Declaration: DocumentTextMenus.h

Taxonomy Categories:

Member Functions:


Interface Category:

API.

Inherits From:

TTextMenu

Inherited By:

None.

Purpose:

Used by the Text Editing Framework to define a set of standard text menus. Text menu objects may be associated with text views, providing an interface to the end user for applying commands on text. This derived class is designed to work with TDocumentTextViews, which interact with text components.

Instantiation:

Allocate on the heap or the stack.

Deriving Classes:

At present, this class is not intended to be derived. In the future, a mechanism will be provided to customize text menus in documents.

Concurrency:

Not multithread safe.

Resource Use:

No special requirements.

Other Considerations:

None.

Member Function: TDocumentTextMenu::TDocumentTextMenu

TDocumentTextMenu (TGUIBundleConnection * theBundleConnectionToAlias)

Interface Category:

API.

Purpose:

Constructs a text menu object for a specified document text view.

Calling Context:

May be called directly by clients

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::~TDocumentTextMenu

virtual ~ TDocumentTextMenu ()

Interface Category:

API.

Purpose:

Destructor.

Calling Context:

Called to destroy an object. Typically not called directly by clients.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::AddTextMenus

virtual void AddTextMenus (TMenu & menu)

Interface Category:

API.

Purpose:

Adds text-related menus to a menu object.

Calling Context:

May be called directly by clients.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::CreateComponentMenu

virtual MMenuItem * CreateComponentMenu ()

Interface Category:

API.

Purpose:

Create a menu containing items related to text components.

Calling Context:

Called by Text Editing Framework. May be called directly by clients.

Parameters:

Return Value:

Pointer to MMenuItem created.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::CreateCommandMenuItem

virtual TMomentaryMenuItem * CreateCommandMenuItem (const TText & itemLabel, TCommandOn < MTextSelection > * command, TTextLabel * adoptCommandLabel =NIL, MMenuItem :: ESeparatorType =MMenuItem :: kNone, bool updateSelection =false)

Interface Category:

API.

Purpose:

Create a menu item associated with a command.

Calling Context:

Typically called by Text Editing Framework. May be called directly by clients.

Parameters:

Return Value:

Pointer to TMomentaryMenuItem object created.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::CreateTextColorMenuItem

virtual TMomentaryMenuItem * CreateTextColorMenuItem (const int colorTableIndex, MMenuItem :: ESeparatorType =MMenuItem :: kNone)

Interface Category:

API.

Purpose:

Creates a menu item representing a color that could be applied to text. This differs from the inherited member function because the command and selection reflect the component's GUIBundle.

Calling Context:

Typically called by Text Editing Framework. May be called directly by clients.

Parameters:

Return Value:

Returns pointer to TMomentaryMenuItem created.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::CreateFillColorMenuItem

virtual TMomentaryMenuItem * CreateFillColorMenuItem (const int colorTableIndex, MMenuItem :: ESeparatorType =MMenuItem :: kNone)

Interface Category:

API.

Purpose:

Creates a menu item representing a color that could be applied to text. This differs from the inherited member function because the command and selection reflect the component's GUIBundle.

Calling Context:

Typically called by Text Editing Framework. May be called directly by clients.

Parameters:

Return Value:

Returns pointer to TMomentaryMenuItem created.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.

Member Function: TDocumentTextMenu::RemoveTextMenus

virtual void RemoveTextMenus (TMenu & menu)

Interface Category:

API.

Purpose:

Removes text-related menus to a menu object.

Calling Context:

Called directly by clients.

Parameters:

Return Value:

None.

Exceptions:

Throws no exceptions, passes all exceptions through.

Concurrency:

Not multithread safe.

Other Considerations:

None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.