Library | File

Class uifcMenuPane

# include <uifcMenuPane.h>

class uifcMenuPane
 : public virtual uifcComponent
{
    xaideclare(uifcMenuPane)
    ...
};



Description





Method Summary

voidAddActionListener (uifcMenuPaneListener_ptr listener)
 
xboolCanRedraw ()
 
xboolCanWrap ()
 
voidCreateTimer (uifcMenuPaneTimer_ptr timer, xrstring timerName, xbool writeInTrail)
 
voidDeleteChild (xrstring name)
 
xboolDoesAutoClose ()
 
xboolDoesFocusOnDisplay ()
 
xboolDoesReplayDismissEvent ()
 
uifcKey_ptrGetAcceleratorKey ()
 
xstringGetAcceleratorText ()
 
xintGetContentArrangement ()
 
uifcDimension_ptrGetFrameMinimumSize ()
 
uifcPoint_ptrGetFrameOrigin ()
 
uifcRectangle_ptrGetFrameRectangle ()
 
uifcDimension_ptrGetFrameSize ()
 
xintGetHeight ()
 
xstringGetHelpText ()
 
xstringGetOwnerName ()
 
uifcRectangle_ptrGetRectangleOfMonitor ()
 
xintGetRows ()
 
uifcPoint_ptrGetScreenOrigin ()
 
uifcRectangle_ptrGetScreenRectangle ()
 
uifcRichTextGetTextFormat ()
 
xstringGetTitleImage ()
 
xstringGetTitleText ()
 
xintGetWidth ()
 
xboolHasBorder ()
 
xboolHasDropShadow ()
 
xboolHasScrollBarsWhenNeeded ()
 
xintInsertChild (uifcComponent_ptr component)
 
xboolIsVisibleInMenuBar ()
 
voidOpenPopup ()
 
voidPushAction (uifcMenuPaneAction action)
 
voidSetAcceleratorKey (uifcKey_ptr key)
 
voidSetAutoClose (xbool flag)
 
voidSetCanRedraw (xbool flag)
 
voidSetCanWrap (xbool flag)
 
voidSetContentArrangement (xint value)
 
voidSetFocusOnDisplay (xbool flag)
 
voidSetFrameOrigin (uifcPoint_ptr value)
 
voidSetFrameRectangle (uifcRectangle_ptr rect)
 
voidSetFrameSize (uifcDimension_ptr value)
 
voidSetHasBorder (xbool flag)
 
voidSetHasDropShadow (xbool flag)
 
voidSetHasScrollBarsWhenNeeded (xbool flag)
 
voidSetHeight (xint value)
 
voidSetHelpText (xrstring value)
 
voidSetOwnerName (xrstring value)
 
voidSetReplayDismissEvent (xbool flag)
 
voidSetRows (xint value)
 
voidSetTextFormat (uifcRichText value)
 
voidSetTitleImage (xrstring value)
 
voidSetTitleText (xrstring value)
 
voidSetVisibleInMenuBar (xbool flag)
 
voidSetWidth (xint value)
 
voidStartTimer (xrstring timerName, xint duration)
 
voidStopTimer (xrstring timerName)
 


Methods Inherited from Class uifcComponent:

GetDialog, GetComponent, CreateInParent, AddPopupMenu, IsVisible, SetVisible, GetComponentClass, GetComponentClassName, IsAlwaysAtFront, SetAlwaysAtFront, GetBackgroundColor, SetBackgroundColor, IsAttachedAtBottom, SetAttachedAtBottom, GetBottomOffset, SetBottomOffset, GetCursorImage, SetCursorImage, GetTextColor, SetTextColor, GetHelpTextAlignment, SetHelpTextAlignment, GetHelpTextWidth, SetHelpTextWidth, GetHelpTextOriginX, SetHelpTextOriginX, GetHelpTextOriginY, SetHelpTextOriginY, CanInheritPopupMenu, SetCanInheritPopupMenu, IsAttachedAtLeft, SetAttachedAtLeft, GetLeftOffset, SetLeftOffset, DoesReserveSpace, SetReserveSpace, GetParentName, GetPopupMenuName, SetPopupMenuName, CanPopupMenuWhenDisabled, SetCanPopupMenuWhenDisabled, IsAttachedAtRight, SetAttachedAtRight, GetRightOffset, SetRightOffset, IsAttachedAtTop, SetAttachedAtTop, GetTopOffset, SetTopOffset, IsValidDropSite, SetValidDropSite, GetValidDropTypeFlags, SetValidDropTypeFlags, GetChildNameArray, DoesAllowTrailRecording, SetAllowTrailRecording, CanReduceHeight, SetCanReduceHeight, CanReduceWidth, SetCanReduceWidth



