1 /**********************************************************************
2 Freeciv - Copyright (C) 2006 - The Freeciv Project
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12 ***********************************************************************/
14 #ifndef FC__WIDGET_BUTTON_H
15 #define FC__WIDGET_BUTTON_H
17 #define create_icon_button_from_unichar(pIcon, pDest, pUniChar, pUniCharSize, iPtsize, flags) \
18 create_icon_button(pIcon, pDest, create_string16(pUniChar, pUniCharSize, iPtsize), flags)
20 #define create_icon_button_from_chars(pIcon, pDest, pCharString, iPtsize, flags) \
21 create_icon_button(pIcon, pDest, \
22 create_str16_from_char(pCharString, iPtsize), \
25 #define create_themeicon_button_from_unichar(pIcon_theme, pDest, pUniChar, pUniCharSize, iPtsize, flags) \
26 create_themeicon_button(pIcon, pDest, create_string16(pUniChar, pUniCharSize, iPtsize), \
29 #define create_themeicon_button_from_chars(pIcon_theme, pDest, pCharString, iPtsize, flags) \
30 create_themeicon_button(pIcon_theme, pDest, \
31 create_str16_from_char(pCharString, \
35 struct widget
*create_icon_button(SDL_Surface
*pIcon
,
36 struct gui_layer
*pDest
, SDL_String16
*pString
, Uint32 flags
);
38 struct widget
*create_themeicon_button(SDL_Surface
*pIcon_theme
,
39 struct gui_layer
*pDest
, SDL_String16
*pString
, Uint32 flags
);
41 int draw_tibutton(struct widget
*pButton
, Sint16 start_x
, Sint16 start_y
);
42 int draw_ibutton(struct widget
*pButton
, Sint16 start_x
, Sint16 start_y
);
44 #endif /* FC__WIDGET_BUTTON_H */