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)  

Fl_Label Struct Reference

#include <Fl_Widget.H>

Collaboration diagram for Fl_Label:

List of all members.

Public Member Functions

void draw (int, int, int, int, Fl_Align) const
void measure (int &w, int &h) const

Public Attributes

const char * value
Fl_Imageimage
Fl_Imagedeimage
Fl_Font font
Fl_Fontsize size
Fl_Color color
Fl_Align align_
uchar type

Detailed Description

This struct stores all information for a text or mixed graphics label.

Todo:
For FLTK 1.3, the Fl_Label type will become a widget by itself. That way we will be avoiding a lot of code duplication by handling labels in a similar fashion to widgets containing text. We also provide an easy interface for very complex labels, containing html or vector graphics.

Definition at line 73 of file Fl_Widget.H.


Member Function Documentation

void Fl_Label::draw ( int  X,
int  Y,
int  W,
int  H,
Fl_Align  align 
) const

Draws the label aligned to the given box

Draws a label with arbitrary alignment in an arbitrary box.

Definition at line 86 of file fl_labeltype.cxx.

References H, image, type, and value.

Referenced by Fl_Menu_Item::draw(), Fl_Choice::draw(), and Fl_Widget::draw_label().

void Fl_Label::measure ( int &  W,
int &  H 
) const

Measures the size of the label.

Parameters:
[in,out]W,H: this is the requested size for the label text plus image; on return, this will contain the size needed to fit the label

Definition at line 95 of file fl_labeltype.cxx.

References f, fl_normal_measure(), image, type, and value.

Referenced by Fl_Menu_Item::measure(), and Fl_Widget::redraw_label().


Member Data Documentation

alignment of label

Definition at line 87 of file Fl_Widget.H.

Referenced by Fl_Widget::Fl_Widget().

optional image for a deactivated label

Definition at line 79 of file Fl_Widget.H.

Referenced by Fl_Menu_Item::draw(), Fl_Choice::draw(), Fl_Widget::draw_label(), Fl_Widget::Fl_Widget(), and Fl_Menu_Item::measure().


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