Löve Frames - A GUI Library

Showcase your libraries, tools and other projects that help your fellow love users.
User avatar
OmarShehata
Party member
Posts: 259
Joined: Tue May 29, 2012 6:46 pm
Location: Egypt
Contact:

Re: Löve Frames - A GUI Library

Post by OmarShehata »

riidom wrote:if you see the documentation, check the "base" object, it has a ton of methods, all other objects inherit from, and thus not described there. In this list, you will find :Remove().
Took me a while to discover myself :)
Oh! Thanks! :D
szensk
Party member
Posts: 155
Joined: Sat Jan 19, 2013 3:57 am

Re: Löve Frames - A GUI Library

Post by szensk »

I don't have a github account so

starting at line #693 in objects/textinput.lua

Code: Select all

if loveversion == "0.9.0" then
	unicode = string.byte(unicode)
end
what about nil unicode? (ie a function key)

Code: Select all

if loveversion == "0.9.0" then
	unicode = unicode and string.byte(unicode) or -1
end
Or the 'else' on line 691 it should be

Code: Select all

elseif unicode then
User avatar
Nikolai Resokav
Party member
Posts: 140
Joined: Wed Apr 28, 2010 12:51 am
Location: United States

Re: Löve Frames - A GUI Library

Post by Nikolai Resokav »

szensk wrote:I don't have a github account so

starting at line #693 in objects/textinput.lua

Code: Select all

if loveversion == "0.9.0" then
	unicode = string.byte(unicode)
end
what about nil unicode? (ie a function key)

Code: Select all

if loveversion == "0.9.0" then
	unicode = unicode and string.byte(unicode) or -1
end
Or the 'else' on line 691 it should be

Code: Select all

elseif unicode then
Thanks for the report. I'll fix that in the next update.
User avatar
killer64
Prole
Posts: 14
Joined: Mon Mar 12, 2012 7:55 pm

Re: Löve Frames - A GUI Library

Post by killer64 »

verry nice, i made a lovely UI to control my stargates (SGCraft + CC)
Image
Sometimes, the elegant implementation is just a function. Not a method. Not a class. Not a framework. Just a function.
User avatar
ncarlson
Prole
Posts: 35
Joined: Wed Jul 20, 2011 4:00 pm

Re: Löve Frames - A GUI Library

Post by ncarlson »

Excellent library!

Just wanted to say thanks for the continued updates.
ixjf
Prole
Posts: 19
Joined: Sat Apr 27, 2013 10:27 am

Re: Löve Frames - A GUI Library

Post by ixjf »

I am porting this library (and eventually re-writing most of it to meet my needs) for Multi Theft Auto and I came across something which I don't understand:

Code: Select all

local height = font:getHeight(curline:sub(i, i))
on file textinput.lua (I don't know the exact line because I have modified the file already). On Love2D wiki, getHeight method does not have any parameters. What's this?
I used to be an adventurer like you, but then I took an arrow in the knee.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: Löve Frames - A GUI Library

Post by Robin »

It's the same. Functions in Lua ignore extra arguments, just like arguments you don't pass become nil.
Help us help you: attach a .love.
User avatar
Eamonn
Party member
Posts: 550
Joined: Sat May 04, 2013 1:29 pm
Location: Ireland

Re: Löve Frames - A GUI Library

Post by Eamonn »

As I think everyone in this thread has said, this library is excellent. It's better then excellent. You can't describe how excellent it is!

I'm writing some basic helper methods, which makes life a lot easier. It's really easy to do stuff like that, and it's really easy to design your own UI, as a poster above showed. It's just incredible! :D Thanks for making it!
"In those quiet moments, you come into my mind" - Liam Reilly
ixjf
Prole
Posts: 19
Joined: Sat Apr 27, 2013 10:27 am

Re: Löve Frames - A GUI Library

Post by ixjf »

Robin wrote:It's the same. Functions in Lua ignore extra arguments, just like arguments you don't pass become nil.
I know that. I had an idea it'd probably be that it's unnecessary, just like in many functions of this library I saw parameters which are never used but I thought there was an explanation for it.
I used to be an adventurer like you, but then I took an arrow in the knee.
User avatar
Robin
The Omniscient
Posts: 6506
Joined: Fri Feb 20, 2009 4:29 pm
Location: The Netherlands
Contact:

Re: Löve Frames - A GUI Library

Post by Robin »

Okay. I guess some people become confused because [wiki]Font:getWidth[/wiki] does take an argument?
Help us help you: attach a .love.
Post Reply

Who is online

Users browsing this forum: No registered users and 219 guests