Added auto alignment for Align Text Columns

This commit is contained in:
Tercio Jose
2022-05-01 14:46:17 -03:00
parent 1490f47ac9
commit 08f78be505
7 changed files with 147 additions and 5 deletions
+8
View File
@@ -4597,6 +4597,14 @@ function _detalhes:FastPSUpdate (enabled)
end
function Details:AdjustInLineTextPadding()
for _, row in ipairs(self.barras) do
row.lineText2:SetPoint("right", row.statusbar, "right", -self.fontstrings_text2_anchor, 0)
row.lineText3:SetPoint("right", row.statusbar, "right", -self.fontstrings_text3_anchor, 0)
row.lineText4:SetPoint("right", row.statusbar, "right", -self.fontstrings_text4_anchor, 0)
end
end
-- search key: ~row ~bar ~updatebar
function _detalhes:InstanceRefreshRows (instancia)
+13
View File
@@ -1556,6 +1556,19 @@ do
desc = Loc ["STRING_OPTIONS_ALIGNED_TEXT_COLUMNS_DESC"],
},
{--inline auto align enabled
type = "toggle",
get = function() return currentInstance.use_auto_align_multi_fontstrings end,
set = function (self, fixedparam, value)
editInstanceSetting(currentInstance, "use_auto_align_multi_fontstrings", value)
editInstanceSetting(currentInstance, "InstanceRefreshRows")
_detalhes:RefreshMainWindow(-1, true)
afterUpdate()
end,
name = Loc ["STRING_OPTIONS_ALIGNED_TEXT_COLUMNS_AUTOALIGN"],
desc = Loc ["STRING_OPTIONS_ALIGNED_TEXT_COLUMNS_AUTOALIGN_DESC"],
},
{--lineText2 (left, usuali is the 'done' amount)
type = "range",
get = function() return tonumber (currentInstance.fontstrings_text2_anchor) end,