Thread Tools Display Modes
09-13-13, 01:33 PM   #1
bsmorgan
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Mar 2005
Posts: 219
Trade Skill Name Truncating

In the Blizzard TradeSkill Frame, a recipe like "Crafted Dreadful Gladiator's Ornamented Headcover" is truncated to "Crafted Dreadful Gladiator's Ornamented Hea..." so it fits in the width of the frame.

I want to do the same thing but I've studied Blizzard's code for a few hours and can't figure out where the magic happens. Can anyone help me figure it out? In what I have now (ATSW if you are curious), the name just runs off the end of the width that's allocated to it.

Brad

P.S. I was also unsuccessful in figuring out how to make that part of the frame wider. I'm definitely a novice when it comes to messing with the UI part of an addon. Most of mine use the chat frame and slash commands!

If there's someone interested in a "fan update" for ATSW and has the expertise to do the UI stuff, I'd be happy to turn this into a "fans update". I've got guild bank and sub headers (in cooking) working.
  Reply With Quote
09-14-13, 07:18 AM   #2
ravagernl
Proceritate Corporis
Premium Member
AddOn Author - Click to view addons
Join Date: Feb 2006
Posts: 1,176
For the automatic ellipsis, check here: http://www.wowwiki.com/UIOBJECT_FontString
  Reply With Quote
09-14-13, 12:41 PM   #3
bsmorgan
A Cobalt Mageweaver
AddOn Author - Click to view addons
Join Date: Mar 2005
Posts: 219
Thank you!

That was exactly what I needed. Once I knew the "trick", it was easy to spot the difference between my code and the Blizzard code.

Rather than setting the left and right anchors, I found the ButtonText attribute wordwrap="false"

Code:
<ButtonText name="$parentText" inherits="GameFontNormal" justifyH="LEFT" wordwrap="false">

Last edited by bsmorgan : 09-14-13 at 12:47 PM.
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Trade Skill Name Truncating


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