add a method to textbox
a method to get bounds of a text selection
This commit is contained in:
@@ -469,6 +469,18 @@ namespace drawerbase {
|
||||
API::update_window(*this);
|
||||
}
|
||||
|
||||
std::pair<upoint, upoint> textbox::selection() const
|
||||
{
|
||||
std::pair<upoint, upoint> points;
|
||||
|
||||
internal_scope_guard lock;
|
||||
auto editor = get_drawer_trigger().editor();
|
||||
if (editor)
|
||||
editor->get_select_points(points.first, points.second);
|
||||
|
||||
return points;
|
||||
}
|
||||
|
||||
void textbox::copy() const
|
||||
{
|
||||
internal_scope_guard lock;
|
||||
|
||||
Reference in New Issue
Block a user