浏览代码

make Label consider spaces for visible_characters

wingedadventurer 5 年之前
父节点
当前提交
695980a0f2
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      scene/gui/label.cpp

+ 1 - 0
scene/gui/label.cpp

@@ -225,6 +225,7 @@ void Label::_notification(int p_what) {
 					return;
 				}
 				if (from->space_count) {
+					chars_total += from->space_count;
 					/* spacing */
 					x_ofs += space_w * from->space_count;
 					if (can_fill && align == ALIGN_FILL && spaces) {