Mercurial > wow > ouroloot
changeset 46:0b1e703a6954
Make sure tab row fills width.
author | Farmbuyer of US-Kilrogg <farmbuyer@gmail.com> |
---|---|
date | Sat, 21 Jan 2012 01:39:44 +0000 |
parents | 1001dd95dbeb |
children | 1070a14cfee4 |
files | gui.lua |
diffstat | 1 files changed, 6 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/gui.lua Fri Jan 20 11:48:38 2012 +0000 +++ b/gui.lua Sat Jan 21 01:39:44 2012 +0000 @@ -360,8 +360,13 @@ g_generated = nil tabgroup_tabs = {} window_title = "Ouro Loot " .. self.revision + -- TabGroup stretches out the tabs to fill the row but only if >75% of the + -- row is already full. It turns out that not doing this looks like ass. + -- If we won't have enough tabs to trigger this on its own, pad out the tab + -- titles (not looking quite as nice, ah well) to force it to trigger. + local fmtstr = #_taborder > 6 and "%s" or " %s " for _,v in ipairs(_taborder) do - tinsert (tabgroup_tabs, {value=v, text=_tabtexts[v].title}) + tinsert (tabgroup_tabs, {value=v, text=fmtstr:format(_tabtexts[v].title)}) -- By default, tabs are editboxes with generated text if not tabs_OnGroupSelected[v] then tabs_OnGroupSelected[v] = tabs_generated_text_OGS