Search found 196 matches

by Clyde
Mon Nov 04, 2019 9:05 am
Forum: Showcase
Topic: json.hollywood
Replies: 8
Views: 907

Re: json.hollywood

Very nice, thanks!
by Clyde
Wed Oct 02, 2019 2:05 pm
Forum: General programming
Topic: Any way to save current eventhandler option?
Replies: 9
Views: 221

Re: Any way to save current eventhandler option?

Well, I am unsure about the syntax you use, but if you do it like it is said in the manual you could do things like this: Function callbackFunction1() EndFunction Function callbackFunction2() EndFunction InstallEventHandler({ OnMouseUp = callbackFunction1 }) ; And later you would simple write: Insta...
by Clyde
Wed Oct 02, 2019 2:01 pm
Forum: General programming
Topic: Create tables
Replies: 8
Views: 198

Re: Create tables

To create the table at runtime you would do something like:

Code: Select all

For t = 1 to c
    MenuItiem[t] = yourDynamicValue
Next
by Clyde
Tue Oct 01, 2019 10:59 pm
Forum: Hollywood bugs
Topic: Documentation problems
Replies: 32
Views: 10594

Re: Documentation problems

The object that is passed to the event handler callback function which is called when creating a layer button contains a property called "layername", which is not documented in the MakeButton section of the documentation: Function _handleMouseClickEvents(msg) DebugPrint("msg.id", msg.id) DebugPrint(...
by Clyde
Tue Oct 01, 2019 10:53 pm
Forum: Newbie questions
Topic: Move layer with mouse
Replies: 9
Views: 422

Re: Move layer with mouse

PEB, your code works like a charm and I could easily adapt it to my code. Thanks a lot again! I am not sure whether this is new with Hollywood 8, but the object that is passed to the event handler callback (p_ButtonFunc()) has a property called "layername" (msg.layername), so don't have to build you...
by Clyde
Tue Oct 01, 2019 5:03 pm
Forum: Wishlist
Topic: StrToTable()
Replies: 9
Views: 368

Re: StrToTable()

Yeah, this is really nice! Thanks, Andreas!

EDIT: But booleans in the table will be converted to 0/1 in the xml, right?
by Clyde
Mon Sep 30, 2019 7:33 am
Forum: General programming
Topic: why table.function doesnt pass var while table:function does?
Replies: 3
Views: 157

Re: why table.function doesnt pass var while table:function does?

This link is useful for that kind of questions (I just discovered this last week): http://lua-users.org/wiki/ObjectOrientationTutorial
by Clyde
Wed Sep 25, 2019 2:04 pm
Forum: Newbie questions
Topic: Move layer with mouse
Replies: 9
Views: 422

Re: Move layer with mouse

Wow, thanks Bugala for your work on this post! It is interesting to see others code. E.g. I should more look into the object orientated aspects of Hollywood. But it is also interesting how you manage the layer stuff. I am not sure whether I will need that complexity, but good to know that I can have...
by Clyde
Wed Sep 25, 2019 1:45 pm
Forum: Showcase
Topic: json.hollywood
Replies: 8
Views: 907

Re: json.hollywood

Well, this is not the task of JSON or the JSON encoder/decoder. JSON is just another representation of structuring data. You have to write your own converting code to convert from your txt file format to a Hollywood table.
by Clyde
Wed Sep 25, 2019 12:44 pm
Forum: Showcase
Topic: json.hollywood
Replies: 8
Views: 907

Re: json.hollywood

Could you please provide a small real example with the structure/table you want to convert to JSON? What the json encoder does is taking a Hollywood table and converts it to json (and the decoder takes the json and converts it back to a table). So, seeing your first code snipped (starting with "Capi...