editint.h
Go to the documentation of this file.00001
00039
00040
00041
00042
00043
00044
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058 #ifndef DT_EDITINT_H
00059 #define DT_EDITINT_H
00060
00061 #include <dt/dwidget.h>
00062 #include <dt/dtag.h>
00063 #include <drv/lcd_text.h>
00064
00065 #include <cfg/compiler.h>
00066 #include <cfg/macros.h>
00067
00068
00069 #define EDIS_DEFAULT 0
00070 #define EDIS_CURSORLEFT BV(0)
00071 #define EDIS_WRAP BV(1)
00072
00074 typedef uint16_t dstyle_t;
00075
00076 typedef struct DEditInt
00077 {
00078 DWidget widget;
00079
00080 int *value;
00081 int min;
00082 int max;
00083 dstyle_t style;
00084 void (*draw)(struct DEditInt *);
00085
00086 } DEditInt;
00087
00088 void editint_init(DEditInt *e, dpos_t pos, dpos_t size, dcontext_t *context, int *value, int min, int max);
00089 void editint_update(DEditInt *e, dtag_t tag, dval_t val);
00090 void editint_draw(DEditInt *e);
00091
00092 #endif