Fix T99373: add some padding in spreadsheet vector columns

This improves readability in some cases (e.g. in T99373).
This commit is contained in:
Jacques Lucke 2022-07-26 12:35:55 +02:00
parent b08c5381ac
commit c5712c6795
Notes: blender-bot 2023-02-14 00:09:06 +01:00
Referenced by issue #99373, Spreadsheet column should add 1 letter space between column when vector value reach 6 digits + 1 decimal
1 changed files with 2 additions and 2 deletions

View File

@ -287,7 +287,7 @@ class SpreadsheetLayoutDrawer : public SpreadsheetDrawer {
for (const int i : values.index_range()) {
std::stringstream ss;
const float value = values[i];
ss << std::fixed << std::setprecision(3) << value;
ss << " " << std::fixed << std::setprecision(3) << value;
const std::string value_str = ss.str();
uiBut *but = uiDefIconTextBut(params.block,
UI_BTYPE_LABEL,
@ -318,7 +318,7 @@ class SpreadsheetLayoutDrawer : public SpreadsheetDrawer {
for (const int i : values.index_range()) {
std::stringstream ss;
const float value = values[i];
ss << std::fixed << std::setprecision(3) << value;
ss << " " << std::fixed << std::setprecision(3) << value;
const std::string value_str = ss.str();
uiBut *but = uiDefIconTextBut(params.block,
UI_BTYPE_LABEL,