FLTK 1.3.2

- Main Page
- Related Pages
- Modules
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions
Fl_Tree_Prefs Class Reference

Tree widget's preferences. More...

`#include <Fl_Tree_Prefs.H>`

List of all members.

## Public Member Functions
Fl_Image * | closeicon () const
| Gets the default 'close' icon Returns the Fl_Image* of the icon, or 0 if none.
void | closeicon (Fl_Image *val)
| Sets the icon to be used as the 'close' icon.
Fl_Color | connectorcolor () const
| Get the connector color used for tree connection lines.
void | connectorcolor (Fl_Color val)
| Set the connector color used for tree connection lines.
Fl_Tree_Connector | connectorstyle () const
| Get the connector style.
void | connectorstyle (Fl_Tree_Connector val)
| Set the connector style.
void | connectorstyle (int val)
| Set the connector style [integer].
int | connectorwidth () const
| Get the tree connection line's width.
void | connectorwidth (int val)
| Set the tree connection line's width.
| Fl_Tree_Prefs ()
| Fl_Tree_Prefs constructor.
Fl_Color | item_labelbgcolor () const
| Get the default label background color.
void | item_labelbgcolor (Fl_Color val)
| Set the default label background color.
Fl_Color | item_labelfgcolor () const
| Get the default label foreground color.
void | item_labelfgcolor (Fl_Color val)
| Set the default label foreground color.
Fl_Font | item_labelfont () const
| Return the label's font.
void | item_labelfont (Fl_Font val)
| Set the label's font to `val`.
Fl_Fontsize | item_labelsize () const
| Return the label's size in pixels.
void | item_labelsize (Fl_Fontsize val)
| Set the label's size in pixels to `val`.
Fl_Color | labelbgcolor () const
| Obsolete: Get the default label background color. Please use item_labelbgcolor() instead.
void | labelbgcolor (Fl_Color val)
| Obsolete: Set the default label background color. Please use item_labelbgcolor(Fl_Color) instead.
Fl_Color | labelfgcolor () const
| Obsolete: Get the default label foreground color. Please use item_labelfgcolor() instead.
void | labelfgcolor (Fl_Color val)
| Obsolete: Set the default label foreground color. Please use item_labelfgcolor(Fl_Color) instead.
Fl_Font | labelfont () const
| Obsolete: Return the label's font.
void | labelfont (Fl_Font val)
| Obsolete: Set the label's font to `val`. Please use item_labelfont(Fl_Font) instead.
int | labelmarginleft () const
| Get the label's left margin value in pixels.
void | labelmarginleft (int val)
| Set the label's left margin value in pixels.
Fl_Fontsize | labelsize () const
| Obsolete: Return the label's size in pixels. Please use item_labelsize() instead.
void | labelsize (Fl_Fontsize val)
| Obsolete: Set the label's size in pixels to `val`. Please use item_labelsize(Fl_Fontsize) instead.
int | linespacing () const
| Get the line spacing value in pixels.
void | linespacing (int val)
| Set the line spacing value in pixels.
int | marginleft () const
| Get the left margin's value in pixels.
void | marginleft (int val)
| Set the left margin's value in pixels.
int | margintop () const
| Get the top margin's value in pixels.
void | margintop (int val)
| Set the top margin's value in pixels.
int | openchild_marginbottom () const
| Get the margin below an open child in pixels.
void | openchild_marginbottom (int val)
| Set the margin below an open child in pixels.
Fl_Image * | openicon () const
| Get the current default 'open' icon.
void | openicon (Fl_Image *val)
| Sets the default icon to be used as the 'open' icon when items are add()ed to the tree.
Fl_Boxtype | selectbox () const
| Get the default selection box's box drawing style as an Fl_Boxtype.
void | selectbox (Fl_Boxtype val)
| Set the default selection box's box drawing style to `val`.
Fl_Tree_Select | selectmode () const
| Get the selection mode used for the tree.
void | selectmode (Fl_Tree_Select val)
| Set the selection mode used for the tree to `val`.
char | showcollapse () const
| Returns 1 if the collapse icon is enabled, 0 if not.
void | showcollapse (int val)
| Set if we should show the collapse icon or not.
int | showroot () const
| Returns 1 if the root item is to be shown, or 0 if not.
void | showroot (int val)
| Set if the root item should be shown or not.
Fl_Tree_Sort | sortorder () const
| Get the default sort order value.
void | sortorder (Fl_Tree_Sort val)
| Set the default sort order value.
Fl_Image * | usericon () const
| Gets the default 'user icon' (default is 0)
void | usericon (Fl_Image *val)
| Sets the default 'user icon' Returns the Fl_Image* of the icon, or 0 if none (default).
int | usericonmarginleft () const
| Get the user icon's left margin value in pixels.
void | usericonmarginleft (int val)
| Set the user icon's left margin value in pixels.

## Detailed Description

Tree widget's preferences.

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.

## Member Function Documentation

void Fl_Tree_Prefs::closeicon | ( | Fl_Image * | val | ) |

Sets the icon to be used as the 'close' icon.

This overrides the built in default '[-]' icon.

Parameters:

  [in] | val | -- The new image, or zero to use the default [-] icon.

Fl_Color Fl_Tree_Prefs::connectorcolor | ( |  | ) | const`[inline]`

Get the connector color used for tree connection lines.

Fl_Font Fl_Tree_Prefs::item_labelfont | ( |  | ) | const`[inline]`

Return the label's font.

Fl_Font Fl_Tree_Prefs::labelfont | ( |  | ) | const`[inline]`

Obsolete: Return the label's font.

Please use item_labelfont() instead.

Fl_Image* Fl_Tree_Prefs::openicon | ( |  | ) | const`[inline]`

Get the current default 'open' icon.

Returns the Fl_Image* of the icon, or 0 if none.

void Fl_Tree_Prefs::openicon | ( | Fl_Image * | 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.

Parameters:

  [in] | val | -- The new image, or zero to use the default [+] icon.

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.

char Fl_Tree_Prefs::showcollapse | ( |  | ) | const`[inline]`

Returns 1 if the collapse icon is enabled, 0 if not.

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().

Parameters:

  [in] | val | 1: shows collapse icons (default), 0: hides collapse icons.

void Fl_Tree_Prefs::showroot | ( | int | val | ) | `[inline]`

Set if the root item should be shown or not.

Parameters:

  [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.

The documentation for this class was generated from the following files:

- Fl_Tree_Prefs.H
- Fl_Tree_Prefs.cxx