[squeak-dev] The Trunk: Morphic-cmm.756.mcz
eliot.miranda at gmail.com
Mon Feb 2 01:57:40 UTC 2015
On Sun, Feb 1, 2015 at 1:05 PM, Chris Muller <asqueaker at gmail.com> wrote:
> ParagraphEditor is in ST-80, so not part of this package. Speaking of
> that, is a corresponding change to ParagraphEditor necessary? Is
> ParagraphEditor intended to be purged at some point?
Not necessarily. People use it as a way of reducing footprint. Whether we
can afford to keep it going long term is debatable but so far people like
David Lewis have done a good job of keeping it working. So by all means
fix compare to clipboard therein.
> On Sun, Feb 1, 2015 at 1:06 PM, <commits at source.squeak.org> wrote:
> > Chris Muller uploaded a new version of Morphic to project The Trunk:
> > http://source.squeak.org/trunk/Morphic-cmm.756.mcz
> > ==================== Summary ====================
> > Name: Morphic-cmm.756
> > Author: cmm
> > Time: 1 February 2015, 1:06:11.045 pm
> > UUID: c1553853-472d-45ca-a182-c07497c6f7a9
> > Ancestors: Morphic-cmm.755
> > - Present the comparison to clipboard text from the context of
> paste-modification, since that is what the user is determining whether to
> do with the clipboard contents.
> > - Make the same change to ParagraphEditor, for consistency.
> > =============== Diff against Morphic-cmm.755 ===============
> > Item was changed:
> > ----- Method: TextEditor>>compareToClipboard (in category 'menu
> messages') -----
> > compareToClipboard
> > + "If any text is selected, present the modifications that would
> be made to it if the clipboard contents were pasted over it. If no text is
> selected, present the differences betwen the entire pane's contents and the
> clipboard text."
> > + | subjectText proposedText |
> > + subjectText := self selection string ifEmpty: [ paragraph text
> string ].
> > + proposedText := self clipboardText string.
> > + subjectText = proposedText ifTrue: [^ self inform: 'Exact
> > + (StringHolder new
> > + textContents:
> > + (TextDiffBuilder
> > + buildDisplayPatchFrom: subjectText
> > + to: proposedText)) openLabel:
> 'Differences with Clipboard Text'!
> > - "Check to see if whether the receiver's text is the same as the
> text currently on the clipboard, and inform the user."
> > - | s1 s2 |
> > - s1 := self clipboardText string.
> > - s2 := self selection string.
> > - s1 = s2 ifTrue: [^ self inform: 'Exact match'].
> > -
> > - (StringHolder new textContents:
> > - (TextDiffBuilder buildDisplayPatchFrom: s1 to: s2))
> > - openLabel: 'Comparison to Clipboard Text'!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Squeak-dev