<body><div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
                                        > ... <span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px">the usual workflow of copying and reusing the printIt string more complicated ...</span><div><span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px"><br></span></div><div><span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px">Note that print-it does not always produce a "store string" and is thus not always executable. ;-)</span></div><div><span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px"><br></span></div><div><span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px">Best,</span></div><div><span style="font-family: Calibri, Helvetica, sans-serif;font-size: 16px">Marcel</span></div><div class="mb_sig"></div><blockquote class="history_container" type="cite" style="border-left-style:solid;border-width:1px; margin-top:20px; margin-left:0px;padding-left:10px;">
                        <p style="color: #AAAAAA; margin-top: 10px;">Am 14.11.2019 12:58:22 schrieb Thiede, Christoph <christoph.thiede@student.hpi.uni-potsdam.de>:</p><div style="font-family:Arial,Helvetica,sans-serif">

<div id="divtagdefaultwrapper" style="font-size: 12pt;color: #000000;font-family: Calibri,Helvetica,sans-serif" dir="ltr">
<p>Hi Marcel,</p>
<p><br>
</p>
<p>yes, <cmd>0 still works. It is an interesting idea to put the link aside to the actual print string, but I have to admit that both approaches would make the usual workflow of copying and reusing the printIt string more complicated, unfortunately ...</p>
<p><br>
</p>
<p>Another idea, should we maybe consider some kind of TextMorph/editor extension that is indeed not affected by clipboard? Visually, something like:</p>
<p><br>
</p>
<p><img size="33002" contenttype="image/png" id="img253449" style="max-width: 99.9%; user-select: none;" contextid="img75704" tabindex="0" src="cid:c4954e41-9206-4223-ab5e-ea0d86e2d30e"></img><br>
</p>
<p><br>
</p>
<p>Such a text attachment would need to be laid out like regular TextAnchors, however, they must not be selected by the cursor. One could describe the idea as an extension to the TextAnchor that prohibits an editor to select it.</p>
<p><br>
</p>
<p>***</p>
<p><br>
</p>
<p>BTW: <span style="font-size: 12pt">Another related problem is that unless you
</span><span style="font-size: 12pt">delete the printed-it string, all following commands in a workspace will be miss-styled (see above)</span><span style="font-size: 12pt">. Someone recently mentioned that Pharo restarts styling after #code</span><span style="font-size: 12pt">E</span><span style="font-size: 12pt">xcess
 in each new line, which sounds great. Should we maybe add a similar feature to Shout?</span></p>
<p><span style="font-size: 12pt"><br>
</span></p>
<p><span style="font-size: 12pt">Best,</span></p>
<p><span style="font-size: 12pt">Christoph</span></p>
<div id="Signature">
<div name="divtagdefaultwrapper" style="font-family: Calibri,Arial,Helvetica,sans-serif;font-size: ;margin: 0">
<div><span style="font-size: 10pt;color: #808080"></span></div>
</div>
</div>
</div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><span style="font-family: Calibri, sans-serif;color: #000000"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel<br>
<b>Gesendet:</b> Donnerstag, 14. November 2019 09:28:58<br>
<b>An:</b> John Pfersich via Squeak-dev<br>
<b>Betreff:</b> Re: [squeak-dev] The Inbox: Morphic-ct.1586.mcz</span>
<div> </div>
</div>
<div>
<div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
> ... <span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">spread all over your workspace ...</span>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px"><br>
</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">What do you mean by that? Copy-and-paste of text should always
 carry those attributes. With "spreading" I thought you mean you would unintentionally extend those text links to other characters.</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px"><br>
</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">What about this style after a print-it :</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px"><br>
</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">World extent
<span style="background-color: rgb(198, 217, 240);">3840@2004 <span style="color: #4f81bd">
<b>[explore]</b></span></span></span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px"><br>
</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">Tricky. We want to preserve to preserve the actual #printString
 ... Does [cmd]+[0] still work?</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px"><br>
</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">Best,</span></div>
<div><span style="font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols;font-size: 16px">Marcel</span></div>
<div class="mb_sig"></div>
<blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
<p style="color: #AAAAAA; margin-top: 10px;">Am 13.11.2019 18:06:48 schrieb Thiede, Christoph <christoph.thiede@student.hpi.uni-potsdam.de>:</p>
<div style="font-family:Arial,Helvetica,sans-serif">
<div id="divtagdefaultwrapper" style="font-size: 12pt;color: #000000;font-family: Calibri,Helvetica,sans-serif" dir="ltr">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt;color: rgb(0, 0, 0);font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols">
<p>Hi Marcel,</p>
<p><br>
</p>
<p>Thanks for the hint, I played a bit around with emphasisHere. But if I am not mistaken, you cannot set emphasisHere for the next character to be typed while another text (the printIt result) is currently selected?</p>
<p><br>
</p>
<p>This is also only one half of the problem. Personally, I often copy one printIt result to use it at another place. (I know, variables would be a better option, however, I feel convenient to do this.) It looks kind of weird if this link is spread all over
 your workspace:</p>
