TangentFoxy / Pop.Box

(ON HOLD) Pop.Box is an easy to use GUI library for the LÖVE engine, intended for rapid prototyping.
http://guard13007.github.io/Pop.Box/docs
MIT License
8 stars 4 forks source link

Table-based element creation #42

Closed TangentFoxy closed 8 years ago

TangentFoxy commented 8 years ago

Use:

pop.box({
  x = 60,
  y = 20,
  w = 120,
  h = 20
})

Function:

@data = {} -- the table passed by the user

And all access to object values needs to be changed to access data.value. This will probably be a little slower. In the future, if it becomes a problem, it can be removed even easier than it is to add.

This also makes writing the streamlined_get_set stuff easier, since values will be separate from the class access.

If a user passes an incomplete table, it will be completed by the defaults. (Note to self: Does MoonScript have table merging? If so, use that, else, check and see if lume has it.)

TangentFoxy commented 8 years ago

The main things I need for this to work: