fix bug that single-line text_editor still shows scrollbar

This commit is contained in:
Jinhao
2017-07-20 23:44:03 +08:00
parent 0d99cb26dc
commit d53254b89a
3 changed files with 42 additions and 7 deletions

View File

@@ -40,6 +40,11 @@ namespace skeletons
public:
using graph_reference = paint::graphics&;
enum class scrolls
{
none, horz, vert, both
};
struct events_type
{
::std::function<void(const point&)> hover_outside;
@@ -51,6 +56,8 @@ namespace skeletons
events_type& events();
bool enable_scrolls(scrolls which);
void step(unsigned step_value, bool horz);
bool scroll(bool forwards, bool horz);
bool turn_page(bool forwards, bool horz);