• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSTextView undo/redo question
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSTextView undo/redo question


  • Subject: Re: NSTextView undo/redo question
  • From: Bill Cheeseman <email@hidden>
  • Date: Mon, 20 Aug 2001 15:56:18 -0400

on 8/19/01 10:31 PM, Brian Webster at email@hidden wrote:

> One approach that might help figure stuff out would be to create
> a subclass of NSUndoManager and override the
> registerUndoWithTarget:selector:object: and
> prepareWithInvocationTarget: methods to print out NSLogs keeping
> track of what undo actions are getting registered. You could at
> least use this method to try to figure out what objects to pass
> to removeAllActionsForTarget:.

I did this, and the target turns out always to be an instance of
NSConcreteTextStorage. This is a private class, so I can't think of any way
to pass it to removeAllActionsWithTarget:.

So I will have to pursue the first route you suggested, creating my own undo
manager for the text fields that are to have on-the-fly undo/redo, then
calling removeAllActions on that undo manager.

Thanks for your thoughts. You have helped me to focus on the problem.

--

Bill Cheeseman - email@hidden
Quechee Software, Quechee, Vermont, USA

The AppleScript Sourcebook - www.AppleScriptSourcebook.com
Vermont Recipes - www.stepwise.com/Articles/VermontRecipes


  • Follow-Ups:
    • Re: NSTextView undo/redo question
      • From: Bill Cheeseman <email@hidden>
References: 
 >Re: NSTextView undo/redo question (From: Brian Webster <email@hidden>)

  • Prev by Date: Re: I'll Bite
  • Next by Date: Re: Searchable Archives Are Here
  • Previous by thread: Re: NSTextView undo/redo question
  • Next by thread: Re: NSTextView undo/redo question
  • Index(es):
    • Date
    • Thread