Method Detail

voidOpenPopup ()

 

Display the MenuPane as a popup menu.
Returns:



uifcPoint_ptrGetFrameOrigin ()

 

Determine the position of the component, in pixels, relative to its parent.
Returns:



uifcPoint_ptrGetScreenOrigin ()

 

Determine the screen position of the component, in pixels.
Returns:



voidSetFrameOrigin (uifcPoint_ptr value)

 

Set the screen position of the MenuPane, in pixels.
Parameters:
value
Returns:



xintInsertChild (uifcComponent_ptr component)

 


Parameters:
component
Returns:



uifcDimension_ptrGetFrameMinimumSize ()

 

Determine the minimum size of the component, in pixels.
Returns:



voidSetFrameSize (uifcDimension_ptr value)

 

Set the size of the MenuPane, in pixels.
Parameters:
value
Returns:



uifcRectangle_ptrGetScreenRectangle ()

 

Determine the size and screen position of the component, in pixels.
Returns:



uifcRectangle_ptrGetRectangleOfMonitor ()

 

Determine the rectangle of the screen upon which the majority of the given component is displayed.
Returns:



voidSetFrameRectangle (uifcRectangle_ptr rect)

 

Set the size and screen position of the MenuPane, in pixels.
Parameters:
rect
Returns:



voidDeleteChild (xrstring name)

 

Delete a component from the parent.
Parameters:
name
Returns:



uifcDimension_ptrGetFrameSize ()

 

Determine the size of the component, in pixels.
Returns:



uifcRectangle_ptrGetFrameRectangle ()

 

Determine the size and position of the component, in pixels.
Returns:



xboolDoesFocusOnDisplay ()

 
Returns:
Flag indicating whether the MenuPane should automatically take the focus when it appears on the screen (xtrue), or not (xfalse).



voidSetFocusOnDisplay (xbool flag)

 

Sets flag indicating whether the MenuPane should automatically take the focus when it appears on the screen (xtrue), or not (xfalse).
Parameters:
flag
Returns:



xboolHasDropShadow ()

 
Returns:
Flag indicating whether the MenuPane displays a drop-shadow around the bottom and right-hand edges of the window, if permitted to do so by the current OS window manager settings.



voidSetHasDropShadow (xbool flag)

 

Sets flag indicating whether the MenuPane displays a drop-shadow around the bottom and right-hand edges of the window, if permitted to do so by the current OS window manager settings.
Parameters:
flag
Returns:



xintGetWidth ()

 
Returns:
The width in pixels for the menu that the menu should ideally use. This value will be used as long as it is larger than the default menu width.



voidSetWidth (xint value)

 

Sets the width in pixels for the menu that the menu should ideally use. This value will be used as long as it is larger than the default menu width.
Parameters:
value
Returns:



xintGetRows ()

 
Returns:
The number of visible rows of the MenuPane.



voidSetRows (xint value)

 

Sets the number of visible rows of the MenuPane.
Parameters:
value
Returns:



xboolHasScrollBarsWhenNeeded ()

 
Returns:
Flag indicating whether scrollbars should only be displayed when they are required (xtrue) or whether they should always be displayed (xfalse).



voidSetHasScrollBarsWhenNeeded (xbool flag)

 

Sets flag indicating whether scrollbars should only be displayed when they are required (xtrue) or whether they should always be displayed (xfalse).
Parameters:
flag
Returns:



uifcKey_ptrGetAcceleratorKey ()

 
Returns:
The accelerator key which, when pressed, will display the MenuPane when it is used as a popup menu.



voidSetAcceleratorKey (uifcKey_ptr key)

 

Sets the accelerator key which, when pressed, will display the MenuPane when it is used as a popup menu.
Parameters:
key
Returns:



xstringGetTitleImage ()

 
Returns:
The image of the MenuPane, used only by the MenuBar to generate the necessary display information for the corresponding MenuBar item.
This may be a BIF (the .bif extension is optional) file or a JPG, PNG, PCX, GIF, BMP, ICO or CUR file.



voidSetTitleImage (xrstring value)

 

Sets the image of the MenuPane, used only by the MenuBar to generate the necessary display information for the corresponding MenuBar item.
This may be a BIF (the .bif extension is optional) file or a JPG, PNG, PCX, GIF, BMP, ICO or CUR file.
Parameters:
value
Returns:



xboolCanWrap ()

 
Returns:
Flag indicating whether the MenuPane should attempt to wrap its children into multiple columns (xtrue) when the MenuPane is longer than the height of the screen upon which the MenuPane is to be displayed, or whether the MenuPane should display scroll buttons to allow the contents to be viewed (xfalse).



