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

Fl_Label Struct Reference

#include <Fl_Widget.H>

Collaboration diagram for Fl_Label:
[legend]

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:
There is an aspiration that 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. However, this re-factoring is not in place in this release.

Definition at line 65 of file Fl_Widget.H.

Member Function Documentation

◆ draw()

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 77 of file fl_labeltype.cxx.

References H, image, table, type, value, and Y.

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

◆ measure()

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 86 of file fl_labeltype.cxx.

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

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

Member Data Documentation

◆ align_

Fl_Align Fl_Label::align_

alignment of label

Definition at line 79 of file Fl_Widget.H.

Referenced by Fl_Widget::align(), Fl_Window::draw(), and Fl_Widget::Fl_Widget().

◆ color

◆ deimage

Fl_Image* Fl_Label::deimage

◆ font

◆ image

◆ size

◆ type

◆ value


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