Page 1 of 1

Create floting window

Posted: Tue Aug 10, 2021 12:20 pm
by davoodice2
hello.
I am newbie in moho scripting.

Is there a way to build a floating window in Moho? So that he had access to the main window of Moho. :?:

Re: Create floting window

Posted: Tue Aug 10, 2021 12:37 pm
by Lukas
I've been experimenting and was able to create a floating window that has access Moho but it's unstable at the moment: ExperimentDialWindow.gif

More info in this thread.

Re: Create floting window

Posted: Tue Aug 10, 2021 1:28 pm
by gilcartunista
Great Lukas!! If possible I would like to try it! Grateful!

Re: Create floting window

Posted: Tue Aug 10, 2021 7:10 pm
by davoodice2
Lukas wrote: Tue Aug 10, 2021 12:37 pm I've been experimenting and was able to create a floating window that has access Moho but it's unstable at the moment: ExperimentDialWindow.gif

More info in this thread.
amazing job ! this with moho's api?

Re: Create floting window

Posted: Wed Aug 11, 2021 8:45 am
by Lukas
davoodice2 wrote: Tue Aug 10, 2021 7:10 pmamazing job ! this with moho's api?
Yes Moho's API and some undocumented stuff mentioned in the thread I linked in my first reply.
gilcartunista wrote: Tue Aug 10, 2021 1:28 pm Great Lukas!! If possible I would like to try it! Grateful!
It'll just crash...

Re: Create floting window

Posted: Wed Aug 11, 2021 3:27 pm
by gilcartunista
Lukas wrote: Wed Aug 11, 2021 8:45 am
davoodice2 wrote: Tue Aug 10, 2021 7:10 pmamazing job ! this with moho's api?
Yes Moho's API and some undocumented stuff mentioned in the thread I linked in my first reply.
gilcartunista wrote: Tue Aug 10, 2021 1:28 pm Great Lukas!! If possible I would like to try it! Grateful!
It'll just crash...
OK Lukas! No problem, I test it anyway! Grateful.

Re: Create floting window

Posted: Wed Aug 11, 2021 3:41 pm
by hayasidist
the challenge (why it crashes) is, I think, to do with how the "moho" table is passed through to the "update" function (and I'm also guessing that the functions in that table are expected to be written in C / C++; so the "moho" that they get is C-friendly, and not LUA friendly.) Specifically, I haven't yet figured out how to invoke the functions that return properties that the "usual LUA moho" would give you using such as moho.layer

More here: viewtopic.php?f=12&t=33793&start=30#p198597

so if anyone can figure that out ...

Re: Create floting window

Posted: Wed Aug 11, 2021 4:33 pm
by davoodice2
can you share how to create a floating window? please :cry:

just interface.

Re: Create floting window

Posted: Wed Aug 11, 2021 4:59 pm
by Lukas
Check out the code in LM_SetOrigin.lua
Also: http://mohoscripting.com/classes/LM_SimpleDialog

Re: Create floting window

Posted: Thu Aug 12, 2021 8:17 am
by davoodice2
Lukas wrote: Wed Aug 11, 2021 4:59 pm Check out the code in LM_SetOrigin.lua
Also: http://mohoscripting.com/classes/LM_SimpleDialog
thanks man.

Re: Create floting window

Posted: Thu Aug 12, 2021 8:19 am
by davoodice2
davoodice2 wrote: Thu Aug 12, 2021 8:17 am
Lukas wrote: Wed Aug 11, 2021 4:59 pm Check out the code in LM_SetOrigin.lua
Also: http://mohoscripting.com/classes/LM_SimpleDialog
thanks you.