voidSetCanWrap (xbool flag)

 

Sets flag indicating whether the MenuPane should attempt to wrap its children into multiple columns (xtrue) when the MenuPane is longer than the height of the screen upon which the MenuPane is to be displayed, or whether the MenuPane should display scroll buttons to allow the contents to be viewed (xfalse).
Parameters:
flag
Returns:



xboolDoesReplayDismissEvent ()

 
Returns:
Flag indicating whether the MenuPane should replay a mouse event which occured outside the component, causing the MenuPane to be dismissed. The mouse event is replayed to the component beneath the cursor, where it would otherwise have been sent, originally.



voidSetReplayDismissEvent (xbool flag)

 

Sets flag indicating whether the MenuPane should replay a mouse event which occured outside the component, causing the MenuPane to be dismissed. The mouse event is replayed to the component beneath the cursor, where it would otherwise have been sent, originally.
Parameters:
flag
Returns:



uifcRichTextGetTextFormat ()

 
Returns:
The format of the display text of the component.

RICHTEXT_OFF Plain text
RICHTEXT_ON A very restricted subset of HTML
RICHTEXT_ON + <HTML> HTML as supported by the HTMLWindow

The UI RichText format supports the following styles, controlled by their corresponding tokens:

Style Switch on Switch off
Bold \b \b0
Italic \i \i0
Underlined \ul \ulnone
Strike-through \strike \strike0
Superscript \super \nosupersub
Subscript \sub \nosupersub
Foreground Color \cfRRGGBB \cf0
Background Color \cbRRGGBB \cb0
Picture \pictNAME n/a

N.B. Each token must be followed immediately by another token or a whitespace character (e.g. space, newline).
The very restricted subset of HTML supports the following styles, controlled by their corresponding tokens:

Style Switch on Switch off
Bold <b> </b>
Italic <i> </i>
Underlined <u> </u>
Strike-through <strike> </strike>
Superscript <sup> </sup>
Subscript <sub> </sub>
Foreground Color <font color=#RRGGBB> </font>
Background Color <span style="background:#RRGGBB"> </span>
Picture <img src="NAME"> n/a



voidSetTextFormat (uifcRichText value)

 

Sets the format of the display text of the component.

RICHTEXT_OFF Plain text
RICHTEXT_ON A very restricted subset of HTML
RICHTEXT_ON + <HTML> HTML as supported by the HTMLWindow

The UI RichText format supports the following styles, controlled by their corresponding tokens:

Style Switch on Switch off
Bold \b \b0
Italic \i \i0
Underlined \ul \ulnone
Strike-through \strike \strike0
Superscript \super \nosupersub
Subscript \sub \nosupersub
Foreground Color \cfRRGGBB \cf0
Background Color \cbRRGGBB \cb0
Picture \pictNAME n/a

N.B. Each token must be followed immediately by another token or a whitespace character (e.g. space, newline).
The very restricted subset of HTML supports the following styles, controlled by their corresponding tokens:

Style Switch on Switch off
Bold <b> </b>
Italic <i> </i>
Underlined <u> </u>
Strike-through <strike> </strike>
Superscript <sup> </sup>
Subscript <sub> </sub>
Foreground Color <font color=#RRGGBB> </font>
Background Color <span style="background:#RRGGBB"> </span>
Picture <img src="NAME"> n/a

Parameters:
value
Returns:



xintGetContentArrangement ()

 
Returns:
The alignment of the image and label of the MenuPane when the MenuPane is a child of a MenuBar.
This is made up of between 1 and 4 digits which represent the relative locations of the image and label.
The first digit is the image alignment within the bounds of the MenuBar button:

1 2 3
4 5 6
7 8 9

The second digit is optional and is the label alignment within the bounds of the MenuBar button, using the same scheme as above. If no digit is specified then the label alignment is assumed to be the same as the image alignment.
The third digit is also optional and is the relative position of the image and the label if the first 2 digits are equal. If no digit is specified then the relative position is assumed to be 1.

1 The image to the left of the label
2 The image to the right of the label
3 The image above the label
4 The image below the label

The fourth digit is also optional and is a flag representing whether how the image and label should be displayed. If no digit is specified then then fourth digit is assumed to be 1.

1 Display both the image and label
2 Display only the image
3 Display only the label



voidSetContentArrangement (xint value)

 

Sets the alignment of the image and label of the MenuPane when the MenuPane is a child of a MenuBar.
This is made up of between 1 and 4 digits which represent the relative locations of the image and label.
The first digit is the image alignment within the bounds of the MenuBar button:

1 2 3
4 5 6
7 8 9

