[Cuis-dev] [FIX] Re: Wrong feedback adding an extension category?

H. Hirzel hannes.hirzel at gmail.com
Sat Mar 8 13:06:18 PST 2025


Gerald

your fix 'Browser-addExtensionCategory.st' works fine in Cuis 7.3-7061.

Adding a new extension category but also dismissing the dialog box 
without adding a new category.

Thank you.

--Hannes

On 08/03/2025 7:11 pm, Gerald Klix via Cuis-dev wrote:
> Sorry messed it up.
> Here comes a version that handles aborts properly.
>
> Fun fact: I discovered that omission, when I wanted
> to add an extension category for my Haverize-package,
> in the browser class. I wanted to add this very method,
> to have the fixed version available in Haver, which
> is based on Cuis 7.2
>
>
> Best Regards,
>
> Gerald
>
>
>
> On 3/8/25 6:00 PM, Gerald Klix via Cuis-dev wrote:
>> Hi List Members, Hi Juan,
>>
>> Please find enclosed a fix for the issue Hannes observed.
>> I did only test it with Haver/Cuis 7.2, but I presume it will work
>> for Cuis'  rolling release, as well.
>>
>>
>> HTH,
>>
>> Gerald
>>
>>
>> On 3/8/25 5:06 PM, Gerald Klix via Cuis-dev wrote:
>>> Confirmed!
>>>
>>> There is are two issues with Browser>>#addExtensionCategory.
>>> First there is a coding error, this fragment
>>>
>>> (packageNames includes:                (newCategoryName copyUpTo: 
>>> $-) allButFirst
>>>
>>> should read
>>>
>>> (packageNames includes:                (newCategoryName 
>>> copyUpToLast: $-) allButFirst.
>>>
>>> The conceptional problem is that there should be some message that
>>> should complain in a sensible way if you use just the package name 
>>> as category (after the ‚*‘).
>>>
>>> Please give me 45 minutes to fix this.
>>>
>>> The intended use is to choose an existing category – ‚menu‘
>>> in your case – and than choose „Add extension Category ...“
>>> The text-input morph should contain the name 
>>> „Graphics-Files-Additiona-menu“
>>> in this case.
>>>
>>>
>>> Til later,
>>>
>>> Gerald
>>>
>>>
>>>
>>> On 3/6/25 5:39 PM, H. Hirzel via Cuis-dev wrote:
>>>> Hello
>>>>
>>>> I would like to add the method #exportAsPNG given below to class 
>>>> Morph with an extension category indicating that it belongs to 
>>>> package 'Graphics-Files-Additional'. The package has been loaded 
>>>> before.
>>>>
>>>> If I choose the menu option 'New extension Category ...' I get
>>>>
>>>>     'The selected prefix does not match any package name. Do you 
>>>> want to use it anyway?'
>>>>
>>>> If I say yes I can add it. However the feedback given seems to be 
>>>> wrong.
>>>>
>>>> Kind regards
>>>>
>>>> Hannes
>>>>
>>>> ------------------------
>>>>
>>>> exportAsPNG
>>>>     "Export the receiver's image as a PNG."
>>>>     self request: 'Enter file name'
>>>>         initialAnswer: (self printStringLimitedTo: 20),'.png'
>>>>         do: [:aString| (self imageForm: 32) writePNGfileNamed: 
>>>> aString]
>>>>
>>>
>>
>>
>
>


More information about the Cuis-dev mailing list