#include <Fl_Tree_Prefs.H>
Public Member Functions | |
void | bgcolor (Fl_Color val) |
Set the default label background color. | |
Fl_Color | bgcolor () const |
Get the default label background color. | |
void | closeicon (Fl_Pixmap *val) |
Sets the icon to be used as the 'close' icon. | |
Fl_Pixmap * | closeicon () const |
Gets the default 'close' icon Returns the Fl_Pixmap* of the icon, or 0 if none. | |
void | connectorcolor (Fl_Color val) |
Set the connector color; the color used for tree connection lines. | |
Fl_Color | connectorcolor () const |
Get the connector color; the color used for tree connection lines. | |
void | connectorstyle (Fl_Tree_Connector val) |
Set the connector style. | |
Fl_Tree_Connector | connectorstyle () const |
Get the connector style. | |
void | connectorwidth (int val) |
Set the tree connection line's width. | |
int | connectorwidth () const |
Get the tree connection line's width. | |
void | fgcolor (Fl_Color val) |
Set the default label foreground color. | |
Fl_Color | fgcolor () const |
Get the default label foreground color. | |
Fl_Tree_Prefs () | |
Fl_Tree_Prefs constructor. | |
void | inactivecolor (Fl_Color val) |
Set the default inactive color. | |
Fl_Color | inactivecolor () const |
Get the default inactive color. | |
void | labelfont (int val) |
Set the label's font to val . | |
int | labelfont () const |
Return the label's font. | |
void | labelmarginleft (int val) |
Set the label's left margin value in pixels. | |
int | labelmarginleft () const |
Get the label's left margin value in pixels. | |
void | labelsize (int val) |
Set the label's size in pixels to val . | |
int | labelsize () const |
Return the label's size in pixels. | |
void | linespacing (int val) |
Set the line spacing value in pixels. | |
int | linespacing () const |
Get the line spacing value in pixels. | |
void | marginleft (int val) |
Set the left margin's value in pixels. | |
int | marginleft () const |
Get the left margin's value in pixels. | |
void | margintop (int val) |
Set the top margin's value in pixels. | |
int | margintop () const |
Get the top margin's value in pixels. | |
void | openicon (Fl_Pixmap *val) |
Sets the default icon to be used as the 'open' icon when items are add()ed to the tree. | |
Fl_Pixmap * | openicon () const |
Get the current default 'open' icon. | |
void | selectbox (Fl_Boxtype val) |
Set the default selection box's box drawing style to val . | |
Fl_Boxtype | selectbox () const |
Get the default selection box's box drawing style as an Fl_Boxtype. | |
void | selectcolor (Fl_Color val) |
Set the default selection color. | |
Fl_Color | selectcolor () const |
Get the default selection color. | |
void | selectmode (Fl_Tree_Select val) |
Set the selection mode used for the tree to val . | |
Fl_Tree_Select | selectmode () const |
Get the selection mode used for the tree. | |
void | showcollapse (int val) |
Set if we should show the collapse icon or not. | |
char | showcollapse () const |
Returns 1 if the collapse icon is enabled, 0 if not. | |
void | showroot (int val) |
Set if the root item should be shown or not. | |
int | showroot () const |
Returns 1 if the root item is to be shown, or 0 if not. | |
void | sortorder (Fl_Tree_Sort val) |
Set the default sort order value. | |
Fl_Tree_Sort | sortorder () const |
Get the default sort order value. | |
void | usericon (Fl_Pixmap *val) |
Sets the default 'user icon' Returns the Fl_Pixmap* of the icon, or 0 if none (default). | |
Fl_Pixmap * | usericon () const |
Gets the default 'user icon' (default is 0). | |
void | usericonmarginleft (int val) |
Set the user icon's left margin value in pixels. | |
int | usericonmarginleft () const |
Get the user icon's left margin value in pixels. |
Fl_Tree's Preferences class.
This class manages the Fl_Tree's defaults. You should probably be using the methods in Fl_Tree instead of trying to accessing tree's preferences settings directly.
void Fl_Tree_Prefs::closeicon | ( | Fl_Pixmap * | val | ) |
Sets the icon to be used as the 'close' icon.
This overrides the built in default '[-]' icon.
[in] | val | -- The new pixmap, or zero to use the default [-] icon. |
int Fl_Tree_Prefs::labelfont | ( | ) | const [inline] |
Return the label's font.
void Fl_Tree_Prefs::openicon | ( | Fl_Pixmap * | val | ) |
Sets the default icon to be used as the 'open' icon when items are add()ed to the tree.
This overrides the built in default '[+]' icon.
[in] | val | -- The new pixmap, or zero to use the default [+] icon. |
Fl_Pixmap* Fl_Tree_Prefs::openicon | ( | ) | const [inline] |
Get the current default 'open' icon.
Returns the Fl_Pixmap* of the icon, or 0 if none.
void Fl_Tree_Prefs::selectmode | ( | Fl_Tree_Select | val | ) | [inline] |
Set the selection mode used for the tree to val
.
This affects how items in the tree are selected when clicked on and dragged over by the mouse. See Fl_Tree_Select for possible values.
void Fl_Tree_Prefs::showcollapse | ( | int | val | ) | [inline] |
Set if we should show the collapse icon or not.
If collapse icons are disabled, the user will not be able to interactively collapse items in the tree, unless the application provides some other means via open() and close().
[in] | val | 1: shows collapse icons (default), 0: hides collapse icons. |
char Fl_Tree_Prefs::showcollapse | ( | ) | const [inline] |
Returns 1 if the collapse icon is enabled, 0 if not.
void Fl_Tree_Prefs::showroot | ( | int | val | ) | [inline] |
Set if the root item should be shown or not.
[in] | val | 1 -- show the root item (default) 0 -- hide the root item. |
void Fl_Tree_Prefs::sortorder | ( | Fl_Tree_Sort | val | ) | [inline] |
Set the default sort order value.
Defines the order new items appear when add()ed to the tree. See Fl_Tree_Sort for possible values.