summaryrefslogtreecommitdiff
path: root/src/user/include/cxx/raleigh/w/entry.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/user/include/cxx/raleigh/w/entry.h')
-rw-r--r--src/user/include/cxx/raleigh/w/entry.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/user/include/cxx/raleigh/w/entry.h b/src/user/include/cxx/raleigh/w/entry.h
index 001cae2..c86b281 100644
--- a/src/user/include/cxx/raleigh/w/entry.h
+++ b/src/user/include/cxx/raleigh/w/entry.h
@@ -8,10 +8,15 @@ namespace raleigh {
class entry : public widget {
public:
//default_text's data is copied, so it's okay if it changes or if the memory is freed
- entry(uint32_t rows, uint32_t cols, const char *default_text="",
+ entry(uint32_t rows=25, uint32_t cols=25, const char *default_text="",
const char *font="fixed-10", _pixel_t bg=RGB(ff, ff, ff),
_pixel_t fg=RGB(00, 00, 00), _pixel_t border_color=RGB(00, 00, 00));
+ //not a copy
+ const char *get_contents();
+ //s's data is copied
+ void set_contents(const char *s);
+
void notify_window_change() override;
void paint(_pixel_t *pixbuf, uint32_t pitch) override;
void handle_click(coord window_coords, enum mouse_packet::mouse_button click_type, bool up) override;