Thread Tools Display Modes
08-30-16, 03:59 AM   #1
eiszeit
A Chromatic Dragonspawn
 
eiszeit's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2007
Posts: 154
BonusObjectiveTracker, changing font.

Hello there,

I have this problem here with the bonus objective tracker. You can see that all quest titles, achievement titles have a specific font. But somehow, for BonusObjectives that does not work. It seems they use internal functions to put them all in a table I can't access.

Here's my current quest tracker code:

https://gist.github.com/mtthsw/0ef8f...eb031de6ddbf91

My question now is, does anyone know how to change the font of the bonus objective titles? It drives me crazy. :/

Ignore the reward icon on the Progressbar, that is already fixed.
__________________
Lyn • I'm a mess of unfinished thoughts
  Reply With Quote
08-30-16, 05:58 AM   #2
Miiru
A Flamescale Wyrmkin
 
Miiru's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2008
Posts: 138
You want to change the string that says "Those Beyond Redemption"?

If i remember correctly, the game handles the headers of bonusobjectives and world quests not as headers, but as lines. If you change
Lua Code:
  1. line 215 - line.Text:SetFont([[Fonts/ARIALN.ttf]], 12)
to something else, it should change the bonusobjective header also. You could add a check for textcolor and only apply your headerfont on yellow.
__________________
◘◘ Author of MiirGui Texture Pack - [Core] [Blue] [Grey] ◘◘
  Reply With Quote
08-30-16, 06:18 AM   #3
eiszeit
A Chromatic Dragonspawn
 
eiszeit's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2007
Posts: 154
Oh! That worked. Kinda unprecise way to get it done but here it is:

Lua Code:
  1. local r, g, b = line.Text:GetTextColor()
  2. -- hacky way to get bonus objective titles in another font
  3. -- print(line.Text:GetText(), r, g, b)
  4. if b < 0.1 then
  5.     line.Text:SetFont(FONT, 13)
  6. else
  7.     line.Text:SetFont([[Fonts/ARIALN.ttf]], 12)
  8. end

Thanks!
__________________
Lyn • I'm a mess of unfinished thoughts
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » BonusObjectiveTracker, changing font.

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off