<p><br>
</p>
<p><img size="23901" contenttype="image/png" id="img500184" style="max-width: 99.9%; user-select: none;" contextid="img448753" tabindex="0" src="cid:1a56dcc7-b8be-4dd1-81fa-4e9983c966f8"></img><!-- </img> --><br>
</p>
<p>So unless someone has a great idea to avoid this (a special RunArray of attributes that are private to an editor? a TextAttribute that cannot be copied?), I would rather tend to withdraw my proposal ...</p>
<p><br>
</p>
<p>(Btw: A somehow related issue is that the search bar accepts formatted text from clipboard but does not style it, so in my image, it often looks kind of missstyled:</p>
<p><img size="0" contenttype="image/png" id="img903039" style="max-width: 99.9%; user-select: none;" contextid="img196856" tabindex="0" src="cid:ddfbae54-9593-4ea1-aec1-7e552acbd8be"></img><!-- </img> -->)<br>
</p>
<p><br>
</p>
<p>Best,</p>
<p>Christoph</p>
<div id="Signature">
<div name="divtagdefaultwrapper" style="font-family: Calibri,Arial,Helvetica,sans-serif;font-size: ;margin: 0">
<div><span style="font-size: 10pt;color: #808080"></span></div>
</div>
</div>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><span style="font-family: Calibri, sans-serif;color: #000000"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel<br>
<b>Gesendet:</b> Dienstag, 12. November 2019 14:05:23<br>
<b>An:</b> John Pfersich via Squeak-dev<br>
<b>Betreff:</b> Re: [squeak-dev] The Inbox: Morphic-ct.1586.mcz</span>
<div> </div>
</div>
<div>
<div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
Is it because you do not append "emphasisHere" after your custom emphasis?
<div class="mb_sig"></div>
<blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
<p style="color:#AAAAAA; margin-top:10px">Am 12.11.2019 13:15:43 schrieb Thiede, Christoph <christoph.thiede@student.hpi.uni-potsdam.de>:</p>
<div style="font-family:Arial,Helvetica,sans-serif">
<div id="divtagdefaultwrapper" dir="ltr" style="font-size: 12pt;color: rgb(0, 0, 0);font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols">
<p>Only drawback: If you copy the result to use it for another computation, you spread the link formatting all over your code ...</p>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="divRplyFwdMsg" dir="ltr"><span style="font-family:Calibri,sans-serif; color:#000000"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von Taeumel, Marcel<br>
<b>Gesendet:</b> Dienstag, 12. November 2019 10:36:07<br>
<b>An:</b> John Pfersich via Squeak-dev<br>
<b>Betreff:</b> Re: [squeak-dev] The Inbox: Morphic-ct.1586.mcz</span>
<div> </div>
</div>
<div>
<div id="__MailbirdStyleContent" style="font-size: 10pt;font-family: Arial;color: #000000">
+1
<div><br>
</div>
<div>Best,</div>
<div>Marcel</div>
<div class="mb_sig"></div>
<blockquote class="history_container" type="cite" style="border-left-style: solid;border-width: 1px;margin-top: 20px;margin-left: 0px;padding-left: 10px;min-width: 500px">
<p style="color:#AAAAAA; margin-top:10px">Am 10.11.2019 16:07:23 schrieb Thiede, Christoph <christoph.thiede@student.hpi.uni-potsdam.de>:</p>
<div style="font-family:Arial,Helvetica,sans-serif">
<div dir="ltr">
<div id="x_divtagdefaultwrapper" dir="ltr" style="font-size: 12pt;color: rgb(0, 0, 0);font-family: Calibri, Helvetica, sans-serif, EmojiFont, "Apple Color Emoji", "Segoe UI Emoji", NotoColorEmoji, "Segoe UI Symbol", "Android Emoji", EmojiSymbols">
<p><img size="70473" id="x_img729163" tabindex="0" style="max-width: 99.9%; user-select: none;" src="cid:23717c7d-e38c-4ef9-b852-51c42943885d"></img><!-- </img> --><br>
</p>
<div id="x_Signature">
<div name="x_divtagdefaultwrapper" style="font-family: Calibri,Arial,Helvetica,sans-serif;font-size: ;margin: 0">
<div><span style="font-size: 10pt;color: #808080"></span></div>
</div>
</div>
</div>
<hr tabindex="-1" style="display:inline-block; width:98%">
<div id="x_divRplyFwdMsg" dir="ltr"><span style="font-family:Calibri,sans-serif; color:#000000"><b>Von:</b> Squeak-dev <squeak-dev-bounces@lists.squeakfoundation.org> im Auftrag von commits@source.squeak.org <commits@source.squeak.org><br>
<b>Gesendet:</b> Sonntag, 10. November 2019 16:06:26<br>
<b>An:</b> squeak-dev@lists.squeakfoundation.org<br>
<b>Betreff:</b> [squeak-dev] The Inbox: Morphic-ct.1586.mcz</span>
<div> </div>
</div>
</div>
<span style="font-size: 10pt"><span style="font-size: 10pt">
<div class="PlainText">A new version of Morphic was added to project The Inbox:<br>
<a href="http://source.squeak.org/inbox/Morphic-ct.1586.mcz" target="_blank" rel="noopener noreferrer" id="LPlnk113158" previewremoved="true">http://source.squeak.org/inbox/Morphic-ct.1586.mcz</a><br>
<br>
==================== Summary ====================<br>
<br>
Name: Morphic-ct.1586<br>
Author: ct<br>
Time: 10 November 2019, 4:06:17.228559 pm<br>
UUID: d752eb23-2116-0945-b043-aff08fed94fd<br>
Ancestors: Morphic-mt.1584<br>
<br>
Proposal: Style printIt results as a pluggable link that can be clicked to inspect the result.<br>
<br>
To enable this behavior, this commit also extends #insertAndSelect:at: to allow for inserting both strings and texts.<br>
<br>
=============== Diff against Morphic-mt.1584 ===============<br>
<br>
Item was changed:<br>
  ----- Method: PluggableTextMorph>>printIt (in category 'menu commands') -----<br>
  printIt<br>
         | oldEditor |<br>
         textMorph editor selectFrom: selectionInterval first to: selectionInterval last;<br>
                                                 model: model.  "For, eg, evaluateSelection"<br>
         textMorph handleEdit: [(oldEditor := textMorph editor) evaluateSelectionAndDo:<br>
                 [:result |<br>
                 selectionInterval := oldEditor selectionInterval.<br>
                 textMorph installEditorToReplace: oldEditor.<br>
+                textMorph handleEdit: [ oldEditor afterSelectionInsertAndSelect:<br>
+                        (oldEditor printTextFor: result)].<br>
-                textMorph handleEdit: [oldEditor afterSelectionInsertAndSelect: result printString].<br>
                 selectionInterval := oldEditor selectionInterval.<br>
         <br>
                 textMorph editor selectFrom: selectionInterval first to: selectionInterval last.<br>
                 self scrollSelectionIntoView]]!<br>
