Rebar control help

Function help:

Real API_Status_Create (Real Parent Handle,Real Style Flags, Real Extended Style Flags);

This function creates a new status bar control.

Argument list:
(0) Parent Handle: Identifies the window handle of the window to create this control on.
(1) Style Flags: The style flags, supports the Global Control Styles, the Common Control Styles and the following styles:

SBT_TOOLTIPS - Use this style to enable ToolTips.

Style flags can be separated by a bitwise or '|' operator.

(2) Extended Style Flags: This can be any combination of the Global Extended Control Styles.

Return value:
If this function succeeds, it returns the Control ID of the control, otherwise it returns 0.


Real API_Status_SetParts ( Real Control ID, Real Number Of Parts, Real Part 1 Size, Real Part 2 Size, Real Part 3 Size, Real Part 4 Size, Real Part 5 Size, Real Part 6 Size, Real Part 7 Size, Real Part 8 Size, Real Part 9 Size)

This function changes the number of parts, and the sizes of those parts.

Return value:
If this function succeeds, it returns true (1), otherwise it returns false (0).
Real API_Status_SetText ( Real Control ID, Real Zero Based Part Index, String Text)

This function changes the text of a status bar part.

Return value:
If this function succeeds, it returns true (1), otherwise it returns false (0).
Real API_Status_SetTipText ( Real Control ID, Real Zero Based Part Index, String Text)

This function changes the tooltip text of a status bar control part.

You need to use the SBT_TOOLTIPS style.

This ToolTip text is displayed in two situations:

* When the corresponding pane in the status bar contains only an icon.
* When the corresponding pane in the status bar contains text that is truncated due to the size of the pane.

Return value:
If this function succeeds, it returns true (1), otherwise it returns false (0).


Real API_Status_SetMinHeight ( Real Control ID,Real Status Bar Heigth)

This funtion changes the minimum height of the status bar control.
The control is redrawed to the new size.

Return value:
If this function succeeds, it returns true (1), otherwise it returns false (0).
Real API_Status_SetIcon ( Real Control ID,Real Zero Based Part Index,Real Icon Resource Handle)

This function changes the icon displayed inside a status bar part.

To load an icon from a file, use API_Resource_LoadIcon.

Return value:
If this function succeeds, it returns true (1), otherwise it returns false (0).
Secondary check commands for list boxes:

NM_CLICK - A part is clicked.
NM_DBLCLK- A part is double clicked.
NM_RCLICK- A part is right clicked.
NM_RDBLCLK- A part is right double clicked.

Use API_Check_TertiaryCommand to get the part index.

Example:

if ( Command == Status1)
{
Second = API_Check_SecondaryCommand (1); // Check the status bar command
if (Second == NM_CLICK)
{
Part = API_Check_TertiaryCommand (1) // Check the part number
show_message ("You clicked part "+string (Part)+".");
}
}



Example code:

is

Status1 = API_Status_Create (Win,SBT_TOOLTIPS); // Creates a tooltip

API_Status_SetParts (Status1,3,100,300,-1); // Creates the parts

API_Status_SetText (Status1,0,"Part1"); // Set the text of part 1
API_Status_SetText (Status1,1,"Part2");

Icon = API_Resource_LoadIcon ("Icon.ico"); // Load the icon from a file

API_Status_SetIcon (Status1,2,Icon); // Sets the icon in part 2

API_Status_SetTipText (Status1,2,"Tooltip."); // Changes the tooltip of part 2


Return to help index