PitBull4

It's mostly done, but not entirely done thus why there are still only betas (despite this it is still very stable).

Documentation is written before functions

Much easier for third-party extensions.

Options will be much, much simpler. In 3.0, there's about 200 panels that you can mess with, it's overwhelming. I want to bring this down to somewhere around 10.

Layouts are defined deterministically and unit groups use the layout rather than ad-hoc layouts on a per-unit basis. This will make setting up your unit frames far, far easier.

Due to some decisions made, 4.0 is actually more configurable than 3.0. As a layout designer, you will have a lot more control over how things look. You can have different fonts on the same frame, different textures, more precise positioning, and a whole slough of other things.

CPU Efficiency will be taken much more seriously.

It uses Ace3 instead of Rock.

FAQ: http://www.wowace.com/addons/pitbull4/pages/faq/.

Guide: http://www.wowace.com/addons/pitbull4/pages/guide/.

If you want to help localize PitBull in your language, go to http://www.wowace.com/projects/pitbull4/localization/.

Shefki:
- This commit should fully fix the problems people have been having with SetFont() errors. If the font returned from GetFont is nil then use our cached font and size. Size whenever font is nil will be an uninitialized value and so the existing fix would still throw errors when the size ended up being less than or equal to 0.
- It doesn't make sense to call GetFont on a new FontString. The flags should not be preserved, so just set the font and size and leave the flags as "". The AddFontString call later will set the flags properly. If the font string already exists then you want to preserve the flags.
- Fix some typos that were fixed on nebula1169's branch.
- Remove some values I set to help debugging ticket #1050.
- Hopefully avoid the SetFont errors for sure now assuming that the problem is that GetFont() doesn't work immediately after a SetFont() while the game is still loading in.
- Missed wrapping a geterrorhandler() in pcall().
- Protect against Blizzard's error handler throwing an error, which is why the protection code didn't allow the frames to work even when the SetFont error was happening.
- Stash the DEFAULT_FONT and DEFAULT_FONT_SIZE so I can get people having the font problem to show me what's being stored.
- Wrap the SetFont and SetAlpha calls in pcalls() which should prevent errors with them from breaking frames entirely.
- Make the Vengeance fix backwards compatible.
Benjamin Staneck:
- use a different ID for vengeance that works in 5.4
Shefki:
- Remove unnecessary constants that I added on accident.
- Hopefully stop some rare errors in LuaTexts about SetFont.

Shefki:
- Fix a long standing bug in ComboPoints where the icons changed size based on other settings. Without the new support for a background this never showed up except in vertical mode, however in vertical mode the icons would get smaller as more points were earned. With the new background horizontal mode icons would be smaller when the background was enabled.
Players using vertical mode may need to adjust the size of the
ComboPoints smaller, now that the bug has been fixed and the icons are
displaying at the configured size.
- Fix issue with Eridius' patch that breaks vertical mode without backgrounds.
- Apply Eridius' background for Combo Points patch.
- Missed adding BattlePet to the embeded modules list.
- Fix missing modules from the embedded module list.
- Fix the PvPIcon module when used with an unaligned Pandaren. This was breaking config mode for those characters.
Benjamin Staneck:
- lets let the checkout copy load modules, too.
Shefki:
- Revert "apply combopoint patch by Eridius (ticket 1046)" See my reasoning on the ticket.
This reverts commit 267d2d9b7734d4c6aa7f2113c5782d6e115276eb.
Benjamin Staneck:
- apply combopoint patch by Eridius (ticket 1046)

--------------------
Shefki:
- Oops duplicated a line unintentionally.
- Add support for warlock green fire to the BurningEmbers module.
- Set the extra2 value to 0 for other bar modules (prevents ghost extra values from showing up when bars get reused).
- Add support for showing absorbs in the VisualHeal module.
- Add a 2nd extra bar to BetterStatusBar.
- Return to old style menus for raid frames since Blizzard has a bug in the new menu system. Includes a somewhat ugly hack around Clique forcing the use of the new menu system.
- Display friendships properly in the ReptutationBar & LuaTexts.
- Remove pre-5.1 compatibility from Aura Filters.
- Remove pre 5.1 support from Chi module.
- Remove pre-mop compatibility from UnitFrame.lua
Conflicts:

