mirror of
https://github.com/godotengine/godot.git
synced 2025-10-31 21:51:22 +00:00
Use compile-time Unicode string conversion
Thanks to this syntax introduced in C++11, this reduces the amount of work that needs to be performed at run-time while making the code more terse.
This commit is contained in:
parent
16a93563bf
commit
e9f723006a
11 changed files with 19 additions and 19 deletions
|
|
@ -119,8 +119,8 @@ void VoxelGIEditorPlugin::_notification(int p_what) {
|
|||
}
|
||||
|
||||
String text;
|
||||
text += vformat(TTR("Subdivisions: %s"), vformat(String::utf8("%d × %d × %d"), cell_size.x, cell_size.y, cell_size.z)) + "\n";
|
||||
text += vformat(TTR("Cell size: %s"), vformat(String::utf8("%.3f × %.3f × %.3f"), half_size.x / cell_size.x, half_size.y / cell_size.y, half_size.z / cell_size.z)) + "\n";
|
||||
text += vformat(TTR("Subdivisions: %s"), vformat(U"%d × %d × %d", cell_size.x, cell_size.y, cell_size.z)) + "\n";
|
||||
text += vformat(TTR("Cell size: %s"), vformat(U"%.3f × %.3f × %.3f", half_size.x / cell_size.x, half_size.y / cell_size.y, half_size.z / cell_size.z)) + "\n";
|
||||
text += vformat(TTR("Video RAM size: %s MB (%s)"), String::num(size_mb, 2), size_quality);
|
||||
|
||||
// Only update the tooltip when needed to avoid constant redrawing.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue