[squeak-dev] The Trunk: Graphics-mt.430.mcz

Thiede, Christoph Christoph.Thiede at student.hpi.uni-potsdam.de
Sun Apr 26 17:19:49 UTC 2020


> Does it matter if the text is white on black?


That was my doubt, exactly. :-)

Best,
Christoph
________________________________
Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org> im Auftrag von Jakob Reschke <forums.jakob at resfarm.de>
Gesendet: Montag, 20. April 2020 20:36:08
An: The general-purpose Squeak developers list
Betreff: Re: [squeak-dev] The Trunk: Graphics-mt.430.mcz

Does it matter if the text is white on black?

Note that "Smalltalk classNamed: ..." is not Environments-friendly unless we changed the default binding of #Smalltalk.

Also, why not use a Symbol for the class name? The bindings all have Symbols as keys anyway, so you might trigger a conversion on each invocation. Didn't look it up though.

Tobias Pape <Das.Linux at gmx.de<mailto:Das.Linux at gmx.de>> schrieb am Sa., 18. Apr. 2020, 16:30:

> On 18.04.2020, at 15:37, Thiede, Christoph <Christoph.Thiede at student.hpi.uni-potsdam.de<mailto:Christoph.Thiede at student.hpi.uni-potsdam.de>> wrote:
>
> > +                ifNil: [TextColor black "Fall back"]
>
> Do you think there would be the need for an explicit FallbackTextAttribute, which acts like a null object?

That's essentially what it is.
No need to overengineer.

Best regards
        -Tobias

> Von: Squeak-dev <squeak-dev-bounces at lists.squeakfoundation.org<mailto:squeak-dev-bounces at lists.squeakfoundation.org>> im Auftrag von commits at source.squeak.org<mailto:commits at source.squeak.org> <commits at source.squeak.org<mailto:commits at source.squeak.org>>
> Gesendet: Freitag, 17. April 2020 16:52:44
> An: squeak-dev at lists.squeakfoundation.org<mailto:squeak-dev at lists.squeakfoundation.org>; packages at lists.squeakfoundation.org<mailto:packages at lists.squeakfoundation.org>
> Betreff: [squeak-dev] The Trunk: Graphics-mt.430.mcz
>
> Marcel Taeumel uploaded a new version of Graphics to project The Trunk:
> http://source.squeak.org/trunk/Graphics-mt.430.mcz
>
> ==================== Summary ====================
>
> Name: Graphics-mt.430
> Author: mt
> Time: 17 April 2020, 4:52:36.27086 pm
> UUID: 1e5eac6b-e758-8445-b60e-7b09db8dcc63
> Ancestors: Graphics-nice.429
>
> Adds a simple way to use forms as text anchors without exposing Morphic, where such anchors are currently implemented.
>
> =============== Diff against Graphics-nice.429 ===============
>
> Item was added:
> + ----- Method: Form>>asTextAnchor (in category 'converting') -----
> + asTextAnchor
> +        "Convert the receiver to be embedded in text."
> +
> +        self flag: #refactor. "mt: Text anchors should work outside of Morphic, too. Any instance of Form could be embedded in Text."
> +        ^ (Smalltalk classNamed: 'TextAnchor')
> +                ifNil: [TextColor black "Fall back"]
> +                ifNotNil: [:cls | cls new anchoredMorph: self]!



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20200426/98316118/attachment.html>


More information about the Squeak-dev mailing list