Shefki:
- Handle auras that have been removed in 5.2
- Missed removing an end.
- Finish removing pre-MOP compat from the Aura Filters.
- Fix a typo and a column indentation.
- Remove some parens that aren't really needed.
Benjamin Staneck:
- I'm in your toc, updating your Interface Version to 50200.
- more cleaning
- I like commas
- more spring cleaning in the filter area
- remove some old compat code. I want to cry.
- exclude some dev only files/folders from being packaged
- fix the attempt to call field 'GetBestUnitID' (a nil value) error on 5.2.

Shefki:
- Add Tooth and Claw to Druid Self Buff Aura Filter in 5.1.x
- Put LibDualSpec back to latest tag rather than alpha/beta release since it has a 5.x stable release now.
- TOC bump for 5.1.x
- Backwards compatability for 5.0.x in Chi module.
- Remove Aspect of the Fox with WoW 5.1 from the Aura Filters.
Benjamin Staneck:
- SPELL_POWER_CHI is the new SPELL_POWER_LIGHT_FORCE, no backwards compat, have fun Shefki :D
Shefki:
- Give the Rage of Anger a red power bar.
Specifically map POWER_TYPE_RED_POWER to RAGE since they both translate
to Rage.
- Change the default to not hide Blizzard's AltPowerBar.
If you want it hidden you'll have to toggle it back hidden by doing:
/pb, Modules, Hide Blizzard, check Alternate power.

Shefki:
- Fix Ticket #1005, Leader Icon does not hide after leaving a group.
- LuaTexts: DruidForm(): Fix Moonkin and Flight Form detection.
- Fix a typo
- Flip some if then elseif blocks around so the most common conditions come first.
- The model frame alpha bug applies to the dress up model frame as well.
- Fix Ticket #600: Performance issue with pirate day easter egg.
I just disabled the dress up model usage in combat. It seems to avoid
the problem with lag due to the use of that model since the lag is
caused by the creation of new models. If you're raiding or doing a
dungeon your group is still going to show as pirates since their
portrait will get drawn out of combat generally.
- Fix flickering Portraits on some frames.
The original fix that I'd made for the issue that happened after a scale
or shape change was wrong. The real problem was in our anchor code. So
I've reverted that change here. That hack was ultimately causing the
flashing since the effective scale code was triggering on some frames
everytime.

The real problem behind the scale/shape change was that the layout code
assumed that GetHeight/Width returned the value passed to
SetHeight/Width after a ClearAllPoints, which it does not if the
previous anchors changed the size of the frame. The fix for this is to
set a temporary bogus anchor to allow access to these values. I'm not
100% thrilled with the solution to this, but I think the alternatives
get even more ugly. The layout code does run in combat, so I'll likely
review this change again.

Shefki:
- Oops left some debug code turned on that I'd uncommented to diagnose the sound issue.
- Fix sounds for totem destruction.
No idea why this code was looking for haveTotem as true for totems that
had been removed. Also I see no reason to iterate frames since the
Activate/Deactivate functions do that. I'm guessing this was added
to support MyGetTotemInfo which I also see no reason to use. Should
make the module more efficient.
- Add Fel Energy power type.
- Allow localization for Latin American Spanish, Italian, and Brazilian Portuguese.
- Fix vanishing layouts and groups.
If layouts or groups were left fully at their defaults they would
disappear on logout or reload. This resolves this by adding an
exists flag to their config entries. There is now a config_version
flag in the config DB and a functional process to upgrade the config.

Conflicts:

Main.lua
- Fix the translation for the Highlight module texture description.
- Remove a number of table lookups that were unnecessary on loading.
- Allow the texture of the Highlight module to be changed. Fixes ticket #1000
This uses the background textures from SharedMedia. I added two default
Blizzard textures to the background options since they're useful.

