diff options
author | Michael Drake <tlsa@netsurf-browser.org> | 2013-02-08 15:26:24 +0000 |
---|---|---|
committer | Michael Drake <tlsa@netsurf-browser.org> | 2013-02-08 15:26:24 +0000 |
commit | 698f391289d8c53c19b170dd3b726314ba394826 (patch) | |
tree | 7dbfda126af35a680794b2f8045ca08018fa81e1 /desktop/textarea.h | |
parent | f57e89cc25e92c2ad4eb419e745955595248088b (diff) | |
download | netsurf-698f391289d8c53c19b170dd3b726314ba394826.tar.gz netsurf-698f391289d8c53c19b170dd3b726314ba394826.tar.bz2 |
Add scrollwheel support to textareas.
Diffstat (limited to 'desktop/textarea.h')
-rw-r--r-- | desktop/textarea.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/desktop/textarea.h b/desktop/textarea.h index 266b8356a..560f1ca28 100644 --- a/desktop/textarea.h +++ b/desktop/textarea.h @@ -219,5 +219,16 @@ void textarea_set_dimensions(struct textarea *ta, int width, int height); */ void textarea_set_layout(struct textarea *ta, int width, int height, int top, int right, int bottom, int left); + +/** + * Scroll a textarea by an amount. Only does anything if multi-line textarea + * has scrollbars. If it scrolls, it will emit a redraw request. + * + * \param ta textarea widget + * \param scrx number of px try to scroll in x direction + * \param scry number of px try to scroll in y direction + * \return true iff the textarea was scrolled + */ +bool textarea_scroll(struct textarea *ta, int scrx, int scry); #endif |