[Bug] TextMorph 'text color...' interface applies style toentire text not just selection

Ken Causey ken at kencausey.com
Fri Feb 21 23:33:56 UTC 2003


Ah thanks for this reply.  I suspected that but then decided that I was
wrong since the interface certainly implies that the text may be
composed of mixed fonts.  Rereading the class comment for Text now with
this concept in mind I can see that implied but not explicitly stated. 
Am I to think then that changing the font number can only change the
size?

Ken

On Fri, 2003-02-21 at 17:28, Bob Arning wrote:
> Ken,
> 
> This behavior is something general to TextMorph - it is biased toward having one TextStyle for the entire text. It is quite happy with different sizes, colors and other emphasis, but it takes a little extra work to get it to accept a different font mid-stream.
> 
> Cheers,
> Bob
> 
> On 21 Feb 2003 17:07:13 -0600 Ken Causey <ken at kencausey.com> wrote:
> >On Fri, 2003-02-21 at 16:39, Ned Konz wrote:
> >> On Friday 21 February 2003 01:24 pm, Ken Causey wrote:
> >> > Tested in both 5156 and 5169 updated images.  Grab a TextMorph and
> >> > choose 'text color...' from the halo menu.  Uncheck 'Apply changes
> >> > to entire text' and select part of the text.  Choose a style from
> >> > the Style popup menu.  When it is applied it is applied to the
> >> > entire text not just to the selected text.
> >> 
> >> Actually, it doesn't affect the entire text, but it affects from the 
> >> beginning of the selected text to the end of the text.
> >> 
> >> So if you select some characters in the middle of the text and change 
> >> them, the ones before your selection don't get changed.
> >
> >I am unable to reproduce what you describe in 3.4b-5169.  If I have a
> >TextMorph containing the String 'This is a test of the emergency
> >broadcasting system' and select 'test of the emergency' and change the
> >style then the font of the entire String changes, both in the preview
> >and, when I choose accept, in the original TextMorph (or when I choose
> >cancel for that matter).  Oh and I doo have 'Apply changes to entire
> >text' unchanged.  To make this clear I started with a downloaded
> >3.4b-5156 image and loaded code updates, rejected 3.5 change, then
> >saved, exitted, restarted, and loaded code updates again to get to
> >5169.  For what it's worth this behaviour is identical in the generic
> >5156 image.
> 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20030221/e94caf8d/attachment.pgp


More information about the Squeak-dev mailing list