GUIDrop adds functionality to add images directly to Mudlet by Drag&Drop
The script and luacode will be created automatically.
It uses Adjustable Container with some extras. (check the custom menu)
Once found the position you want the image at, it can be converted into a normal Geyser.Label and use all the perks of them.
(The code is also auto-generated)
This is a very early version,
if you find issues or have some ideas how to improve GUIDrop
please leave feedback in the issue tab or in this thread.
Github link: https://github.com/Edru2/GUIDrop
Github release link: https://github.com/Edru2/GUIDrop/releases
Short showcase video: https://youtu.be/Zl7h83SA9bY
Have fun
GUIDrop Drag and Drop Images onto Mudlet
Re: GUIDrop Drag and Drop Images onto Mudlet
Some initial thoughts:
Deleting a label created in this way doesn't seem to be easy. I found I needed to delete the file in the profile/AdjustableContainers folder.
Having run the convert to label function via the right click menu, there isn't an easy way to get it back into the GUIDropManager. At first I thought I worked out a way but I was wrong as there is a lot more to what you're doing than I initially understood.
- I'm not sure what the easiest workflow there would be. Obviously you can't have clicking enabled on the label after you've converted it, because people will presumably want to use the clickCallBack for their own purposes (I certainly do).
I'll keep playing around with it and if I think of any more feedback I'll let you know. The script itself seems wonderful though, and I'm now dreaming of simple ways to extend the behaviour of labels created by other scripts.
Deleting a label created in this way doesn't seem to be easy. I found I needed to delete the file in the profile/AdjustableContainers folder.
Having run the convert to label function via the right click menu, there isn't an easy way to get it back into the GUIDropManager. At first I thought I worked out a way but I was wrong as there is a lot more to what you're doing than I initially understood.
- I'm not sure what the easiest workflow there would be. Obviously you can't have clicking enabled on the label after you've converted it, because people will presumably want to use the clickCallBack for their own purposes (I certainly do).
I'll keep playing around with it and if I think of any more feedback I'll let you know. The script itself seems wonderful though, and I'm now dreaming of simple ways to extend the behaviour of labels created by other scripts.
Re: GUIDrop Drag and Drop Images onto Mudlet
Have you tried delete image in the right click menu? (I have to remove some options there so it's more visible)
That one is doing exactly that (deleting the file in profile/AdjustableContainers)
Yes, I was thinking about a way to convert back as well. (Have some ideas but still didn't write any code for it)Caled wrote: ↑Thu May 07, 2020 4:09 amHaving run the convert to label function via the right click menu, there isn't an easy way to get it back into the GUIDropManager. At first I thought I worked out a way but I was wrong as there is a lot more to what you're doing than I initially understood.
- I'm not sure what the easiest workflow there would be. Obviously you can't have clicking enabled on the label after you've converted it, because people will presumably want to use the clickCallBack for their own purposes (I certainly do).
A workaround would be, not to convert to label but to use disableClickthrough on the Label.
And if you wan't to move/resize it again use enableClickthrough again.
I just noticed that disable/enable Clickthrough is not being saved anywhere in the Geyser.Label I'll PR that.
So if you want disableClickthrough to be persistent you'll have to change it also in script lua code from clickthrough=true to clickthrough = false.
Re: GUIDrop Drag and Drop Images onto Mudlet
Cool, I'll try leaving it as a label in an adjustable container and see how that goes.
In terms of deleting it, I mean, after it has been converted to a label, it is still defined both in the script editor and in a lua file. Deleting it from the script editor and restarting mudlet, causes it to be pulled from the lua file.
But because it has been converted to a label, there is no right click menu any more.
In terms of deleting it, I mean, after it has been converted to a label, it is still defined both in the script editor and in a lua file. Deleting it from the script editor and restarting mudlet, causes it to be pulled from the lua file.
But because it has been converted to a label, there is no right click menu any more.
Re: GUIDrop Drag and Drop Images onto Mudlet
Yes, that is an issue I didn't notice before (it was working before then there were some changes on Adjustable.Container)Caled wrote: ↑Fri May 08, 2020 12:18 amIn terms of deleting it, I mean, after it has been converted to a label, it is still defined both in the script editor and in a lua file. Deleting it from the script editor and restarting mudlet, causes it to be pulled from the lua file.
But because it has been converted to a label, there is no right click menu any more.
Thanks for testing and letting me notice it
This PR should solve this issue.
https://github.com/Edru2/GUIDrop/pull/2