• 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: Document Saving
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Document Saving


  • Subject: Re: Document Saving
  • From: Bryan Blackburn <email@hidden>
  • Date: Wed, 6 Nov 2002 01:21:19 -0700
  • Mail-followup-to: email@hidden

What I do is implement the NSTextView delegate method

- (NSUndoManager *) undoManagerForTextView:(NSTextView *)view

to return a different undo manager than the NSDocument manager.

Bryan


On Nov 5, 2002 21:47, James Derry stated:
> I just ran into this problem myself today. Your TextView probably has Undo
> enabled. This causes your document to increment its change count. One
> solution is to disable undo in your TextView. The approach I took is to
> implement my own change-counter and use [NSDocument updateChangeCount:] (I
> think that's the method name!) to set what I felt was the "correct"
> dirty-document state.
>
> If I get some time, I'm planning on figuring out how to subclass NSTextView
> (or one of its many, many hidden classes) to enable Undo in the TextView
> while NOT influencing the document-class change count.
>
> Uh, unless anyone has a better idea or has already done that work???
>
> Jim Derry
> --me
>
>
> On 11/5/02 12:36 PM email@hidden wrote:
> > I'm using a Document-Based Cocoa Application template. For some reason when I
> > edit my TextView and close the window, it automatically makes the save dialog
> > show up. How can I stop this from happening? Thanks.
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Document Saving (From: James Derry <email@hidden>)

  • Prev by Date: netinfod - rpc: timed out problem
  • Next by Date: Re: drawing with transparency
  • Previous by thread: Re: Document Saving
  • Next by thread: redirect stderr
  • Index(es):
    • Date
    • Thread