summaryrefslogtreecommitdiff
path: root/textscreen/txt_strut.h
diff options
context:
space:
mode:
authorSimon Howard2009-03-07 00:24:45 +0000
committerSimon Howard2009-03-07 00:24:45 +0000
commit2b5dae761ba1727cb483f4bae334a1b25f222e18 (patch)
tree3d8f68186aca380f39bf2974b59d17cbfcb888cd /textscreen/txt_strut.h
parent9b5d574982b49d0c12c5c7229a9151ad40c1bcb9 (diff)
downloadchocolate-doom-2b5dae761ba1727cb483f4bae334a1b25f222e18.tar.gz
chocolate-doom-2b5dae761ba1727cb483f4bae334a1b25f222e18.tar.bz2
chocolate-doom-2b5dae761ba1727cb483f4bae334a1b25f222e18.zip
Add documentation for high-level textscreen functions.
Subversion-branch: /trunk/chocolate-doom Subversion-revision: 1449
Diffstat (limited to 'textscreen/txt_strut.h')
-rw-r--r--textscreen/txt_strut.h20
1 files changed, 15 insertions, 5 deletions
diff --git a/textscreen/txt_strut.h b/textscreen/txt_strut.h
index 7d9e7650..8436aa9c 100644
--- a/textscreen/txt_strut.h
+++ b/textscreen/txt_strut.h
@@ -22,15 +22,18 @@
#ifndef TXT_STRUT_H
#define TXT_STRUT_H
+/**
+ * Strut widget.
+ *
+ * A strut is a widget that takes up a fixed amount of space. It can
+ * be visualised as a transparent box. Struts are used to provide
+ * spacing between widgets.
+ */
+
typedef struct txt_strut_s txt_strut_t;
#include "txt_widget.h"
-//
-// A strut is used to force a table to a minimum width/height. It is not
-// visible but it takes up space.
-//
-
struct txt_strut_s
{
txt_widget_t widget;
@@ -38,6 +41,13 @@ struct txt_strut_s
int height;
};
+/**
+ * Create a new strut.
+ *
+ * @param width Width of the strut, in characters.
+ * @param height Height of the strut, in characters.
+ */
+
txt_strut_t *TXT_NewStrut(int width, int height);
#endif /* #ifndef TXT_STRUT_H */