QuestTitleHighlight is the current default and has a yellow tint to it.
QuestLogTitleHighlight is similar but has no tint.
- Fix bug in double_fill_table function that wasn't really hurting anything.
- Fix the error about Totem slot must be in the range of 1 to 4.
Appears that when zoning between cross realm zones and non-cross realm
zones we get a PLAYER_TOTEM_UPDATE for slot 5 that doesn't exist. It's
a bug on Blizzard's end but we can workaround it by ignoring the event.

Reported to Blizzard here:
http://us.battle.net/wow/en/forum/topic/6490460422#1
- Disable vehicle swaps when they shouldn't happen, since the game has specified not to.
Note: This is a complete fix the secure code has a bug and click on the
unit will still target the wrong unit. Bug has been reported to
Blizzard. Generally this shouldn't be a playability issue since click
on the player frame shouldn't be necessary during these events/quests.
- Fix issue where you only see the top of the Portrait in 3D mode.
Looks like the model frame no longer sets the position back to the
default when changing models.
- Cleanup some unnecessary global variables.
PitBull4 should not be setting any global variable other than the
PitBull4 table, the SLASH_PITBULLFOUR* global variables and
UI_DROPDOWNMENU_MENU_LEVEL as necessary for interfacing with Blizzard's
API.

Shefki:
- Change the default color for the AltPowerBar to match what Blizzard uses in their raid frames.
- Update the logic for the AltPowerBar to avoid showing it when the game has flagged not to.
- Fix an error in the AlterPowerBar module that would make it show incorrect info for alternate powers where the minimum wasn't zero.
- Fix the typo in the AltPowerBar that someone I reverted again. Oops.
- Implement aura filters fully for Monk.
- Refix party and raid config mode after adding hiding of frames for pet battles.
When I yanked the old ForceShow code I forgot to leave it in place for
the Group frames.
- Handling hiding the frames during pet battles.
This also lays the ground work for user configured macro conditionals
for hiding/showing the frames.
- Prevent an error when the fader module starts trying to update before the layoutdb is loaded for the frame.

Shefki:
- Remove some config options that don't do anything in the SoulShard module.
- Fix issue that would break ShadowOrb module after changing profiles.
Same issue as HolyPower module had.
- Fix problem with Chi module not updating after a profile change.
Same problem as HolyPower module.
- Fix problem with HolyPower module no long updating correctly after changing profiles.
In particular it would update before the profile had been completely loaded and then the color would be stuck on black.
- Show Totem module for DK's without a spec picked.
- Improve the graphics for the Monk Chi module.
- Arcane Charge shows up as a debuff, move under the self debuffs filter.
- Refresh frame layouts after the group headers are done on profile changes. Should prevent some odd edge cases with changing profiles with different configs on the same group header.
- Fix some places where we could end up comparing a number with nil.

Shefki:
- Fix background on the BurningEmbers module when set to vertical.
- Fix the background on the HolyPower module when set to vertical.
- Fix two typos. One leaked a global variable. Both prevented LuaTexts from knowing if a spell was interruptible or not.
- Fix a leak of the global variable _ in Portrait module, which also breaks the Glyph UI due to a Blizzard bug.
Only occured when class was the portrait type or fallback type.
- Fix a typo that leaked a global variable and that actually broke the OnUpdate throttling for the Aura module.
- Fix leak of player_in_group variable into global namespace.
Another case of me testing and forgetting to put back to local after
modifying for 5.0.
- Fix master_looter_guid leaking into the global namespace.
I removed the local while testing this and I forgot to put it back when
I finished updating the module for 5.0.
- Add Rapid Teleportation to Mage self buffs.

Shefki:
- Workaround a bug in the SecureGroupHeaders where anchors are not set properly. Shows up as frames being sized incorrectly, may be seen when switching between configurations or profiles with different growth directions.
Problem here is that SecureGroupHeaders configureChildren function does
not ClearallPoints on frames that exist and are in use. So changing the
growth direction of a used frame breaks the children.
- Update HideBlizzard module for 5.0.4 (only would have created problems if you were toggling them on and off without reloading).
Removed some support for pre 4.3 WoW.

