[Cuis-dev] Pluggable button with icon

Juan Vuletich juan at cuis.st
Mon Aug 11 10:15:19 PDT 2025


I can't run that, because I don't have the context.

If I create a button with similar code, and open it, I see that by 
default it is quite small. It looks fine if I enlarge it. So, I guess 
the solution is to give it whatever extent you want.

I also see that #minimumExtent tries to be enough for at least some text 
to be visible, if ther is a label. If there's no label, #minimumExtent 
is really small. I can modify it to make it somewhat larger, but I can't 
guarantee it is the proper size for the use you are doing of it. Only 
you (I mean the programmer of the code using the button) can know and 
set that.

Hope this helps.

On 11/08/2025 10:31 AM, H. Fernandes via Cuis-dev wrote:
> When you execute the button instantiation as shown in the screenshots, it looks right for you?
>
> Dr. Geo -- http://gnu.org/s/dr-geo
>
> ----- Juan Vuletich <juan at cuis.st> a écrit :
>> Hi Hilaire,
>>
>> On 10/08/2025 6:04 PM, Hilaire Fernandes via Cuis-dev wrote:
>>> Am I misusing because label and icon do not look good together?
>>>
>>> Then when button with only icon it does not look good either:
>>>
>>>
>>>
>>> The button should look right on the first place, independently of the
>>> rounded or squared shape.
>>>
>> I don't know. I really don't. If you want, prepare an image for me and
>> I'll take a look.
>>
>> My previous answer was only to your suggestion of making #icon: call
>> #noButtonShape. In order to keep buttons with icon similar to buttons
>> with labels by default, I suggested making the call to #noButtonShape
>> yourself. That's a way to get the behaviour you suggested while keeping
>> consistent buttons for people using buttons with label and buttons with
>> icons together.
>>
>> If you want me to take a look at your code and make a suggestion, please
>> prepare an image (or a complete example that I can run on Cuis base.
>> This is of course better for me)
>>
>> Thanks,
>>
>>>
>>> Le 10/08/2025 à 21:14, Juan Vuletich a écrit :
>>>> Hi Hilaire,
>>>>
>>>> Other users have reported that a button shape should look with a
>>>> label and with an icon, unless the programmer says they want it
>>>> different. Sometimes it is impossible to please everybody. Can you
>>>> please send #noButtonShape in your code, prior or after calling #icon: ?
>>>>
>>>> Thanks,
>>>>
>>> -- 
>>> http://mamot.fr/@drgeo
>>>
>> -- 
>> Juan Vuletich
>> www.cuis.st
>> github.com/jvuletich
>> researchgate.net/profile/Juan-Vuletich
>> independent.academia.edu/JuanVuletich
>> patents.justia.com/inventor/juan-manuel-vuletich

-- 
Juan Vuletich
www.cuis.st
github.com/jvuletich
researchgate.net/profile/Juan-Vuletich
independent.academia.edu/JuanVuletich
patents.justia.com/inventor/juan-manuel-vuletich



More information about the Cuis-dev mailing list