View Single Post
Old 04-11-10, 01:34 PM   #9
nightcracker
A Molten Giant
 
nightcracker's Avatar
AddOn Author - Click to view addons
Join Date: Sep 2009
Posts: 714
Originally Posted by Saiket View Post
If you don't want to override the user's uiScale, you can use the following code to position a frame on real pixel boundaries: http://pastey.net/134131

It includes some test code that renders pixel-wide nested borders. The top one in this screenshot is adjusted, the bottom one isn't.
Hence my above post

One problem though, neither GetCVar("uiScale") or UIParent:GetScale() return values instantly, you'll have to hook an event like PLAYER_ENTERING_WORLD(I don't know the first event that they are available, I do know that they are available at PLAYER_ENTERING_WORLD).
__________________
Three things are certain,
Death, taxes and site not found,
You, victim of one.
nightcracker is offline   Reply With Quote