Shefki:
- Fix a typo in the name of the Mage enemy debuffs filter.
- Expose the Mage and Hunter friend debuffs filters that were added but not enabled in the default filters.
- Fix typo in DemonicFury module description.
- TOC Bump for 5.0.4
- Some more pre-Cataclysm aura filters I missed removing.
- Update aura filters for Warrior in MoP.
Remove pre-Cataclysm support.
- Update aura filters for Warlock in MoP.
Remove pre-Cataclysm support.
- Update aura filters for Shaman in MoP.
Remove pre-Cataclysm support.
- Adjust aura filters for Rogue in MoP.
Remove pre-Cataclysm support.
- Update aura filters for Priest in MoP.
Remove pre-Cataclysm support.
- Fix HolyPower module to properly work with Boundless Convinction in 5.x.
- Update Aura filters for Paladin.
Remove pre-Cataclysm support.
- Mage aura filters for MoP.
Also removes pre-Cataclysm support.
- Update Hunter aura filters for MoP.
Remove support for pre-Cataclysm as well.
- Major rework of Druid filters for MoP.
Removes support for pre Cata as well.
- Make LuaTexts handle the switch to GROUP_ROSTER_UPDATE event transparently for users.
- Remove some pre-Cataclysm compat code that's way obsolete for all regions.
- Fill in the buffs/debuffs from Hunter Pets.
Filled in from Petopia topic here:
http://forums.wow-petopia.com/viewtopic.php?f=39&t=18086
- Adjust the indentation in Filter.lua for 6 digit spell ids.
- Still Water from Hunter pets is new for MoP, flag it as such.
- Update Aura Filters for major important Buffs/Debuffs
Thanks to WowHead for throwing this together:
http://www.wowhead.com/guide=1100
- Better graphics for ShadowOrb module.
Benjamin Staneck:
- Use the real Shadow Orbs icon and delete the dummy file.
Shefki:
- First pass at Death Knight auras for MoP.
Only 10 more classes to do...
- Enable Totem module for Monks. Don't show totem frame except on specs that use it for classes other than Shaman.
- Workaround a bug in the Blizzard model frame that doesn't properly update the frame after the scale or shape changes.
- Enable totem module for Druids and Deathknights.
This probably needs some more work to make it less confusing, but it at
least exposes the functionality to players.
- Fix Male Worgen portraits and probably a lot of other models that were coded weird.
Switch to using SetPortraitZoom which seems to work more often than SetCamera did.
- Fix typo causing GetSpellinfo error (Paladins, MoP)
- Fix bug #946 - Debuffs for Rogue and Paladin Seal of Truth missing.
- Fix bug #965 - Missing auras for Shaman.
- Remove Find Treasure from Dwarfs.
- Fix a typo in the purge logic for Warrior.
- Update dispel logic for MoP and split offensive dispels into new purge logic. New highlight filter "Highlight: purgeable by me buffs" added to default config.
- Add Worgen, Goblin and Pandaren to Aura filters.
Apparently I forgot to come back and do Worgen and Goblin in Cataclysm.
Oops!
- Add dispelable logic for Monk.
- Add Monk to the Aura filters.
- Fix a comment.
- Rename a variable that happens to be the same as a function.
Wasn't hurting anything but I noticed it while figuring out why the
module wasn't working.
- Fix a long standing typo in the AltPowerBar module that made it not work correctly.
- Update RangeFader to support MoP and remove some dead code for pre-4.x.
- Tired of fighting the launcher and its perms. Just give in and commit them to git.
- Put an end to the warnings about unknown auras in MoP.
Filters still need work but this should stop the annoying spam on login.
- Remove player level check from Chi module. Blizzard removed their code and the constant.
- Remove a line that was unnecessary from the BurningEmbers code.
Benjamin Staneck:
- We're talking embers here, not holy powerz
- Don't load on live
Shefki:
- Forgot to add BattlePet module to .pkgmeta.
- Add BattlePet module for showing an icon for the battle pet type in MoP.
- Add support for community tapped mobs in MoP.
- Support up to 4 embers like Blizzard's code does in the Burning Embers module.
- Update .pkgmeta for BurningEmbers and DemonicFury modules.
- Add Burning Embers module for MoP.
- Update SoulShards module for MoP.
- Add Demonic fury module for MoP.
- Fix that I unintentially disabled ranged weapon enchants on live.
- Fix Bug #990 GetInventorySlotInfo error on MoP Beta.
Benjamin Staneck:
- Revert "remove ranged slot"
This reverts commit ec2db64e689e6a6a08b1aef9c03873657734c92f.

