Skip to content

A fast 2D and 3D game engine — TypeScript SDK, C++/WebAssembly core, visual editor. Ship one project to web, desktop, WeChat MiniGames, playable ads, and native Android / iOS.

test(text): verify scene exercises multi-line + center align + rich text (REARCH_GUI P1.4c)

esengine883ad6df07a5
diff --git a/desktop/public/scenes/ui-text-sdf.esscene b/desktop/public/scenes/ui-text-sdf.esscene
index 7b1e5f3cd..7d33d90f4 100644
--- a/desktop/public/scenes/ui-text-sdf.esscene
+++ b/desktop/public/scenes/ui-text-sdf.esscene
@@ -19,16 +19,19 @@
"parent": null,
"children": [],
"components": [
- { "type": "Transform", "data": { "position": { "x": -220, "y": 0, "z": 0 } } },
+ { "type": "Transform", "data": { "position": { "x": -150, "y": 45, "z": 0 } } },
{
"type": "UIText",
"data": {
- "content": "Ag Hi 文字",
+ "content": "Ag Hi 文字\n<b>SDF</b> <color=#ff5050>rich</color>",
"fontFamily": "sans-serif",
- "fontSizePx": 72,
+ "fontSizePx": 64,
"color": { "r": 1, "g": 1, "b": 1, "a": 1 },
"style": 0,
- "layer": 0
+ "layer": 0,
+ "richText": true,
+ "align": 1,
+ "lineHeight": 0
}
}
],