That is ? Stringwidth does not match the effective width of the text ?
Basically, the clipping issue is totally variable depending on the font you are using. If I use the standard game font, completely unaltered, then I get no clipping of any kind. If I replace the font, using CF2, or Tekticles or just by putting a Fonts dir in the WoW folder, then I get different clipping depending on which font is used.
The font issue does not show up at all if I use the pre-scrolling version of LQT. With the latest r78 and beyond, the clipping issue shows up if I use certain fonts. Never with the standard game font. Calibri also works fine. Others start to clip the right hand side. Torhal mentioned that the scrollable branch added height/width constraints - so maybe that's what's going on.
Also worth noting is that if I am looking at a clipped tooltip, and I play with the scale, I can make the clipping go away by changing the scale around to a significantly larger scale (115%+). Maybe also worth noting that my font of choice, which clips like mad, is quite small compared to the standard game font, or Calibri.
Unfortunately, while I'm fairly decent at coding some stuff after 3 years, frame type code still eludes me, so I can't personally help troubleshoot it any further.
And after a lot of headbanging in IRC the conclusion was : As a workaround, don't release the tooltip, just hide it. This obviously defeats the whole recycling philosophy but apparently this warrants a good review.
The thing is you are setting an OnUpdate to call TooltipUpdate() when the cursor is not over the DO at which point you hide the tooltip, instead of releasing it (releasing it autohides it btw). I have tested this extensively today (Broker_Factions and Auditor loaded) and found it to be the culprit for messing the factions tip :razz:
Eep, you are totally right, I am not releasing the tooltip there. However... I actually use Broker_Factions myself, and the tooltip is totally messed up even with just Broker_Factions loaded.
If you try it with a fresh install of Broker_Factions, it works fine - but if you update the LibQTip inside the Broker_Factions libs dir to any version LQT that includes the scrollable branch, then the tip is messed up - Auditor or no!
So, it's not my fault, but... yeah, my code is poop!
I prefered doing a release as content may greatly change between refresh to release all unused frames.
What would be the best thing to do in the following case:
1) hide the tooltip when leaving ldb object ==> Release.
2) redraw of tooltip when forcing a refresh after collapsing / expanding a category by clicking on the +/- icon of the category. Curently I'm releasing but would it be better to just call Clear() and that would also keep the position of the slider.
3)Same as 2) but for tracker that are almost always on so refresh can also be triggered by adding more data to it
In Auditor, I Clear() after an expansion/contraction of a category, and only release OnLeave. I found that if I released after a QTClick, then the tooltip would totally disappear until you hovered over the LDB frame, as once released, the cursor was no longer over the tooltip, so it would automatically trigger the OnLeave, and release again.
I absolutely agree, but I can't find the problem in LQT, so I'm just bypassing it for now :P
Although, it could also be an issue with the RIGHT alignment, as with the extra column, you can see that some (random) entries in the right hand side column are not aligned in a perfect line to the right - some are a few pixels further over.
Ive been getting clipping problems with both TomQuest2 and Broker_Factions its alwasy the right edge getting clipped :(
Any idea whats causing it and how to fix it?
I've just managed to 'fix' this in my mod, Auditor, by purposefully making the tooltip have one more column than I actually need.
In Auditor's case, there are 4 columns in the tooltip. When the tooltip is created with 4 columns, stuff is endlessly clipped in the right hand column. If I create the tooltip with 5 columns, even without putting anything in the 5th column (not even a " "), then the tooltip looks fantastic, with no clipped columns.