forgot backwards comp
- remove ranged slot
Shefki:
- Use the variable I meant not what I typed.
- Avoid issues in HealthBar and PowerBar where UnitGUID returns nil inside an event.
- Fix a possible error when a unit goes away as UNIT_AURA fires.
- Fix case on Chi module description to match translation phrase.
- Really should change the author entry on things I wrote.
- Add ShadowOrbs module for Priest's in MoP.
Benjamin Staneck:
- fix ticket #947
Shefki:
- Update LuaTexts to show the proper info for battle pets in MoP.
- Remove some pre-wrath compat code from LuaTexts.
- Fix RaidTargetIcon module for MoP.
- Remove debug code from Chi module I forgot to remove.
- Add Chi module to pkgmeta so it'll get packaged.
- Add a Chi module for Monks.
Still using the icon from the the Holy Power module for now.
- Update DruidManaBar module to work for Mistweaver Monks in MoP.
The module name isn't fully chaning to prevent breaking things for
existing druid users. But it will display as the Druid/Monk mana bar
modules on the AddOns screen and in game.
- Fix HolyPower module for MoP (really Blizzard changing names of constants)
- Fix master guid refresh event for MoP.
- Fix MasterLooterIcon for MoP.
- Fix ReadyCheckIcon module for MoP.
- Eclipse module compatability with MoP.
- Remove a change I inadvertantly commited to the acceptable classifications for ThreatBar to work with my private branch for testing purposes.
- Use alpha releases of Ace3, LibBanzai and LibDualSpec for MoP compatability.
- Add a translation for Monks.
- MoP Fixes: Commit the changes roughly based on daf2's zip file.