<br>
Item was changed:<br>
  ----- Method: TextEditor>>afterSelectionInsertAndSelect: (in category 'new selection') -----<br>
+ afterSelectionInsertAndSelect: aStringOrText<br>
- afterSelectionInsertAndSelect: aString<br>
  <br>
+        self insertAndSelect: aStringOrText at: self stopIndex !<br>
-        self insertAndSelect: aString at: self stopIndex !<br>
<br>
Item was changed:<br>
  ----- Method: TextEditor>>insertAndSelect:at: (in category 'new selection') -----<br>
+ insertAndSelect: aStringOrText at: anInteger<br>
- insertAndSelect: aString at: anInteger<br>
  <br>
+        aStringOrText isString ifTrue: [<br>
+                ^ self<br>
+                        insertAndSelect: (Text string: aStringOrText attributes: emphasisHere)<br>
+                        at: anInteger].<br>
-        self closeTypeIn.<br>
         <br>
+        self closeTypeIn.<br>
         self selectInvisiblyFrom: anInteger to: anInteger - 1.<br>
         self openTypeIn.<br>
  <br>
         self<br>
                 replace: self selectionInterval<br>
+                with: (Text string: ' ' attributes: emphasisHere), aStringOrText<br>
-                with: (Text string: (' ', aString) attributes: emphasisHere)<br>
                 and: [].<br>
- <br>
         self closeTypeIn.!<br>
<br>
Item was changed:<br>
  ----- Method: TextEditor>>printIt (in category 'do-its') -----<br>
  printIt<br>
  <br>
         self evaluateSelectionAndDo: [:result |<br>
                 (model respondsTo: #printIt:result:)<br>
                         ifTrue: [model<br>
                                 perform: #printIt:result:<br>
                                 with: self selection<br>
                                 with: result]<br>
+                        ifFalse: [self afterSelectionInsertAndSelect: (self printTextFor: result)]]!<br>
-                        ifFalse: [self afterSelectionInsertAndSelect: result printString]]!<br>
<br>
Item was added:<br>
+ ----- Method: TextEditor>>printTextFor: (in category 'do-its') -----<br>
+ printTextFor: anObject<br>
+ <br>
+        ^ Text<br>
+                string: anObject printString<br>
+                attributes: {PluggableTextAttribute evalBlock: [anObject inspect]}!<br>
<br>
<br>
</div>
</span></span></div>
</blockquote>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div>
</div>
</blockquote>
</div>
</div>
</div></blockquote>
                                        </div></body>