summaryrefslogtreecommitdiffstats
path: root/lib/widget/gauge.h
diff options
context:
space:
mode:
Diffstat (limited to 'lib/widget/gauge.h')
-rw-r--r--lib/widget/gauge.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/lib/widget/gauge.h b/lib/widget/gauge.h
new file mode 100644
index 0000000..e1f5d2c
--- /dev/null
+++ b/lib/widget/gauge.h
@@ -0,0 +1,36 @@
+
+/** \file gauge.h
+ * \brief Header: WGauge widget
+ */
+
+#ifndef MC__WIDGET_GAUGE_H
+#define MC__WIDGET_GAUGE_H
+
+/*** typedefs(not structures) and defined constants **********************************************/
+
+#define GAUGE(x) ((WGauge *)(x))
+
+/*** enums ***************************************************************************************/
+
+/*** structures declarations (and typedefs of structures)*****************************************/
+
+typedef struct WGauge
+{
+ Widget widget;
+ gboolean shown;
+ int max;
+ int current;
+ gboolean from_left_to_right;
+} WGauge;
+
+/*** global variables defined in .c file *********************************************************/
+
+/*** declarations of public functions ************************************************************/
+
+WGauge *gauge_new (int y, int x, int cols, gboolean shown, int max, int current);
+void gauge_set_value (WGauge * g, int max, int current);
+void gauge_show (WGauge * g, gboolean shown);
+
+/*** inline functions ****************************************************************************/
+
+#endif /* MC__WIDGET_GAUGE_H */