summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-07-10 13:29:47 +0200
committerGitHub <noreply@github.com>2019-07-10 13:29:47 +0200
commit6b6911cf11c279fc5133ffcb578e63168248af0d (patch)
tree8824c2d026277b316f26e89ffa88a7c02f3e68e3
parentf71a7943596751296ff7738d2169540e2e5fe204 (diff)
parent94d542042ebb22c8120883b8403eade2110050b9 (diff)
Merge pull request #30483 from kawa-yoiko/linelen-guideline-hinting
Fix incorrect X position of line length guideline
-rw-r--r--scene/gui/text_edit.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/gui/text_edit.cpp b/scene/gui/text_edit.cpp
index 7a937843ab..ff0c723141 100644
--- a/scene/gui/text_edit.cpp
+++ b/scene/gui/text_edit.cpp
@@ -683,7 +683,7 @@ void TextEdit::_notification(int p_what) {
}
if (line_length_guideline) {
- int x = xmargin_beg + cache.font->get_char_size('0').width * line_length_guideline_col - cursor.x_ofs;
+ int x = xmargin_beg + (int)cache.font->get_char_size('0').width * line_length_guideline_col - cursor.x_ofs;
if (x > xmargin_beg && x < xmargin_end) {
VisualServer::get_singleton()->canvas_item_add_line(ci, Point2(x, 0), Point2(x, size.height), cache.line_length_guideline_color);
}