[squeak-dev] The Trunk: System-mt.1403.mcz

Marcel Taeumel marcel.taeumel at hpi.de
Tue Mar 28 07:46:36 UTC 2023


Hmm... hmm... well, it is a more usable test than Text >> #unembellished ... hmm...
https://en.wikipedia.org/wiki/Plain_text [https://en.wikipedia.org/wiki/Plain_text]


"In principle, plain text can be in any encoding, [...]" ... this also feeds into the "Why are ByteStrings not yet decoded? There are ByteArrays for encoded stuff." discussion.

Well, begin "plain text" surely is *some* domain or interpretation... not sure how it relates to Smalltalk and how textual content is represented in the image... hmm...

Ha! "Our" current (practical) interpretation of instances of Text being "plain" is "no attributes but text alignment":

TextMorph >> newContents:
[...]
self plainTextOnly ifTrue: [ newText removeAttributesThat: [:att | att isTextAlignment not] ].

[...]

Any more thoughts? I would at least keep it consistent... throughout the image...

Best,
Marcel
Am 28.03.2023 08:42:01 schrieb Eliot Miranda <eliot.miranda at gmail.com>:
Doesn’t seem domain specific to me. Instead it answers whether a text has any emphasis or not. By definition strings don’t.

_,,,^..^,,,_ (phone)

> On Mar 27, 2023, at 1:01 AM, commits at source.squeak.org wrote:
>
> Marcel Taeumel uploaded a new version of System to project The Trunk:
> http://source.squeak.org/trunk/System-mt.1403.mcz
>
> ==================== Summary ====================
>
> Name: System-mt.1403
> Author: mt
> Time: 27 March 2023, 10:00:56.498651 am
> UUID: 106cd43c-6be0-314c-ac46-e16bf55f8a89
> Ancestors: System-eem.1402
>
> As usual, move domain-specific string/text messages into extension protocol. Use *System-Support for now but it could be *Network as well or something that relates to the underlying MIME classification (here: text/plain).
>
> =============== Diff against System-eem.1402 ===============
>
> Item was added:
> + ----- Method: String>>isPlainText (in category '*System-Support') -----
> + isPlainText
> + "For compatibility with Text"
> + ^true!
>
> Item was added:
> + ----- Method: Text>>isPlainText (in category '*System-Support') -----
> + isPlainText
> + "A Text with no emphasis has empty values."
> + ^runs values = #(#())!
>
>

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


More information about the Squeak-dev mailing list