Questions tagged [nsundomanager]

`NSUndoManager` is a general-purpose recorder of operations for undo and redo.

222 questions
2
votes
0 answers

Removing redo actions in NSUndoManager

I am facing an architecture question and I am wondering if anyone know if my idea is feasible or has a better architecture idea. My situation is that I have CoreData data model for tracking some financial data, imagine it is bank accounts (it's not…
pco494
  • 371
  • 1
  • 9
2
votes
0 answers

NSUndoManager beginUndoGrouping appears to happen twice, when only called once?

I have a popover that opens and closes. When it opens, I call -beginUndoGrouping on my NSUndoManager. When it closes, I call -endUndoGrouping. If I view my undo stack after the fact, I see this: 0: endUndoGrouping 1: endUndoGrouping 2:…
A O
  • 5,516
  • 3
  • 33
  • 68
2
votes
0 answers

Restoring undoManager of UITextView

In my app I have a class inherited from UITextView and I need to create and destroy many instances of this view on screen. So my question - is there a way to save (before destroy) and then restore (after create) undo/redo stacks of each instance? //…
BorisR
  • 514
  • 1
  • 4
  • 19
2
votes
1 answer

Are NSUndomanager changes persisted between launches with CoreData

I'm implementing undos in an app using CoreData. My app also uses State Restoration. What's not clear to me from the docs is if the NSUndoManager will persist its undo history between launches / state restoration? It's not a major issue if it…
Mark Bridges
  • 8,228
  • 4
  • 50
  • 65
2
votes
2 answers

Is it possible to implement mutliple NSUndoManager for one NSWindow?

I have a window with multiple views (they all subclass NSView and there is always only one visible) on which i draw paths. I'd like to have an NSUndoManager for each view, but obviously they all have the same NSUndoManager, coming from the…
xon1c
  • 423
  • 5
  • 12
2
votes
2 answers

NSTextView undo/redo attribute changes (when not first responder)

I'm building a basic text editor with custom controls. For my text alignment control, I need to cover two user scenarios: the text view is the first responder - make the paragraph attribute changes to…
Kyle Truscott
  • 1,537
  • 1
  • 12
  • 18
2
votes
1 answer

Disable NSUndoManager grouping invocations on document load

NSUndoManager groups invocations together that happen in the same runloop. I want to load a document that contains the undo history within it. As such, I create a document and apply the invocations one-by-one, these however all get added very…
Chris
  • 2,739
  • 4
  • 29
  • 57
2
votes
1 answer

Undo/Redo Operation doesn't work with Bold,italic, Background and Foreground text color in UITextview

As User enter some text in UITextview, User applies some operation like Bold, italic, Underline, Bullet, Background and Foreground color to the specific text.When Undo/redo operation is applied, it will erase the whole word instead of eliminating…
mohsin
  • 530
  • 5
  • 24
2
votes
1 answer

NSUndoManager basics

I made an app which has a button, when you press it, it becomes disabled and Undo action should return it to the previous state (enable it). I used NSUndoManager to make this possible, but it doesn't work. It seems I'm missing something essential in…
Yashman
  • 111
  • 1
  • 11
2
votes
1 answer

make NSUndoManager ignore a property of an NSManagedObject

My app's main function is to arrange objects on a plot. The whole thing is based on Core Data, and each object on the plot is represented by an entity. For this example, that entity will be "Unit," a custom subclass of NSManagedObject. When the plot…
2
votes
1 answer

NSUndoManager : revert all the functionality of method

I search lot about it but can't get more detail about what I want. Is it possible to reverse all the functionality performed any method with the help of NSUndoManager class. For example : suppose I am deleting any row from table view or remove any…
Pratik Bhiyani
  • 2,489
  • 3
  • 17
  • 27
2
votes
0 answers

Implementing NSUndoManager with Paint Application

I am new to iOS and building a paint application. Everything goes ok..but I am unable to implement NSUndoManager in my application for undo and redo purpose. The problem is that I am unable to store the previous state of painting for undo. Here is…
Santosh
  • 1,254
  • 2
  • 16
  • 31
2
votes
2 answers

NSUndoManager setActionName: doesn't change menu text

I've been implimenting undo features for my cocoa app (OS 10.9), and I have successfully implemented an instance of an undo feature using NSUndoManager. However, I cannot get the "Undo" text to change under the edit menu! I am using the…
Stuart Barth
  • 301
  • 2
  • 10
2
votes
1 answer

How to disable the NSUndoManager in an NSDocument?

I'm using NSDocument but I would like to disable the undo manager. How can I do it?
Colas
  • 3,473
  • 4
  • 29
  • 68
2
votes
0 answers

Implement NSUndomanager in tutorial code

trying to implement undo function in smooth drawing app that I did following this tutorial http://mobile.tutsplus.com/tutorials/iphone/ios-sdk_freehand-drawing/ From what I read, using NSUndoanager is the best way of doing it, but I am not seeing…
user2067051
  • 99
  • 2
  • 15