if(multiline)
check_view_range();
-
- rebuild();
-}
-
-void Entry::set_edit_position(unsigned pos)
-{
- edit_pos = min(pos, text.size());
- selection_active = false;
-
- if(multiline)
- check_view_range();
-
rebuild();
}
selection_pos = edit_pos;
selection_active = select;
- edit_pos = ep;
- check_view_range();
+ edit_pos = min(ep, text.size());
+ if(multiline)
+ check_view_range();
rebuild();
}
void erase(unsigned, unsigned);
const std::string &get_text() const { return text.get(); }
- void set_edit_position(unsigned);
+ void set_edit_position(unsigned p) { set_edit_position(p, false); }
unsigned get_edit_position() const { return edit_pos; }
bool get_selection(unsigned &, unsigned &) const;