gauge.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. /** \file gauge.h
  2. * \brief Header: WGauge widget
  3. */
  4. #ifndef MC__WIDGET_GAUGE_H
  5. #define MC__WIDGET_GAUGE_H
  6. /*** typedefs(not structures) and defined constants **********************************************/
  7. #define GAUGE(x) ((WGauge *)(x))
  8. /*** enums ***************************************************************************************/
  9. /*** structures declarations (and typedefs of structures)*****************************************/
  10. typedef struct WGauge
  11. {
  12. Widget widget;
  13. gboolean shown;
  14. int max;
  15. int current;
  16. gboolean from_left_to_right;
  17. } WGauge;
  18. /*** global variables defined in .c file *********************************************************/
  19. /*** declarations of public functions ************************************************************/
  20. WGauge *gauge_new (int y, int x, int cols, gboolean shown, int max, int current);
  21. void gauge_set_value (WGauge * g, int max, int current);
  22. void gauge_show (WGauge * g, gboolean shown);
  23. /*** inline functions ****************************************************************************/
  24. #endif /* MC__WIDGET_GAUGE_H */