<div dir="ltr">Thanks, Juan and Ken!<div><br></div><div><a class="gmail_plusreply" id="plusReplyChip-0" href="mailto:juan@jvuletich.org" tabindex="-1">@Juan Vuletich</a> I defined #submorphsMightProtrude to answer true and it worked like a charm.<br></div><div><br></div><div><a class="gmail_plusreply" id="plusReplyChip-1" href="mailto:ken.dickey@whidbey.com" tabindex="-1">@KenD</a> I (believe) I did that when trying to fix the bug, the challenge is how to shrink/wrap the parent morph whenever one of the submorphs changes. To make it work I took a look at the "morph lifecycle" and noticed that layoutSubmorphs is called before a morph is drawn. I redefined layoutSubmorphs in the parent and after calling super I compute the parent extent based on the submorphs to shrink/wrap. Its fine working so far, but I bet there will be unhandled edge cases.<br></div><div><br></div><div>Cheers,</div><div>Nico PM</div><div><br></div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Wed, Jul 28, 2021 at 12:28 PM Juan Vuletich via Cuis-dev <<a href="mailto:cuis-dev@lists.cuis.st">cuis-dev@lists.cuis.st</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On 7/27/2021 10:49 AM, ken.dickey--- via Cuis-dev wrote:<br>
> On 2021-07-26 19:01, Juan Vuletich via Cuis-dev wrote:<br>
> ..<br>
>> WRT your other question (I completely missed it earlier today), no. <br>
>> Cuis doesn't include "shrink wrap" morphs. I guess it shouldn't be <br>
>> difficult to implement it for your own morph. Cuis Layouts are based <br>
>> on the opposite idea: each morph decides the location and maybe <br>
>> extent of its submorphs.<br>
><br>
> Note that implementing shrink wrap is darn easy. Just use a <br>
> containing LayoutMorph and set its morphExtent to<br>
> LayoutMorph>>minimumExtent<br>
><br>
> FYI,<br>
> -KenD<br>
<br>
Great insight. Ken, you officially know more about Cuis Layouts than me!<br>
<br>
Thanks,<br>
<br>
-- <br>
Juan Vuletich<br>
<a href="http://www.cuis-smalltalk.org" rel="noreferrer" target="_blank">www.cuis-smalltalk.org</a><br>
<a href="https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev" rel="noreferrer" target="_blank">https://github.com/Cuis-Smalltalk/Cuis-Smalltalk-Dev</a><br>
<a href="https://github.com/jvuletich" rel="noreferrer" target="_blank">https://github.com/jvuletich</a><br>
<a href="https://www.linkedin.com/in/juan-vuletich-75611b3" rel="noreferrer" target="_blank">https://www.linkedin.com/in/juan-vuletich-75611b3</a><br>
@JuanVuletich<br>
<br>
-- <br>
Cuis-dev mailing list<br>
<a href="mailto:Cuis-dev@lists.cuis.st" target="_blank">Cuis-dev@lists.cuis.st</a><br>
<a href="https://lists.cuis.st/mailman/listinfo/cuis-dev" rel="noreferrer" target="_blank">https://lists.cuis.st/mailman/listinfo/cuis-dev</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature"><br>Nicolás Papagna</div>