When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg karlramberg@gmail.com wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
Thanks for working in this! =) Cheers, Eduardo
On Sat, 11 Mar 2023 at 11:48, karl ramberg karlramberg@gmail.com wrote:
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg karlramberg@gmail.com wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
On Sat, Mar 11, 2023 at 3:58 PM Eduardo Ochs eduardoochs@gmail.com wrote:
Thanks for working in this! =) Cheers, Eduardo
It's quite fun trying to fix these issues :-)
Additionally to my posted fix I think that turning text wrapping off should turn on horizontal scrollbar.
Best, Karl
On Sat, 11 Mar 2023 at 11:48, karl ramberg karlramberg@gmail.com wrote:
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg karlramberg@gmail.com wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
Hi Karl --
Please do not use TextMorohForEditView directly. Only interface it via PluggableTextMorph and there use hResizing and vResizing. I think. From the top of my hat 😅
wrapFlag and autoFit might interfere with each other unexpectedly.
If this does not solve the issue, I will take another look at the code there next week. 🙃 Sorry for the inconvenience.
Best, Marcel ________________________________ From: Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org on behalf of karl ramberg karlramberg@gmail.com Sent: Saturday, March 11, 2023 4:13:56 PM To: The general-purpose Squeak developers list squeak-dev@lists.squeakfoundation.org Subject: Re: [squeak-dev] [BUG] TextMorphForEditView wrapFlag
On Sat, Mar 11, 2023 at 3:58 PM Eduardo Ochs <eduardoochs@gmail.commailto:eduardoochs@gmail.com> wrote: Thanks for working in this! =) Cheers, Eduardo
It's quite fun trying to fix these issues :-)
Additionally to my posted fix I think that turning text wrapping off should turn on horizontal scrollbar.
Best, Karl
On Sat, 11 Mar 2023 at 11:48, karl ramberg <karlramberg@gmail.commailto:karlramberg@gmail.com> wrote: Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg <karlramberg@gmail.commailto:karlramberg@gmail.com> wrote: When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
Hi Marcel,
what do you think of adding comments like this one
Please do not use TextMorphForEditView directly. Only interface it via PluggableTextMorph...
to the code? This would help a lot the people like me who are learning Morphic mainly via the explorer and the debugger...
Cheers =), Eduardo Ochs
On Sat, 11 Mar 2023 at 15:23, Taeumel, Marcel via Squeak-dev < squeak-dev@lists.squeakfoundation.org> wrote:
Hi Karl --
Please do not use TextMorohForEditView directly. Only interface it via PluggableTextMorph and there use hResizing and vResizing. I think. From the top of my hat 😅
wrapFlag and autoFit might interfere with each other unexpectedly.
If this does not solve the issue, I will take another look at the code there next week. 🙃 Sorry for the inconvenience.
Best, Marcel
*From:* Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org on behalf of karl ramberg karlramberg@gmail.com *Sent:* Saturday, March 11, 2023 4:13:56 PM *To:* The general-purpose Squeak developers list < squeak-dev@lists.squeakfoundation.org> *Subject:* Re: [squeak-dev] [BUG] TextMorphForEditView wrapFlag
On Sat, Mar 11, 2023 at 3:58 PM Eduardo Ochs eduardoochs@gmail.com wrote:
Thanks for working in this! =) Cheers, Eduardo
It's quite fun trying to fix these issues :-)
Additionally to my posted fix I think that turning text wrapping off should turn on horizontal scrollbar.
Best, Karl
On Sat, 11 Mar 2023 at 11:48, karl ramberg karlramberg@gmail.com wrote:
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg karlramberg@gmail.com wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
On Sat, Mar 11, 2023 at 7:23 PM Taeumel, Marcel via Squeak-dev < squeak-dev@lists.squeakfoundation.org> wrote:
Hi Karl --
Please do not use TextMorohForEditView directly. Only interface it via PluggableTextMorph and there use hResizing and vResizing. I think. From the top of my hat 😅
There is no menu option to access the wrapFlag from PluggableTextMorph while there are menu options for TextMorphForEditView.
Best, Karl
wrapFlag and autoFit might interfere with each other unexpectedly.
If this does not solve the issue, I will take another look at the code there next week. 🙃 Sorry for the inconvenience.
Best, Marcel
*From:* Squeak-dev squeak-dev-bounces@lists.squeakfoundation.org on behalf of karl ramberg karlramberg@gmail.com *Sent:* Saturday, March 11, 2023 4:13:56 PM *To:* The general-purpose Squeak developers list < squeak-dev@lists.squeakfoundation.org> *Subject:* Re: [squeak-dev] [BUG] TextMorphForEditView wrapFlag
On Sat, Mar 11, 2023 at 3:58 PM Eduardo Ochs eduardoochs@gmail.com wrote:
Thanks for working in this! =) Cheers, Eduardo
It's quite fun trying to fix these issues :-)
Additionally to my posted fix I think that turning text wrapping off should turn on horizontal scrollbar.
Best, Karl
On Sat, 11 Mar 2023 at 11:48, karl ramberg karlramberg@gmail.com wrote:
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg karlramberg@gmail.com wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
Hi Karl, hi Eduardo --
Via Morphic-mt.2117, I removed those menu options from those TextMorphForEditView instances. You can still play around with the (more generic sounding) hResizing and vResizing though.
Best, Marcel Am 11.03.2023 19:54:09 schrieb karl ramberg karlramberg@gmail.com:
On Sat, Mar 11, 2023 at 7:23 PM Taeumel, Marcel via Squeak-dev <squeak-dev@lists.squeakfoundation.org [mailto:squeak-dev@lists.squeakfoundation.org]> wrote:
Hi Karl --
Please do not use TextMorohForEditView directly. Only interface it via PluggableTextMorph and there use hResizing and vResizing. I think. From the top of my hat 😅 There is no menu option to access the wrapFlag from PluggableTextMorph while there are menu options for TextMorphForEditView.
Best, Karl
wrapFlag and autoFit might interfere with each other unexpectedly.
If this does not solve the issue, I will take another look at the code there next week. 🙃 Sorry for the inconvenience.
Best, Marcel From: Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org [mailto:squeak-dev-bounces@lists.squeakfoundation.org]> on behalf of karl ramberg <karlramberg@gmail.com [mailto:karlramberg@gmail.com]> Sent: Saturday, March 11, 2023 4:13:56 PM To: The general-purpose Squeak developers list <squeak-dev@lists.squeakfoundation.org [mailto:squeak-dev@lists.squeakfoundation.org]> Subject: Re: [squeak-dev] [BUG] TextMorphForEditView wrapFlag
On Sat, Mar 11, 2023 at 3:58 PM Eduardo Ochs <eduardoochs@gmail.com [mailto:eduardoochs@gmail.com]> wrote:
Thanks for working in this! =) Cheers, Eduardo
It's quite fun trying to fix these issues :-)
Additionally to my posted fix I think that turning text wrapping off should turn on horizontal scrollbar.
Best, Karl
On Sat, 11 Mar 2023 at 11:48, karl ramberg <karlramberg@gmail.com [mailto:karlramberg@gmail.com]> wrote:
Attached is a change set that fixes turning text wrapFlag both on and off in TextMorphForEditView. I'm not familiar with the inner workings of these methods to say they are the correct fixes. The end result looks right but implementation is maybe a little clumsy.
Best, Karl
On Sat, Mar 11, 2023 at 10:44 AM karl ramberg <karlramberg@gmail.com [mailto:karlramberg@gmail.com]> wrote:
When a you turn preference wrapFlag off in TextMorphForEditViewyou get
Assertion failure in Morph>>#doLayoutIn: ... "2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ self removeProperty: #doLayoutAgain. layout flushLayoutCache. layout layout: self in: layoutBounds]. self assert: (self hasProperty: #doLayoutAgain) not]. ...
But redoing the layout can add the property #doLayoutAgain. I think this has to be changed to : ...
"2.2) Do one additional run on the layout if requested in #layoutInBounds:." (self hasProperty: #doLayoutAgain) ifTrue: [ layout flushLayoutCache. layout layout: self in: layoutBounds. self removeProperty: #doLayoutAgain.]. self assert: [(self hasProperty: #doLayoutAgain) not]]. ...
Best, Karl
squeak-dev@lists.squeakfoundation.org