• 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
Saving doc loses NSTextView position/selection Re: Lion autosave...
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Saving doc loses NSTextView position/selection Re: Lion autosave...


  • Subject: Saving doc loses NSTextView position/selection Re: Lion autosave...
  • From: Fritz Anderson <email@hidden>
  • Date: Tue, 15 Nov 2011 10:46:45 -0600

On 11 Nov 2011, at 11:23 AM, Fritz Anderson wrote:

> On 11 Nov 2011, at 11:00 AM, Fritz Anderson wrote:
>
>> My application writes an XML document that includes styled text in the form of HTML. At the user end is an NSTextView; I use an in-memory Core Data store for working storage. The text view is bound to the backing NSManagedObject through an NSArrayController. I have an NSValueTransformer subclass between the text view and the array controller to translate between the attributed string and NSData containing the HTML.
> ...
>> Snatching the user's work from under his hands is a horrible experience. How can I fix this?
>
> I hate it when people rapid-fire updates to their questions, but…
>
> Removing the value transformer from the NSArray controller process between the text view and the model object doesn't help.
>
> In my model object, I added an NSAttributedString-valued on-demand @property; the getter and setter rely on the transformer to get and set the HTML string** CD attribute. The value still transits through the transformer, but I hoped that hiding it from the controller might help.
>
> It didn't. I still have the bug.

A further update. I turned autosave off; the bug doesn't trigger in the middle of work, but it does trigger on File > Save. Without autosave, the selection, scroll, and first responder status are lost _before_ entry to dataOfType:error:.

Autosave and -commitEditing were red herrings.

I'd like to provide a better experience than this. Can somebody please suggest a lead?

	— F

_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Saving doc loses NSTextView position/selection Re: Lion autosave...
      • From: Kyle Sluder <email@hidden>
References: 
 >Lion autosave loses NSTextView position/selection (From: Fritz Anderson <email@hidden>)
 >Re: Lion autosave loses NSTextView position/selection (From: Fritz Anderson <email@hidden>)

  • Prev by Date: Re: About iVars declaration and property
  • Next by Date: Re: About iVars declaration and property
  • Previous by thread: Re: Lion autosave loses NSTextView position/selection
  • Next by thread: Re: Saving doc loses NSTextView position/selection Re: Lion autosave...
  • Index(es):
    • Date
    • Thread