Added text alignment to conditional formats

Combo box for selecting the desired text alignment for a conditional
format.

The default alignment in the browser has been adjusted for numbers, which
are now aligned to the right as in spreadsheets.

Project file format updated.

See issues #1976 and #1815.
This commit is contained in:
mgrojo
2019-09-21 23:28:35 +02:00
parent 1ec502ae9b
commit c27002c301
8 changed files with 92 additions and 8 deletions

View File

@@ -442,6 +442,7 @@ void TableBrowser::addCondFormat(int column, const QString& value)
CondFormat newCondFormat(value, QColor(Settings::getValue("databrowser", "reg_fg_colour").toString()),
m_condFormatPalette.nextSerialColor(Palette::appHasDarkTheme()),
QFont(Settings::getValue("databrowser", "font").toString()),
CondFormat::AlignLeft,
m_browseTableModel->encoding());
m_browseTableModel->addCondFormat(column, newCondFormat);
browseTableSettings[currentlyBrowsedTableName()].condFormats[column].push_back(newCondFormat);