[Cuis-dev] FYI. VectorGraphics freezes World. CuisBook procedure.

Juan Vuletich juan at jvuletich.org
Tue Jul 20 19:31:23 PDT 2021


Done. Just pushed another update. Please tell how it goes.

Cheers,

On 7/20/2021 6:34 PM, Juan Vuletich via Cuis-dev wrote:
> The truth is that all I need to move to the Canvas is the specific 
> methods to draw the icons in window controls. There are Form in 
> BitBltCanvas, but just drawing calls in VectorGraphicsCanvas. Let my 
> try to partially revert the changes, and see if I can get VG drawing 
> the icons, without reducing the flexibility you need.
>
> Thanks,
>
> On 7/20/2021 6:14 PM, Gerald Klix via Cuis-dev wrote:
>> I just looked into it, and discovered your changes as you
>> discribed them.
>>
>> This move is a bit unfortunate, because
>> I overwrote many of the drawing methods.
>> Only drawRoundGradientLookOn: and draw3DLookOn:
>> are expected to be definded in the super class.
>> Sending the corespoinding messages to the canvas won't
>> do the job, because these methods delegate the icon
>> drawing not the canvas and not my subclass.
>> I don't want the icons to be magnified that much.
>> Maybe factroring out the magniofaction factors
>> might do the job. Also the icons are displayed left of
>> label.
>>
>> I'll look into it tommorrow and try to come up with
>> a solution, its 23:10 here.
>>
>> Just one remark (or rant):
>> I can't the my this solution is cleaner:
>> Now Canavs defines the geometry of Button
>> and not the button itself.
>>
>>
>> Thanks for your help and Best Regards,
>>
>> Gerald
>>
>>
>> On 7/20/21 10:57 PM, Juan Vuletich via Cuis-dev wrote:
>>> Nice to know. WRT PluggableButtonMorph, I did several changes that 
>>> move to BitBltCanvas all the BitBlt related code, having a cleaner 
>>> interface to the Canvas, that can also be implemented by 
>>> VectorGraphicsCanvas. If you need help updating your code, just tell.
>>>
>>> Cheers,
>>>
>>> On 7/20/2021 5:50 PM, Gerald Klix via Cuis-dev wrote:
>>>> Hi Juan,
>>>>
>>>> this solved most of my problems with Haver and the latest updates.
>>>> My subclass of PlugableButtonMorph does not work any
>>>> more, but this issue should be easy to find and fix.
>>>>
>>>>
>>>> Thanks a lot,
>>>>
>>>> Gerald
>>>>
>>>>
>>>> On 7/20/21 10:08 PM, Juan Vuletich via Cuis-dev wrote:
>>>>> On 7/18/2021 6:37 AM, Nicola Mingotti via Cuis-dev wrote:
>>>>>>
>>>>>> Hi guys,
>>>>>>
>>>>>> I was reading the Cuis Book in the last flight and trying some 
>>>>>> stuff.
>>>>>>
>>>>>> I found this ugly situation where following chapter 7 procedure 
>>>>>> "going vector"
>>>>>> and doing :
>>>>>> ----
>>>>>> Feature require: 'VectorGraphics'
>>>>>> ----
>>>>>>
>>>>>> Freezes the World. I tried in Mac and Linux. Recently downloaded 
>>>>>> from Git.
>>>>>> Same behavior.
>>>>>>
>>>>>> I can't fix it myself, but I let you know there is a problem.
>>>>>>
>>>>>> I humbly recommend you not to put 'experimental' procedures in 
>>>>>> the beginner book.
>>>>>> Or to mark them in red and say well to prepare a separate image 
>>>>>> before running
>>>>>> those lines ... or the beginner will get into troubles ;)
>>>>>>
>>>>>> I see in another image i have 'VectorGraphics' already loaded,
>>>>>> probably it loaded as a dependency when I installed 'StyledText'.
>>>>>> So, i deduce the prolbem is on loading 'VectorGraphics' alone.
>>>>>>
>>>>>> bye
>>>>>> Nicola
>>>>>
>>>>> Hi Nicola,
>>>>>
>>>>> Most likely the problem you found was because when you pull the 
>>>>> repo, you get the latest VectorGraphics.pck.st and a bunch of 
>>>>> numbered updates. Some of those updates might be needed for the 
>>>>> package to run properly, but they are not installed by default. So 
>>>>> things could break if updates are not manually loaded before 
>>>>> installing Vector Graphics. This is of course not good!
>>>>>
>>>>> Today I pushed several updates that:
>>>>>
>>>>> - Include new images. All updates up to now are pre loaded.
>>>>> - Actually add the update number as a prerequisite to 
>>>>> VectorGraphics.pck.st. If you try to load it without the required 
>>>>> updates to the base image, it won't load and will give a hopefully 
>>>>> useful error message. This will help in the future.
>>>>>
>>>>> We don't want people to find broken stuff like that. We try to be 
>>>>> careful to avoid it as much as possible, and to fix things quickly 
>>>>> when we break them. Thanks for reporting this. It really helps!
>>>>>
>>>>> Cheers,
>>>>>
>>>>>
>>>
>>>
>
>


-- 
Juan Vuletich
www.cuis-smalltalk.org
https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev
https://github.com/jvuletich
https://www.linkedin.com/in/juan-vuletich-75611b3
@JuanVuletich



More information about the Cuis-dev mailing list