Thread Tools Display Modes
03-17-16, 07:34 PM   #1
myrroddin
A Pyroguard Emberseer
 
myrroddin's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 1,246
LibUtilities1.0 needs testers

While I am discussing code on the appropriate thread, I have put LibUtilities-1.0 into experimental status.

The Curseforge packager is doing its thing, as is the luadoc process. Hopefully there will be something soon. In the meantime, here is the link: http://www.wowace.com/addons/libutilities-1-0/

What it does:
  1. Pixel perfection
  2. Convert decimal to hex
  3. Parse item strings
  4. Round numbers to the nth decimal
  5. Give data about UI scale and screen resolution
  Reply With Quote
03-17-16, 09:26 PM   #2
Cybeloras
A Fallenroot Satyr
 
Cybeloras's Avatar
AddOn Author - Click to view addons
Join Date: Dec 2009
Posts: 28
  • You have a syntax error on line 2.
  • What does NumberToHex offer over just using string.format("%x", number)?
  • string_split("x", currResolution) doesn't work - you can't perform strsplit on a function.
  • GetCurrentResolution() doesn't return a string with an 'x' in it - it returns an index into the return values of GetScreenResolutions().
  • None of your functions are usable at all because they are all declared locally and are never made available outside your one file. I think you meant to define them as lib:PixelPerfect() and so on?

Considering it won't run at all, and even if it did and your functions were accessable, half the functions will throw errors, maybe you should test it yourself a little before asking for others to test it.

A tip on the design: Requiring implementors to call VisualData() before PixelPerfect() will start working (and also requiring them to 'just know' if they need to call VisualData() again because of external changes in order to keep PixelPerfect() working) is pretty bad design. Consider an implementation that doesn't require someone to do setup work in order to call PixelPerfect().

EDIT: Oh, and the CurseForge documenter (with .docmeta files) hasn't worked in years.

Last edited by Cybeloras : 03-17-16 at 09:29 PM. Reason: formatting
  Reply With Quote
03-21-16, 05:48 AM   #3
myrroddin
A Pyroguard Emberseer
 
myrroddin's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 1,246
I have fixed all the issues listed. PixelPerfect internally calls VisualData, although you can still do so yourself.

And stupid Documenter! I wrote the API manually.

The first beta (tested, appears to work) is on Curse, and will be on Wowinterface soon.

Note, I removed the rounding function. After perusing the web, there were many versions, all doing things slightly differently, so I am leaving that to developer design rather than library implementation.
  Reply With Quote
03-21-16, 06:15 AM   #4
myrroddin
A Pyroguard Emberseer
 
myrroddin's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 1,246
And Wowinterface has it now.
  Reply With Quote
03-21-16, 09:41 AM   #5
Resike
A Pyroguard Emberseer
AddOn Author - Click to view addons
Join Date: Mar 2010
Posts: 1,290
I don't see whats the point of this pixelperfect calls. All it gonna do is to create sizes thats 100% not round. And the game won't be able to determine on what pixel should it draw the frame, so it gonna look blurry.
  Reply With Quote
03-21-16, 04:04 PM   #6
myrroddin
A Pyroguard Emberseer
 
myrroddin's Avatar
AddOn Author - Click to view addons
Join Date: Oct 2008
Posts: 1,246
Some people have talked about this in past years. I don't know if there is a good fix, and I worked with what I have.

Beside the discussion already linked, I found a note here, which pretty much verified things, and didn't solve the blurriness.

If there is a better solution, I am all ears.
  Reply With Quote

WoWInterface » AddOns, Compilations, Macros » Alpha/Beta AddOns and Compilations » LibUtilities1.0 needs testers


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