summaryrefslogtreecommitdiffstats
path: root/lib/widget/gauge.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:22:03 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:22:03 +0000
commitffccd5b2b05243e7976db80f90f453dccfae9886 (patch)
tree39a43152d27f7390d8f7a6fb276fa6887f87c6e8 /lib/widget/gauge.h
parentInitial commit. (diff)
downloadmc-upstream/3%4.8.30.tar.xz
mc-upstream/3%4.8.30.zip
Adding upstream version 3:4.8.30.upstream/3%4.8.30
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
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 */