The second digit is optional and is the label alignment within the bounds of the MenuBar button, using the same scheme as above. If no digit is specified then the label alignment is assumed to be the same as the image alignment.
The third digit is also optional and is the relative position of the image and the label if the first 2 digits are equal. If no digit is specified then the relative position is assumed to be 1.

1 The image to the left of the label
2 The image to the right of the label
3 The image above the label
4 The image below the label

The fourth digit is also optional and is a flag representing whether how the image and label should be displayed. If no digit is specified then then fourth digit is assumed to be 1.

1 Display both the image and label
2 Display only the image
3 Display only the label

Parameters:
value
Returns:



xboolIsVisibleInMenuBar ()

 
Returns:
If the MenuPane is parented by a MenuBar then this attribute is a flag indicating whether the MenuPane should be visible in the MenuBar.



voidSetVisibleInMenuBar (xbool flag)

 

Sets if the MenuPane is parented by a MenuBar then this attribute is a flag indicating whether the MenuPane should be visible in the MenuBar.
Parameters:
flag
Returns:



xboolCanRedraw ()

 
Returns:
Flag indicating whether redraws are permitted in the MenuPane.



voidSetCanRedraw (xbool flag)

 

Sets flag indicating whether redraws are permitted in the MenuPane.
Parameters:
flag
Returns:



xstringGetHelpText ()

 
Returns:
The popup help-text to be displayed whilst the pointer is over the component.
If the value begins with <HTML> then the help-text is treated as HTML, and rendered accordingly. It is often wise to use HTML help-text in conjunction with HelpTextWidth attribute, to define the maximum width of the popup help-text window.



voidSetHelpText (xrstring value)

 

Sets the popup help-text to be displayed whilst the pointer is over the component.
If the value begins with <HTML> then the help-text is treated as HTML, and rendered accordingly. It is often wise to use HTML help-text in conjunction with HelpTextWidth attribute, to define the maximum width of the popup help-text window.
Parameters:
value
Returns:



xstringGetTitleText ()

 
Returns:
The label of the MenuPane, used only by the MenuBar to generate the necessary display information for the corresponding MenuBar item.
The text may be single or multi-line, and may contain a mnemonic by prefixing the mnemonic character with an ampersand.



voidSetTitleText (xrstring value)

 

Sets the label of the MenuPane, used only by the MenuBar to generate the necessary display information for the corresponding MenuBar item.
The text may be single or multi-line, and may contain a mnemonic by prefixing the mnemonic character with an ampersand.
Parameters:
value
Returns:



xintGetHeight ()

 
Returns:
The height in pixels for the menu that the menu should ideally use. This value will be used as long as it is larger than the default menu height.



voidSetHeight (xint value)

 

Sets the height in pixels for the menu that the menu should ideally use. This value will be used as long as it is larger than the default menu height.
Parameters:
value
Returns:



xstringGetOwnerName ()

 
Returns:
The name of the component over which the MenuPane was displayed when it is being used as a popup menu.



voidSetOwnerName (xrstring value)

 

Sets the name of the component over which the MenuPane was displayed when it is being used as a popup menu.
Parameters:
value
Returns:



xboolHasBorder ()

 
Returns:
Flag indicating whether the MenuPane has a decorated shadow border.



voidSetHasBorder (xbool flag)

 

Sets flag indicating whether the MenuPane has a decorated shadow border.
Parameters:
flag
Returns:



xboolDoesAutoClose ()

 
Returns:
Flag indicating whether the MenuPane should close automatically due to the action which has just occured within the current open menu hierarchy. This flag can be used by the application code to prevent the automatic closure of a MenuPane by setting it to xfalse in the OnCloseRequest() callback.



voidSetAutoClose (xbool flag)

 

Sets flag indicating whether the MenuPane should close automatically due to the action which has just occured within the current open menu hierarchy. This flag can be used by the application code to prevent the automatic closure of a MenuPane by setting it to xfalse in the OnCloseRequest() callback.
Parameters:
flag
Returns:



xstringGetAcceleratorText ()

 
Returns:
The translated text representation of the current value of AcceleratorKey attribute.



voidAddActionListener (uifcMenuPaneListener_ptr listener)

 


Parameters:
listener
Returns:



voidPushAction (uifcMenuPaneAction action)

 


Parameters:
action
Returns:



voidCreateTimer (uifcMenuPaneTimer_ptr timer, xrstring timerName, xbool writeInTrail)

 


Parameters:
timer
timerName
writeInTrail
Returns:



voidStartTimer (xrstring timerName, xint duration)

 


Parameters:
timerName
duration
Returns:



voidStopTimer (xrstring timerName)

 


Parameters:
timerName
Returns: