aboutsummaryrefslogtreecommitdiff
path: root/src/ui/render/TextRenderObject.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/render/TextRenderObject.cpp')
-rw-r--r--src/ui/render/TextRenderObject.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/ui/render/TextRenderObject.cpp b/src/ui/render/TextRenderObject.cpp
index 18020032..c7803383 100644
--- a/src/ui/render/TextRenderObject.cpp
+++ b/src/ui/render/TextRenderObject.cpp
@@ -187,8 +187,7 @@ void TextRenderObject::Draw(platform::graphics::IPainter* painter) {
}
if (this->selection_range_.has_value()) {
- const auto&& rects =
- text_layout_->TextRangeRect(this->selection_range_.value());
+ const auto&& rects = text_layout_->TextRangeRect(*this->selection_range_);
for (const auto& rect : rects)
painter->FillRectangle(rect, this->GetSelectionBrush().get());
}