mirror of
https://git.mirrors.martin98.com/https://github.com/bambulab/BambuStudio.git
synced 2025-09-21 04:23:15 +08:00
FIX: used filament character occlusion in multilingual
JIRA: SUTDIO-6587 Signed-off-by: Kunlong Ma <kunlong.ma@bambulab.com> Change-Id: I68940a4237b0e952cee85c2c01886b52c144cfbc
This commit is contained in:
parent
d7ab35000a
commit
179191eefe
@ -4604,8 +4604,17 @@ void GCodeViewer::render_legend(float &legend_height, int canvas_width, int canv
|
|||||||
if (title_columns[i].first == "") {
|
if (title_columns[i].first == "") {
|
||||||
offsets.push_back(offsets.back() + max_width(title_columns[i - 1].second, "") + style.ItemSpacing.x);
|
offsets.push_back(offsets.back() + max_width(title_columns[i - 1].second, "") + style.ItemSpacing.x);
|
||||||
}
|
}
|
||||||
|
else if (title_columns[i].first == _u8L("Display")) {
|
||||||
|
float length = ImGui::CalcTextSize(title_columns[i - 2].first.c_str()).x;
|
||||||
|
float offset = offsets.back() + max_width(title_columns[i - 1].second, title_columns[i - 1].first);
|
||||||
|
size_t index = offsets.size() - 2;
|
||||||
|
if (index >= 0) {
|
||||||
|
offset = std::max(offset, length + offsets[index]);
|
||||||
|
}
|
||||||
|
offsets.push_back(offset + 2.0f * style.ItemSpacing.x);
|
||||||
|
}
|
||||||
else {
|
else {
|
||||||
offsets.push_back(offsets.back() + max_width(title_columns[i - 1].second, title_columns[i - 1].first) + style.ItemSpacing.x);
|
offsets.push_back(offsets.back() + max_width(title_columns[i - 1].second, title_columns[i - 1].first) + 2.0f * style.ItemSpacing.x);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user