diff --git a/api/cooldown.lua b/api/cooldown.lua index 2b0ded1a..477d6575 100644 --- a/api/cooldown.lua +++ b/api/cooldown.lua @@ -85,7 +85,7 @@ local function SetupCooldown(cooldown) cooldown:SetReverse(kind == "aura") cooldown:SetMinimumCountdownDuration(kind == "spell" and tonumber(C.cooldown.threshold) * 1000 or 0) cooldown:SetCountdownFormatter(GetFormatter()) - UpdateFont(cooldown, cooldown:GetParent():GetHeight()) + UpdateFont(cooldown, cooldown:GetParent():GetUnscaledHeight()) end -- applies the "foreign" timers to another addon's cooldown. They only take @@ -107,7 +107,7 @@ local function SetupForeign(cooldown) cooldown:SetMinimumCountdownDuration(tonumber(C.cooldown.threshold) * 1000) cooldown:SetCountdownFormatter(GetFormatter()) - UpdateFont(cooldown, (cooldown:GetParent() or cooldown):GetHeight()) + UpdateFont(cooldown, (cooldown:GetParent() or cooldown):GetUnscaledHeight()) end -- runs as a pfUI cooldown's timer starts: a timer with a total brings back diff --git a/api/ui-widgets.lua b/api/ui-widgets.lua index 50a6aa67..0f912eb7 100644 --- a/api/ui-widgets.lua +++ b/api/ui-widgets.lua @@ -601,7 +601,7 @@ function pfUI.api.SkinDropDown(frame, cr, cg, cb, useSmall) button:HookScript("OnClick", function() local DropDownListWidth = DropDownList1:GetWidth() - local DropDownFrameWidth = frame.backdrop:GetWidth() + local DropDownFrameWidth = frame.backdrop:GetUnscaledWidth() if DropDownListWidth < DropDownFrameWidth then local diff = DropDownFrameWidth - DropDownListWidth DropDownList1:SetWidth(DropDownList1:GetWidth() + diff) diff --git a/api/unitframes.lua b/api/unitframes.lua index 37f27ca3..be7f7548 100644 --- a/api/unitframes.lua +++ b/api/unitframes.lua @@ -2042,7 +2042,7 @@ function pfUI.uf:RefreshUnit(unit, component) local size if disptype == "4" or disptype == "3" then - size = unit.hp.bar:GetHeight() * tonumber(unit.config.debuff_ind_size) + size = unit.hp.bar:GetUnscaledHeight() * tonumber(unit.config.debuff_ind_size) if size ~= indicator.size or disptype ~= indicator.disp or indipos ~= indicator.ipos then indicator:ClearAllPoints() indicator:SetPoint(indipos, 0, 0) @@ -2447,7 +2447,7 @@ function pfUI.uf:AddIcon(frame, pos, icon, timeleft, stacks, start, duration) if not frame.hp then return end local frame = frame.hp.bar - if pos > 6 or pos > ceil(frame:GetWidth() / iconsize) then return end + if pos > 6 or pos > ceil(frame:GetUnscaledWidth() / iconsize) then return end frame.icon = frame.icon or CreateFrame("Frame", nil, frame) diff --git a/modules/castbar.lua b/modules/castbar.lua index cceb5ba1..6c05dcde 100644 --- a/modules/castbar.lua +++ b/modules/castbar.lua @@ -86,7 +86,7 @@ pfUI:RegisterModule("castbar", function () -- Per-craft spark position: the current craft's share of the bar's width. -- Snaps back to the left edge each time StartTradeskillCraft restarts it. local function MoveSpark() - local x = this.craft:GetElapsedPercent() * this.bar:GetWidth() - 1 + local x = this.craft:GetElapsedPercent() * this.bar:GetUnscaledWidth() - 1 this.bar.spark:SetPoint("TOP", this.bar, "TOPLEFT", x, 0) this.bar.spark:SetPoint("BOTTOM", this.bar, "BOTTOMLEFT", x, 0) end diff --git a/modules/combatlog.lua b/modules/combatlog.lua index 4932aa08..8722b93c 100644 --- a/modules/combatlog.lua +++ b/modules/combatlog.lua @@ -2509,13 +2509,7 @@ pfUI:RegisterModule("combatlog", function () local buttonName, button, textWidth; local buttonIndex = 1; -- subtract the width of the dropdown button - local clogleft, clogright = COMBATLOG:GetRight(), COMBATLOG:GetLeft(); - local maxWidth; - if ( clogleft and clogright ) then - maxWidth = (COMBATLOG:GetRight()-COMBATLOG:GetLeft())-31; --Hacky hacky because GetWidth goes crazy when it is docked - else - maxWidth = COMBATLOG:GetWidth() - 31; - end + local maxWidth = COMBATLOG:GetUnscaledWidth() - 31; local additionalFilterButton = CombatLogQuickButtonFrame.AdditionalFilterButton; diff --git a/modules/gui.lua b/modules/gui.lua index e2cda286..77a325b7 100644 --- a/modules/gui.lua +++ b/modules/gui.lua @@ -78,7 +78,7 @@ pfUI:RegisterModule("gui", function () -- basic frame local frame = CreateFrame("Frame", nil, this) - frame:SetWidth(this.parent:GetRight()-this.parent:GetLeft()-20) + frame:SetWidth(this.parent:GetUnscaledWidth()-20) frame:SetHeight(22) frame:SetPoint("TOPLEFT", this, "TOPLEFT", 5, (this.objectCount*-23)-5) diff --git a/modules/marktracking.lua b/modules/marktracking.lua index 09a5485f..2c78b697 100644 --- a/modules/marktracking.lua +++ b/modules/marktracking.lua @@ -41,7 +41,7 @@ pfUI:RegisterModule("marktracking", function () local function ShortenName(name, row) if not name or name == "" then return "" end - local barWidth = row.health:GetWidth() + local barWidth = row.health:GetUnscaledWidth() if barWidth < 1 then barWidth = BAR_WIDTH end local available = barWidth - 4 if rm_showpct then available = available - 32 end