aboutsummaryrefslogtreecommitdiff
path: root/scene/gui
diff options
context:
space:
mode:
authorGeequlim2017-05-27 14:07:18 +0800
committerGeequlim2017-05-27 14:07:18 +0800
commitcd778e00dc5362d00d4760c79fc301951f6f9b75 (patch)
treebf1fc27dc453ce6a9e2fd30d6e296956646cb160 /scene/gui
parent441196a52c80b2bdbd56519f4da45ee589609afe (diff)
downloadgodot-cd778e00dc5362d00d4760c79fc301951f6f9b75.tar.gz
godot-cd778e00dc5362d00d4760c79fc301951f6f9b75.tar.zst
godot-cd778e00dc5362d00d4760c79fc301951f6f9b75.zip
Fix text warp in color blocks with CJK
Diffstat (limited to 'scene/gui')
-rw-r--r--scene/gui/rich_text_label.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/gui/rich_text_label.cpp b/scene/gui/rich_text_label.cpp
index 85ab3ffda..8b551ab0b 100644
--- a/scene/gui/rich_text_label.cpp
+++ b/scene/gui/rich_text_label.cpp
@@ -264,7 +264,7 @@ void RichTextLabel::_process_line(ItemFrame *p_frame, const Vector2 &p_ofs, int
cw = tab_size * font->get_char_size(' ').width;
}
- if (end > 0 && w + cw + begin > p_width) {
+ if (end > 0 && w + cw + wofs > p_width) {
break; //don't allow lines longer than assigned width
}