fltk 1.3.0rc3
About: FLTK (Fast Light Tool Kit) is a cross-platform C++ GUI toolkit for UNIX/Linux (X11), Microsoft Windows, and MacOS X. Release candidate.
  SfR Fresh Dox: fltk-1.3.0rc3-source.tar.gz ("inofficial" and yet experimental doxygen-generated source code documentation)  

Events handling functions

Functions

static int Fl::event ()
static int Fl::event_x ()
static int Fl::event_y ()
static int Fl::event_x_root ()
static int Fl::event_y_root ()
static int Fl::event_dx ()
static int Fl::event_dy ()
static void Fl::get_mouse (int &, int &)
static int Fl::event_clicks ()
static void Fl::event_clicks (int i)
static int Fl::event_is_click ()
static void Fl::event_is_click (int i)
static int Fl::event_button ()
static int Fl::event_state ()
static int Fl::event_state (int i)
static int Fl::event_key ()
static int Fl::event_original_key ()
static int Fl::event_key (int key)
static int Fl::get_key (int key)
static const char * Fl::event_text ()
static int Fl::event_length ()
static int Fl::compose (int &del)
static void Fl::compose_reset ()
static int Fl::event_inside (int, int, int, int)
static int Fl::event_inside (const Fl_Widget *)
static int Fl::test_shortcut (Fl_Shortcut)
static int Fl::handle (int, Fl_Window *)
static Fl_WidgetFl::belowmouse ()
static void Fl::belowmouse (Fl_Widget *)
static Fl_WidgetFl::pushed ()
static void Fl::pushed (Fl_Widget *)
static Fl_WidgetFl::focus ()
static void Fl::focus (Fl_Widget *)
static void Fl::add_handler (Fl_Event_Handler h)
static void Fl::remove_handler (Fl_Event_Handler h)
static int Fl::event_shift ()
static int Fl::event_ctrl ()
static int Fl::event_command ()
static int Fl::event_alt ()
static int Fl::event_buttons ()
static int Fl::event_button1 ()
static int Fl::event_button2 ()
static int Fl::event_button3 ()

Variables

const char *const fl_eventnames []
const char *const fl_fontnames []

Detailed Description

Fl class events handling API declared in <FL/Fl.H>


Function Documentation

void Fl::add_handler ( Fl_Event_Handler  ha) [static, inherited]

Install a function to parse unrecognized events. If FLTK cannot figure out what to do with an event, it calls each of these functions (most recent first) until one of them returns non-zero. If none of them returns non zero then the event is ignored. Events that cause this to be called are:

  • FL_SHORTCUT events that are not recognized by any widget. This lets you provide global shortcut keys.
  • System events that FLTK does not recognize. See fl_xevent.
  • Some other events when the widget FLTK selected returns zero from its handle() method. Exactly which ones may change in future versions, however.

Definition at line 739 of file Fl.cxx.

References handler_link::handle, and handler_link::next.

Referenced by Fl_Menu_::global().

static Fl_Widget* Fl::belowmouse ( ) [inline, static, inherited]

Gets the widget that is below the mouse.

See also:
belowmouse(Fl_Widget*)

Definition at line 688 of file Fl.H.

Referenced by FLDropTarget::Drop(), fl_fix_focus(), fl_handle(), fl_throw_focus(), Fl_Text_Editor::handle(), Fl_Input::handle(), Fl_Group::handle(), and Fl::handle().

void Fl::belowmouse ( Fl_Widget o) [static, inherited]

Sets the widget that is below the mouse. This is for highlighting buttons. It is not used to send FL_PUSH or FL_MOVE directly, for several obscure reasons, but those events typically go to this widget. This is also the first widget tried for FL_SHORTCUT events.