Shefki:
- Build the full sorting table for the group otherwise filtered frames won't work. (e.g. filtered by raid group)
I had an hackish way of doing it in there before that was a little
faster but it can't work now that I fixed the sorting.
- Remove debug code that whines about things being wrong when they aren't since I've made the code much smarter than this auto-detection can deal with.
- Sorting with a partial raid in config mode is now consistent with how you'd expect it to behave.
Unfilled slots are always considered to be towards the end of the sort
(higher index, higher group number, a class that is last on the sort
order, and a name that's alphabetically last).
- Fix duplicates frames for real players in config mode when in a partially filled raid with sorting by group descending.
- Fix an error with group sorted raid frames.
- Rename GroupHeader:AssignFakeUnitIDs to GroupHeader:ApplyConfigModeState.
No functional change just make the code make more sense now that
function does a lot more than just set unit ids.
- Fix Bug #864 - Group Config Mode Doesn't Work.
Major refactoring of the way config mode works. It should be faster,
though it will still take some time if you go straight into raid40 mode
without any of the frames existing. However, subsequent changes in
config mode states after that should be pretty quick. One side
effect of this is that the farmes won't immediately have the fake
units assigned but will pick them up very shortly after.

(Note to self: This commit differs from the anchor branch commit by the
removal of changes to the new/remove config options for units and by the
removal of logic in SwapGroupTemplate to check that the group is a pet
group)
Conflicts:
GroupHeader.lua
Options/Units.lua
- Fix previous patch to put variables inside the function and make _ be local.
- Remove an unused parameter on get_group_roster_info().
- Check frame.unit is set before using it in PvPIcon module.
- Switch to using the proper constants for a couple hardcoded values.
(Note to self: Difference here between anchors branch and master in
RefixSizeAndPosition)
Conflicts:
GroupHeader.lua
- Change the GetNumTalentTabs fix to the style I prefer. This style doesn't litter the special code all over the file.
- Put line endings back to Unix line endings on Filter.lua
- Fix bug #982 preventing Other filter from catching uncategorized auras.
Benjamin Staneck:
- GetNumTalentTabs → GetNumSpecializations for MoP

Shefki:
- Bump TOC files for 4.3
- Fix bug #976, flaw in Aura layout that shows up as divide by zero in 4.3
This was arguably always a bug since it makes the layout misbeehave
on 4.2. Calculating the size of the aura as inf never really made
sense.
- Remove the HappinessIcon module I missed in the last commit.
- Remove all references to pet Happiness.
- Rename VisualHeal5 to just VisualHeal. Remove ManaSpark module.
- Delete old HealComm based VisualHeal module.
- Fix divide by error issues with UnitFrameLayout.lua and 4.3.0
- Fix divide by zero errors for 4.3.0

I'm getting an error in hideblizzard UI when I try to select the garrison action button that makes the button only usable when disabling the hideblizzardui part of the addon. It doesn't happen when you first log on, but only after you have played for an hour or so and changed zones at least once.... Very bizzare but doing a reloadui seems to fix the issue or else the blizz UI offers to disable it for you in order to complete the action of pressing the garrison action button.

Various problems with errors in 5.4 should be fixed in beta48. Took a while to fix since it wasn't reproducible except in some rather specific conditions and even then it wasn't always reliable from one machine to the next.

I think I messed up my settings. My targets arent showing any buffs or debuffs on them, even when I know they have some on. When I target myself, I can see my buffs, but on anyone else, I can't. How can I fix this please?

Thanks.

Look under the Aura settings for the Layout you have defined on your target.

I ve just found this addon and i must say that this is a very nice one fore sure, grats

I ve taken a look at the fact that you wanted to make this addon easyer to handle and still very configurable.

And i have a couple of suggestions :

Would it be possible to configure the text displayed for each bar. I mean, for exemple, as it is now, i can see both my HP/total HP and my %HP displayed in my life bar. And i would rather like to have an option to hide my %HP. Also i d rather like to have an option to hide all text but the name of the target of my target bar. Same with the race displayed in my power bar that i d rather like to hide. Because yet, you can't disable specific parts of the text. For exemple, if i want to hide the race text, i have ti disable the Lua:class and doing so will hide the race but also the level and class text which isn't good

Would it be possible to set the color for each bar because at the moment, despite that in my life bar settings my health is colored in green/yellow/red, the life bar of monsters isn't colored this way at all.

For the first option, it is available and easily fixed, under layout editor you can create a new profile for every bar you want to be different from another bar and then go to text and edit the text you want there.

And for the color part it's available as well, dont have WoW on this computer and dont remember it in my head but its there somewhere :P just look around and you'll find it

I ve just found this addon and i must say that this is a very nice one fore sure, grats

I ve taken a look at the fact that you wanted to make this addon easyer to handle and still very configurable.

And i have a couple of suggestions :

Would it be possible to configure the text displayed for each bar. I mean, for exemple, as it is now, i can see both my HP/total HP and my %HP displayed in my life bar. And i would rather like to have an option to hide my %HP. Also i d rather like to have an option to hide all text but the name of the target of my target bar. Same with the race displayed in my power bar that i d rather like to hide. Because yet, you can't disable specific parts of the text. For exemple, if i want to hide the race text, i have ti disable the Lua:class and doing so will hide the race but also the level and class text which isn't good

Would it be possible to set the color for each bar because at the moment, despite that in my life bar settings my health is colored in green/yellow/red, the life bar of monsters isn't colored this way at all.

I think I messed up my settings. My targets arent showing any buffs or debuffs on them, even when I know they have some on. When I target myself, I can see my buffs, but on anyone else, I can't. How can I fix this please?