Changeset 6857


Ignore:
Timestamp:
Jul 20, 2007, 7:59:00 PM (13 years ago)
Author:
gb
Message:

tweak #/paste; still not right

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ide-1.0/ccl/examples/cocoa-editor.lisp

    r6817 r6857  
    676676        ;; We toggle the blinked character "off" by setting its
    677677        ;; foreground color to the textview's background color.
    678         ;; The blinked character should be "on" whenever the insertion
     678        ;; The blinked character should be "off" whenever the insertion
    679679        ;; point is drawn as "off"
    680680        (ns:with-ns-range  (char-range (text-view-blink-location self) 1)
     
    691691              (#_NSRectFill rect))
    692692          (if flag
    693             (#/drawGlyphsForGlyphRange:atPoint: layout glyph-range (#/textContainerOrigin self)))))))
    694     (call-next-method r color flag)))
     693            (#/drawGlyphsForGlyphRange:atPoint: layout glyph-range (#/textContainerOrigin self))))))))
     694  (call-next-method r color flag))
    695695
    696696
     
    24352435        (#/replaceOccurrencesOfString:withString:options:range:
    24362436                string *ns-cr-string* *ns-lf-string* #$NSLiteralSearch (ns:make-ns-range 0 (#/length string))))
    2437       (let* ((textstorage (#/textStorage self))
    2438              (selectedrange (#/selectedRange self)))
    2439         (#/replaceCharactersInRange:withString: textstorage selectedrange string)))))
     2437      (let* ((textstorage (#/textStorage self)))
     2438        (unless (eql 0 (slot-value textstorage 'append-edits))
     2439          (#/setSelectedRange: self (ns:make-ns-range (#/length textstorage) 0)))
     2440        (let* ((selectedrange (#/selectedRange self)))
     2441          (#/replaceCharactersInRange:withString: textstorage selectedrange string))))))
    24402442
    24412443(objc:defmethod (#/hyperSpecLookUp: :void)
Note: See TracChangeset for help on using the changeset viewer.