Uare: A simple and customisable UI library

Showcase your libraries, tools and other projects that help your fellow love users.
User avatar
Ulydev
Party member
Posts: 445
Joined: Mon Nov 10, 2014 10:46 pm
Location: Paris
Contact:

Re: Uare: A simple and customisable UI library

Post by Ulydev »

Zireael wrote:Does this work with newest LOVE?
Can I have a window over a window? Or see-through windows?
Hey Zireael,
I just updated Uare to work with 0.10.x! Also, yes, you can definitely have windows stacked on top of each other, and even define transparent background colors. Check out the examples in the repo :)
Nicholas Scott
Prole
Posts: 49
Joined: Sun Jun 07, 2015 9:12 am

Re: Uare: A simple and customisable UI library

Post by Nicholas Scott »

Ulydev wrote:Check out the examples in the repo :)
Heyya, quick question, where is all the locations your library gets the mouse position, I would like to replace it with an internal function call to get the mouse position so that I could easily swap it between love.mouse.getPosition() and something like camera:getMousePosition() for gamera and other things :D
Edit: Nvm :P I forgot that it is passed inside the love.update call x3 Well, that's handy, thanks :D

Edit2: Oh hey, quick thing, you should probably pass self inside of your codes update function for the callbacks ie these: Image
It would be useful for accessing your own properties inside of one of those calls, say I wanted a button to move across the screen if it's pressed, as of now I'd have to have a reference to it somewhere else, where if that was passed I could do something as simple as :

Code: Select all

--Declare myButton as a local variable somewhere up here
myButton.onClick(self)
	self.x,self.y = 100, 500
end
table.insert(objects, myButton)
--Now I've lost a reference to that so I'd have to search through the table of objects for it's reference to edit it's attributes
Just a suggestion
User avatar
Ulydev
Party member
Posts: 445
Joined: Mon Nov 10, 2014 10:46 pm
Location: Paris
Contact:

Re: Uare: A simple and customisable UI library

Post by Ulydev »

Nicholas Scott wrote: Just a suggestion
Thanks for the feedback! Feel free to open an issue or a pull request on Github, that would greatly help!
Nicholas Scott
Prole
Posts: 49
Joined: Sun Jun 07, 2015 9:12 am

Re: Uare: A simple and customisable UI library

Post by Nicholas Scott »

Ulydev wrote:Feel free to open an issue or a pull request on Github, that would greatly help!
;~;;;;; so much work, I'll open an issue I guess :P But if I'm gonna do that, I'm gonna open a few more issues while I'm at it, such as adding another callback such as

Code: Select all

--Inside uare:updateSelf(dt, x, y, e)
--After all core update code
if self.customUpdate then self.customUpdate(self, dt, x, y, e) end

Code: Select all

--Inside uare:drawSelf(dt, x, y, e)
--After all core draw code
if self.customDraw then self.customDraw(self) end
Finished creating the issues :P
Aimatt
Prole
Posts: 1
Joined: Thu Dec 01, 2022 4:56 pm

Re: Uare: A simple and customisable UI library

Post by Aimatt »

hi, how to add icon to button?
Post Reply

Who is online

Users browsing this forum: Google [Bot] and 48 guests