imtk

diff src/imtk.h @ 13:9c7987064bb0

- fixed the frame drawing a bit - added global alpha value and various drawing parameters - backported the checkbox check mark from glamtk - fixed progress bar drawing so that the bevels of the trough and the bar won't overlap
author John Tsiombikas <nuclear@siggraph.org>
date Mon, 18 Apr 2011 06:15:46 +0300
parents 467a520f5c00
children df2bc9406561
line diff
     1.1 --- a/src/imtk.h	Sun Apr 17 18:20:23 2011 +0300
     1.2 +++ b/src/imtk.h	Mon Apr 18 06:15:46 2011 +0300
     1.3 @@ -20,6 +20,17 @@
     1.4  	IMTK_RIGHT_BUTTON
     1.5  };
     1.6  
     1.7 +enum {
     1.8 +	IMTK_TEXT_COLOR,
     1.9 +	IMTK_BASE_COLOR,
    1.10 +	IMTK_FOCUS_COLOR,
    1.11 +	IMTK_BEVEL_LIT_COLOR,
    1.12 +	IMTK_BEVEL_SHAD_COLOR,
    1.13 +	IMTK_CURSOR_COLOR,
    1.14 +	IMTK_SELECTION_COLOR,
    1.15 +	IMTK_CHECK_COLOR
    1.16 +};
    1.17 +
    1.18  
    1.19  #ifdef __cplusplus
    1.20  extern "C" {
    1.21 @@ -38,6 +49,7 @@
    1.22  void imtk_begin(void);
    1.23  void imtk_end(void);
    1.24  
    1.25 +void imtk_label(const char *str, int x, int y);
    1.26  int imtk_button(int id, const char *label, int x, int y);
    1.27  int imtk_checkbox(int id, const char *label, int x, int y, int state);
    1.28  void imtk_textbox(int id, char *textbuf, size_t buf_sz, int x, int y);
    1.29 @@ -52,6 +64,13 @@
    1.30  char *imtk_create_list(const char *first, ...);
    1.31  void imtk_free_list(char *list);
    1.32  
    1.33 +/* defined in draw.c */
    1.34 +void imtk_set_color(int col, float r, float g, float b, float a);
    1.35 +void imtk_set_alpha(float a);
    1.36 +float imtk_get_alpha(void);
    1.37 +void imtk_set_bevel_width(float b);
    1.38 +float imtk_get_bevel_width(void);
    1.39 +
    1.40  #ifdef __cplusplus
    1.41  }
    1.42  #endif