浏览代码

Remove spaces from input of HTML color in color picker

Fixes #79338
guemax 2 年之前
父节点
当前提交
d934d00828
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      scene/gui/color_picker.cpp

+ 1 - 1
scene/gui/color_picker.cpp

@@ -559,7 +559,7 @@ void ColorPicker::_html_submitted(const String &p_html) {
 	}
 
 	const Color previous_color = color;
-	color = Color::from_string(p_html, previous_color);
+	color = Color::from_string(p_html.strip_edges(), previous_color);
 
 	if (!is_editing_alpha()) {
 		color.a = previous_color.a;