Add useful macros for widget type cast.
[midnight-commander.git] / lib / widget / label.h
blob9b7573f894e93682d1ca03b5448136f018d9162e
2 /** \file label.h
3 * \brief Header: WLabel widget
4 */
6 #ifndef MC__WIDGET_LABEL_H
7 #define MC__WIDGET_LABEL_H
9 /*** typedefs(not structures) and defined constants **********************************************/
11 #define LABEL(x) ((WLabel *)(x))
13 /*** enums ***************************************************************************************/
15 /*** structures declarations (and typedefs of structures)*****************************************/
17 typedef struct
19 Widget widget;
20 gboolean auto_adjust_cols; /* compute widget.cols from strlen(text)? */
21 char *text;
22 gboolean transparent; /* Paint in the default color fg/bg */
23 } WLabel;
25 /*** global variables defined in .c file *********************************************************/
27 /*** declarations of public functions ************************************************************/
29 WLabel *label_new (int y, int x, const char *text);
30 void label_set_text (WLabel * label, const char *text);
32 /*** inline functions ****************************************************************************/
34 #endif /* MC__WIDGET_LABEL_H */