Quantcast WoWInterface - View Single Post - EquipCompare
Thread: EquipCompare
View Single Post
11-08-08, 11:17 AM   #9
A Murloc Raider
AddOn Author - Click to view addons
Join Date: Nov 2008
Posts: 6
Tooltip rendered (partially/completely) off screen fix for EquipCompare v2.13

Works with WoW v3.0.3:

The following code modifications should resolve most (if not all) issues with
wide comparative tooltip frames being displayed (partially or completely) off
screen. This change repositions dual comparative tooltip frames when there are
two slots that an item can be equipped in (ie, rings, trinkets, weapons). The
comparative tooltip frames will appear above/below one another instead of to
their left/right, but will still be rendered left/right of the main tootlip.

(1) line is moved
(2) lines are modified
(1) line is added

I recommend you copy/paste the "To" code below (without line numbers) over the
existing code in the EquipCompare.lua file.

Open the EquipCompare.lua file.

Change lines 1259-1267:

1259:	-- Now place it in its rightful place
1260:	ComparisonTooltip2:ClearAllPoints();
1261:	if ( leftAlign ) then
1262:		ComparisonTooltip1:ClearAllPoints();
1263:		ComparisonTooltip2:SetPoint("TOPRIGHT", tooltip:GetName(), "TOPLEFT", 0, -10);
1264:		ComparisonTooltip1:SetPoint("TOPRIGHT", "ComparisonTooltip2", "TOPLEFT", 0, 0);
1265:	else
1266:		ComparisonTooltip2:SetPoint("TOPLEFT", "ComparisonTooltip1", "TOPRIGHT", 0, 0);
1267:	end
		-- Now place it in its rightful place
		if ( leftAlign ) then
			ComparisonTooltip2:SetPoint("TOPRIGHT", tooltip:GetName(), "TOPLEFT", 0, -10);
			ComparisonTooltip1:SetPoint("TOPRIGHT", "ComparisonTooltip2", "BOTTOMRIGHT", 0, 0);
			ComparisonTooltip2:SetPoint("TOPLEFT", tooltip:GetName(), "TOPRIGHT", 0, -10);
			ComparisonTooltip1:SetPoint("TOPLEFT", "ComparisonTooltip2", "BOTTOMLEFT", 0, 0);
I am sure there are much more complicated, or maybe even some cleaner ways,
to accomplish similar changes to the relative frame layout that would yield
similar results. This just happens to be one of the quick and dirty methods.

One side effect I observed was that this change does not appear to
"work and play well" with the ALT button functionality.

Last edited by Thrashfinger : 11-08-08 at 11:38 AM.
  Reply With Quote