For me following the steps it doesn’t crash but I get an empty widget without any visible label when I am supposed to create a new widget. If I follow through with the code still nothing is visible. If I create a new script only stack and copy the code of the Square widget. I can create a widget that is placed in the upper left corner. But I see none of the properties in the inspector. If I open the Extension Builder and load the widget and test it it works!
When trying to build a simple widget it is super easy to crash LiveCode. If you use the id of the control but misses the id key word anywhere it crashes. Like: set the backgroundColor of control sMyControlID instead of set the backgroundColor of control id sMyControlID But now it moves forward anyway! My best tips so far: Save often and load the widget via the Extensions Builder Happy coding! > On 21 Apr 2023, at 23:45, matthias rebbe via use-livecode > <use-livecode@lists.runrev.com> wrote: > > Here LC is also crashing to Desktop. > > Tried now the steps of Ali's lesson, > but LC still is crashing. But maybe there is an typo in one of my scripts, so > they are not identical to the ones in the lesson. > Will wait with a bug report until Ali is adding the final stack to the lesson > or at least the complete stack script that can be copied. Currently only > screenshots from the scripts are shown. > > >> Am 21.04.2023 um 22:10 schrieb Håkan Liljegren <ha...@exformedia.se>: >> >> Thanks for the input. I thought I had done everything until I finally >> realised that the file dialog that comes up had a button in the lower left >> corner that said: “Show options”. =-o So then I could select “LiveCode >> Script” as format. And tada. Well, LiveCode crashed… >> …but still. Can now work from that! >> >> Thanks anyway! >> >> :-Håkan >> >>> On 21 Apr 2023, at 14:02, matthias rebbe via use-livecode >>> <use-livecode@lists.runrev.com <mailto:use-livecode@lists.runrev.com>> >>> wrote: >>> >>> Hakan, >>> >>> as far as I know >>> >>> you have to create a script only stack and name it for example >>> se.eformedia.widget.MyButton >>> >>> Then add a openControl handler to the script and put the part of your >>> script into it that creates the internal widget controls. >>> >>> Create a resizeControl handler in which you put any code that is >>> responsible for resizing the controls. >>> >>> Use getProp and SetProp handlers to add properties for the control >>> As long as the stack is in memory you do not need to use the extension >>> builder to test the script widget. >>> You could just use the message box and execute the following: >>> >>> create widget as "se.eformedia.widget.MyButton" >>> >>> use here the name of the stack you used at the beginning. >>> >>> >>> To build the widget using the extension builder you'll need to add some >>> more to the script. You could use the following sample stack as an example >>> https://livecode.com/documents/sample-script-widget.zip >>> The link to that stack was posted in the Blog here >>> https://livecode.com/livecode-10-dp-5-smaller-faster-richer/ >>> >>> >>> >>> My problem currently is, that LC crashes to Desktop right away when I try >>> to build the widget using the extension builder. >>> In my opinion this should not happen. There should be some routine that >>> prevents LC from crashing when there is a problem with building the script >>> widget. >>> But it's a DP so let's see. >>> >>> >>> Regards, >>> Matthias >>> >>> >>> >>> >>> >>>> Am 21.04.2023 um 10:49 schrieb Håkan Liljegren via use-livecode >>>> <use-livecode@lists.runrev.com <mailto:use-livecode@lists.runrev.com>>: >>>> >>>> This caught my eye as I have several “controls” already that could be >>>> turned into "script widgets”. But after “scriptifying” a “group widget” >>>> how can I turn it into a script widget. I can’t add the file in the >>>> extension builder so how can I create the needed .lce file? Or is this a >>>> “not implemented yet” feature? >>>> >>>> :-Håkan >>>> >>>>> On 18 Apr 2023, at 19:18, panagiotis merakos via use-livecode >>>>> <use-livecode@lists.runrev.com <mailto:use-livecode@lists.runrev.com>> >>>>> wrote: >>>>> >>>>> - A prototype implementation of the 'script widgets' feature has >>>>> been included >>>> >>>> _______________________________________________ >>>> use-livecode mailing list >>>> use-livecode@lists.runrev.com <mailto:use-livecode@lists.runrev.com> >>>> Please visit this url to subscribe, unsubscribe and manage your >>>> subscription preferences: >>>> http://lists.runrev.com/mailman/listinfo/use-livecode >>> >>> _______________________________________________ >>> use-livecode mailing list >>> use-livecode@lists.runrev.com <mailto:use-livecode@lists.runrev.com> >>> Please visit this url to subscribe, unsubscribe and manage your >>> subscription preferences: >>> http://lists.runrev.com/mailman/listinfo/use-livecode >> > > _______________________________________________ > use-livecode mailing list > use-livecode@lists.runrev.com > Please visit this url to subscribe, unsubscribe and manage your subscription > preferences: > http://lists.runrev.com/mailman/listinfo/use-livecode _______________________________________________ use-livecode mailing list use-livecode@lists.runrev.com Please visit this url to subscribe, unsubscribe and manage your subscription preferences: http://lists.runrev.com/mailman/listinfo/use-livecode