If you change the belowmouse widget, the previous one and all parents (that don't contain the new widget) are sent FL_LEAVE events. Changing this does not send FL_ENTER to this or any widget, because sending FL_ENTER is supposed to test if the widget wants the mouse (by it returning non-zero from handle()).

Definition at line 831 of file Fl.cxx.

References Fl::belowmouse_, Fl_Widget::contains(), Fl::e_number, FL_DND_LEAVE, FL_LEAVE, Fl::grab(), Fl_Widget::handle(), and Fl_Widget::parent().

int Fl::compose ( int &  del) [static, inherited]

Any text editing widget should call this for each FL_KEYBOARD event. Use of this function is very simple.

If true is returned, then it has modified the Fl::event_text() and Fl::event_length() to a set of bytes to insert (it may be of zero length!). In will also set the "del" parameter to the number of bytes to the left of the cursor to delete, this is used to delete the results of the previous call to Fl::compose().

If false is returned, the keys should be treated as function keys, and del is set to zero. You could insert the text anyways, if you don't know what else to do.

Though the current implementation returns immediately, future versions may take quite awhile, as they may pop up a window or do other user-interface things to allow characters to be selected.

Definition at line 54 of file Fl_compose.cxx.

References Fl::compose_state, Fl::e_keysym, Fl::e_length, Fl::e_state, Fl::e_text, FL_ALT, FL_CTRL, FL_Enter, FL_Escape, FL_KP_Enter, FL_META, and FL_Tab.

Referenced by Fl_Text_Editor::handle_key().

static void Fl::compose_reset ( ) [inline, static, inherited]

If the user moves the cursor, be sure to call Fl::compose_reset(). The next call to Fl::compose() will start out in an initial state. In particular it will not set "del" to non-zero. This call is very fast so it is ok to call it many times and in many places.

Definition at line 679 of file Fl.H.

Referenced by Fl::focus().

static int Fl::event ( ) [inline, static, inherited]

Returns the last event that was processed. This can be used to determine if a callback is being done in response to a keypress, mouse click, etc.

Definition at line 474 of file Fl.H.

Referenced by Fl_Tabs::handle().

static int Fl::event_alt ( ) [inline, static, inherited]

Returns non-zero if the Alt key is pressed.

Definition at line 897 of file Fl.H.

References FL_ALT.

static int Fl::event_button ( ) [inline, static, inherited]

Gets which particular mouse button caused the current event. This returns garbage if the most recent event was not a FL_PUSH or FL_RELEASE event.

Return values:
FL_LEFT_MOUSE
FL_MIDDLE_MOUSE
FL_RIGHT_MOUSE.
See also:
Fl::event_buttons()

Definition at line 556 of file Fl.H.

References FL_Button.

Referenced by fl_get_button_numb(), fl_mouse_button(), Fl_Free::handle(), Fl_Value_Output::handle(), Fl_Value_Input::handle(), Fl_Tree::handle(), Fl_Text_Editor::handle(), Fl_Text_Display::handle(), Fl_Table_Row::handle(), Fl_Table::handle(), Fl_Scrollbar::handle(), Fl_Menu_Button::handle(), Fl_Input::handle(), and Fl_Window_Type::handle().

static int Fl::event_button1 ( ) [inline, static, inherited]

Returns non-zero if mouse button 1 is currently held down. For more details, see Fl::event_buttons().

Definition at line 911 of file Fl.H.

References FL_BUTTON1.

static int Fl::event_button2 ( ) [inline, static, inherited]

Returns non-zero if button 2 is currently held down. For more details, see Fl::event_buttons().

Definition at line 916 of file Fl.H.

References FL_BUTTON2.

static int Fl::event_button3 ( ) [inline, static, inherited]

Returns non-zero if button 3 is currently held down. For more details, see Fl::event_buttons().

Definition at line 921 of file Fl.H.

References FL_BUTTON3.

static int Fl::event_buttons ( ) [inline, static, inherited]

Returns the mouse buttons state bits; if non-zero, then at least one button is pressed now. This function returns the button state at the time of the event. During an FL_RELEASE event, the state of the released button will be 0. To find out, which button caused an FL_RELEASE event, you can use Fl::event_button() instead.

Returns:
a bit mask value like { [FL_BUTTON1] | [FL_BUTTON2] | [FL_BUTTON3] }

Definition at line 906 of file Fl.H.

static int Fl::event_clicks ( ) [inline, static, inherited]

Returns non zero if we had a double click event.

Return values:
Non-zeroif the most recent FL_PUSH or FL_KEYBOARD was a "double click".
N-1for N clicks. A double click is counted if the same button is pressed again while event_is_click() is true.

Definition at line 526 of file Fl.H.

Referenced by fl_double_click(), Fl_Text_Display::handle(), Fl_Table::handle(), Fl_Input::handle(), Fl_Browser_::handle(), Fl_Window_Type::handle(), Widget_Browser::handle(), and Fl_Input_::handle_mouse().

static void Fl::event_clicks ( int  i) [inline, static, inherited]

Manually sets the number returned by Fl::event_clicks(). This can be used to set it to zero so that later code does not think an item was double-clicked.

Parameters:
[in]icorresponds to no double-click if 0, i+1 mouse clicks otherwise
See also:
int event_clicks()

Definition at line 534 of file Fl.H.

References i.

static int Fl::event_command ( ) [inline, static, inherited]

Returns non-zero if the FL_COMMAND key is pressed, either FL_CTRL or on OSX FL_META.

Definition at line 895 of file Fl.H.

References FL_COMMAND.

static int Fl::event_ctrl ( ) [inline, static, inherited]

Returns non-zero if the Control key is pressed.

Definition at line 893 of file Fl.H.

References FL_CTRL.

static int Fl::event_dx ( ) [inline, static, inherited]

Returns the current horizontal mouse scrolling associated with the FL_MOUSEWHEEL event. Right is positive.

Definition at line 503 of file Fl.H.

static int Fl::event_dy ( ) [inline, static, inherited]

Returns the current vertical mouse scrolling associated with the FL_MOUSEWHEEL event. Down is positive.

Definition at line 508 of file Fl.H.

Referenced by Fl_Text_Display::handle().

int Fl::event_inside ( int  xx,
int  yy,
int  ww,
int  hh 
) [static, inherited]

Returns whether or not the mouse event is inside the given rectangle. Returns non-zero if the current event_x and event_y put it inside the widget or inside an arbitrary bounding box. You should always call this rather than doing your own comparison so you are consistent about edge effects.

Definition at line 148 of file Fl.cxx.

References Fl::e_x, and Fl::e_y.

Referenced by Fl_Table::cursor2rowcol(), Fl_Tree::handle(), Fl_Text_Display::handle(), Fl_Table::handle(), Fl_Slider::handle(), Fl_Repeat_Button::handle(), Fl_Group::handle(), Fl_Button::handle(), Fl_Browser_::handle(), Fl_Window_Type::handle(), and Widget_Browser::handle().

int Fl::event_inside ( const Fl_Widget o) [static, inherited]

Returns whether or not the mouse event is inside the given widget. Returns non-zero if the current event_x and event_y put it inside the widget or inside an arbitrary bounding box. You should always call this rather than doing your own comparison so you are consistent about edge effects.

Definition at line 160 of file Fl.cxx.

References Fl::e_x, Fl::e_y, Fl::h(), Fl::w(), Fl_Widget::x(), and Fl_Widget::y().

static int Fl::event_is_click ( ) [inline, static, inherited]

The first form returns non-zero if the mouse has not moved far enough and not enough time has passed since the last FL_PUSH or FL_KEYBOARD event for it to be considered a "drag" rather than a "click". You can test this on FL_DRAG, FL_RELEASE, and FL_MOVE events. The second form clears the value returned by Fl::event_is_click(). Useful to prevent the next click from being counted as a double-click or to make a popup menu pick an item with a single click. Don't pass non-zero to this.

Definition at line 545 of file Fl.H.

Referenced by Fl_Value_Input::handle(), Fl_Text_Display::handle(), Fl_Input::handle(), Fl_Adjuster::handle(), and Fl_Window_Type::handle().

static void Fl::event_is_click ( int  i) [inline, static, inherited]

Only i=0 works! See int event_is_click().

Definition at line 549 of file Fl.H.

References i.

static int Fl::event_key ( ) [inline, static, inherited]

Gets which key on the keyboard was last pushed.

The returned integer 'key code' is not necessarily a text equivalent for the keystroke. For instance: if someone presses '5' on the numeric keypad with numlock on, Fl::event_key() may return the 'key code' for this key, and NOT the character '5'. To always get the '5', use Fl::event_text() instead.

Returns:
an integer 'key code', or 0 if the last event was not a key press or release.
See also:
int event_key(int), event_text(), compose(int&).

Definition at line 594 of file Fl.H.

Referenced by Fl::get_key(), Fl_Free::handle(), Fl_Tree::handle(), Fl_Text_Display::handle(), Fl_Tabs::handle(), Fl_Table::handle(), Fl_Slider::handle(), Fl_Scrollbar::handle(), Fl_Roller::handle(), Fl_Return_Button::handle(), Fl_Menu_Button::handle(), Fl_Input::handle(), Fl_Group::handle(), Fl_Counter::handle(), Flcc_ValueBox::handle(), Flcc_HueBox::handle(), Fl_Choice::handle(), Fl_Button::handle(), Fl_Browser_::handle(), Fl_Adjuster::handle(), Fl::handle(), Fl_Window_Type::handle(), Shortcut_Button::handle(), Fl_Spinner::handle(), Fl_Text_Editor::handle_key(), and Fl::test_shortcut().

int Fl::event_key ( int  key) [static, inherited]

Returns true if the given key was held down (or pressed) during the last event. This is constant until the next event is read from the server.

Fl::get_key(int) returns true if the given key is held down now. Under X this requires a round-trip to the server and is much slower than Fl::event_key(int).

Keys are identified by the unshifted values. FLTK defines a set of symbols that should work on most modern machines for every key on the keyboard:

  • All keys on the main keyboard producing a printable ASCII character use the value of that ASCII character (as though shift, ctrl, and caps lock were not on). The space bar is 32.
  • All keys on the numeric keypad producing a printable ASCII character use the value of that ASCII character plus FL_KP. The highest possible value is FL_KP_Last so you can range-check to see if something is on the keypad.
  • All numbered function keys use the number on the function key plus FL_F. The highest possible number is FL_F_Last, so you can range-check a value.
  • Buttons on the mouse are considered keys, and use the button number (where the left button is 1) plus FL_Button.
  • All other keys on the keypad have a symbol: FL_Escape, FL_BackSpace, FL_Tab, FL_Enter, FL_Print, FL_Scroll_Lock, FL_Pause, FL_Insert, FL_Home, FL_Page_Up, FL_Delete, FL_End, FL_Page_Down, FL_Left, FL_Up, FL_Right, FL_Down, FL_Shift_L, FL_Shift_R, FL_Control_L, FL_Control_R, FL_Caps_Lock, FL_Alt_L, FL_Alt_R, FL_Meta_L, FL_Meta_R, FL_Menu, FL_Num_Lock, FL_KP_Enter. Be careful not to confuse these with the very similar, but all-caps, symbols used by Fl::event_state().

On X Fl::get_key(FL_Button+n) does not work.

On WIN32 Fl::get_key(FL_KP_Enter) and Fl::event_key(FL_KP_Enter) do not work.

Definition at line 43 of file Fl_get_key.cxx.

References Fl::event_state(), FL_Button, fl_display, fl_key_vector, FL_Menu, FL_Meta_L, FL_Meta_R, and i.

static int Fl::event_length ( ) [inline, static, inherited]

Returns the length of the text in Fl::event_text(). There will always be a nul at this position in the text. However there may be a nul before that if the keystroke translates to a nul character or you paste a nul character.

Definition at line 670 of file Fl.H.

Referenced by Fl_Text_Editor::handle_key(), Fl_Input_::handletext(), Fl_Widget::test_shortcut(), and Fl::test_shortcut().

static int Fl::event_original_key ( ) [inline, static, inherited]

Returns the keycode of the last key event, regardless of the NumLock state.

If NumLock is deactivated, FLTK translates events from the numeric keypad into the corresponding arrow key events. event_key() returns the translated key code, whereas event_original_key() returns the keycode before NumLock translation.

Definition at line 603 of file Fl.H.

static int Fl::event_shift ( ) [inline, static, inherited]

Returns non-zero if the Shift key is pressed.

Definition at line 891 of file Fl.H.

References FL_SHIFT.

static int Fl::event_state ( ) [inline, static, inherited]

This is a bitfield of what shift states were on and what mouse buttons were held down during the most recent event. The second version returns non-zero if any of the passed bits are turned on. The legal bits are:

  • FL_SHIFT
  • FL_CAPS_LOCK
  • FL_CTRL
  • FL_ALT
  • FL_NUM_LOCK
  • FL_META
  • FL_SCROLL_LOCK
  • FL_BUTTON1
  • FL_BUTTON2
  • FL_BUTTON3

X servers do not agree on shift states, and FL_NUM_LOCK, FL_META, and FL_SCROLL_LOCK may not work. The values were selected to match the XFree86 server on Linux. In addition there is a bug in the way X works so that the shift state is not correctly reported until the first event after the shift key is pressed or released.

Definition at line 580 of file Fl.H.

Referenced by Fl::event_key(), glutGetModifiers(), Fl_Tree::handle(), Fl_Text_Display::handle(), Fl_Table_Row::handle(), Fl_Table::handle(), Fl_Menu_Button::handle(), Fl_Input::handle(), Flcc_HueBox::handle(), Fl_Choice::handle(), Fl_Button::handle(), Fl_Browser_::handle(), Fl_Adjuster::handle(), Fl_Window_Type::handle(), Widget_Browser::handle(), Shortcut_Button::handle(), Fl_Text_Editor::handle_key(), Fl_Input_::handletext(), Fl_Table::move_cursor(), Fl_Window_Type::newdx(), Fl_Widget::test_shortcut(), and Fl::test_shortcut().

static int Fl::event_state ( int  i) [inline, static, inherited]

See int event_state()

Definition at line 582 of file Fl.H.

References i.

static const char* Fl::event_text ( ) [inline, static, inherited]

Returns the text associated with the current event, including FL_PASTE or FL_DND_RELEASE events. This can be used in response to FL_KEYUP, FL_KEYDOWN, FL_PASTE, FL_DND_RELEASE.

When responding to FL_KEYUP/FL_KEYDOWN, use this function instead of Fl::event_key() to get the text equivalent of keystrokes suitable for inserting into strings and text widgets.

The returned string is guaranteed to be be NULL terminated. However, see Fl::event_length() for the actual length of the string, in case the string itself contains NULLs that are part of the text data.

Returns:
A NULL terminated text string equivalent of the last keystroke.

Definition at line 663 of file Fl.H.

Referenced by Fl_Text_Editor::handle(), Fl::handle(), Shortcut_Button::handle(), Fl_Text_Editor::handle_key(), Fl_Input_::handletext(), Fl_Widget::test_shortcut(), and Fl::test_shortcut().

static int Fl::event_x_root ( ) [inline, static, inherited]

Returns the mouse position on the screen of the event. To find the absolute position of an Fl_Window on the screen, use the difference between event_x_root(),event_y_root() and event_x(),event_y().

Definition at line 491 of file Fl.H.

Referenced by Fl_Value_Input::handle(), Fl::handle(), Fl_TooltipBox::layout(), Fl_Menu_Item::pulldown(), and ColorMenu::run().

static int Fl::event_y_root ( ) [inline, static, inherited]

Returns the mouse position on the screen of the event. To find the absolute position of an Fl_Window on the screen, use the difference between event_x_root(),event_y_root() and event_x(),event_y().

Definition at line 498 of file Fl.H.

Referenced by Fl::handle(), Fl_TooltipBox::layout(), Fl_Menu_Item::pulldown(), and ColorMenu::run().

void Fl::focus ( Fl_Widget o) [static, inherited]

Sets the widget that will receive FL_KEYBOARD events.

If you change Fl::focus(), the previous widget and all parents (that don't contain the new widget) are sent FL_UNFOCUS events. Changing the focus does not send FL_FOCUS to this or any widget, because sending FL_FOCUS is supposed to test if the widget wants the focus (by it returning non-zero from handle()).

See also:
Fl_Widget::take_focus()

Definition at line 789 of file Fl.cxx.

References Fl::compose_reset(), Fl::e_number, FL_UNFOCUS, Fl::focus_, Fl::grab(), Fl_Widget::handle(), Fl_Widget::parent(), Fl_Widget::visible_focus(), and Fl_Widget::window().

int Fl::get_key ( int  key) [static, inherited]

Returns true if the given key is held down now. Under X this requires a round-trip to the server and is much slower than Fl::event_key(int).

See also:
event_key(int)

Definition at line 59 of file Fl_get_key.cxx.

References Fl::event_key(), fl_display, fl_key_vector, and fl_open_display().

void Fl::get_mouse ( int &  x,
int &  y 
) [static, inherited]

Return where the mouse is on the screen by doing a round-trip query to the server. You should use Fl::event_x_root() and Fl::event_y_root() if possible, but this is necessary if you are not sure if a mouse event has been processed recently (such as to position your first window). If the display is not open, this will open it.

get the current mouse pointer world coordinates

Definition at line 1620 of file Fl_mac.cxx.

References fl_open_display().

Referenced by Fl_Window::hotspot().

static Fl_Widget* Fl::pushed ( ) [inline, static, inherited]
void Fl::pushed ( Fl_Widget o) [static, inherited]

Sets the widget that is being pushed. FL_DRAG or FL_RELEASE (and any more FL_PUSH) events will be sent to this widget.

If you change the pushed widget, the previous one and all parents (that don't contain the new widget) are sent FL_RELEASE events. Changing this does not send FL_PUSH to this or any widget, because sending FL_PUSH is supposed to test if the widget wants the mouse (by it returning non-zero from handle()).

Definition at line 857 of file Fl.cxx.

References Fl::pushed_.

void Fl::remove_handler ( Fl_Event_Handler  ha) [static, inherited]

Removes a previously added event handler.

Definition at line 749 of file Fl.cxx.

References handler_link::handle, and handler_link::next.

int Fl::test_shortcut ( Fl_Shortcut  shortcut) [static, inherited]

Test the current event, which must be an FL_KEYBOARD or FL_SHORTCUT, against a shortcut value (described in Fl_Button).

Not to be confused with Fl_Widget::test_shortcut().

Returns:
non-zero if there is a match.

Definition at line 63 of file fl_shortcut.cxx.

References Fl::event_key(), Fl::event_length(), Fl::event_state(), Fl::event_text(), FL_ALT, FL_CAPS_LOCK, FL_CTRL, FL_KEY_MASK, FL_META, FL_SHIFT, fl_tolower(), fl_utf8decode(), and key.

Referenced by Fl_Menu_Item::find_shortcut(), Fl_Text_Editor::handle(), Fl_Text_Display::handle(), Fl_Button::handle(), Fl_Input_::handletext(), and Fl_Menu_Item::test_shortcut().


Variable Documentation

const char* const fl_eventnames[]
Initial value:
{
  "FL_NO_EVENT",
  "FL_PUSH",
  "FL_RELEASE",
  "FL_ENTER",
  "FL_LEAVE",
  "FL_DRAG",
  "FL_FOCUS",
  "FL_UNFOCUS",
  "FL_KEYDOWN",
  "FL_KEYUP",
  "FL_CLOSE",
  "FL_MOVE",
  "FL_SHORTCUT",
  "FL_DEACTIVATE",
  "FL_ACTIVATE",
  "FL_HIDE",
  "FL_SHOW",
  "FL_PASTE",
  "FL_SELECTIONCLEAR",
  "FL_MOUSEWHEEL",
  "FL_DND_ENTER",
  "FL_DND_DRAG",
  "FL_DND_LEAVE",
  "FL_DND_RELEASE",
}

This is an array of event names you can use to convert event numbers into names.

The array gets defined inline wherever your '#include <FL/names.h>' appears.

Example:

  #include <FL/names.h>         // array will be defined here
  int MyClass::handle(int e) {
      printf("Event was %s (%d)\n", fl_eventnames[e], e);
      // ..resulting output might be e.g. "Event was FL_PUSH (1)"..
      [..]
  }

Definition at line 52 of file names.h.

const char* const fl_fontnames[]
Initial value:
{
  "FL_HELVETICA",
  "FL_HELVETICA_BOLD",
  "FL_HELVETICA_ITALIC",
  "FL_HELVETICA_BOLD_ITALIC",
  "FL_COURIER",
  "FL_COURIER_BOLD",
  "FL_COURIER_ITALIC",
  "FL_COURIER_BOLD_ITALIC",
  "FL_TIMES",
  "FL_TIMES_BOLD",
  "FL_TIMES_ITALIC",
  "FL_TIMES_BOLD_ITALIC",
  "FL_SYMBOL",
  "FL_SCREEN",
  "FL_SCREEN_BOLD",
  "FL_ZAPF_DINGBATS",
}

This is an array of font names you can use to convert font numbers into names.

The array gets defined inline wherever your '#include <FL/names.h>' appears.

Example:

  #include <FL/names.h>         // array will be defined here
  int MyClass::my_callback(Fl_Widget *w, void*) {
      int fnum = w->labelfont();
      // Resulting output might be e.g. "Label's font is FL_HELVETICA (0)"
      printf("Label's font is %s (%d)\n", fl_fontnames[fnum], fnum);
      // ..resulting output might be e.g. "Label's font is FL_HELVETICA (0)"..
      [..]
  }

Definition at line 97 of file names.h.