Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Shane Stanley
On 21/09/2012, at 4:12 PM, Kyle Sluder wrote: > My gut tells me you should remove that preference and direct your users to > Mountain Lion's General System Preferences instead. That doesn't help with Lion users, but I take your point about what's likely to happen. I'd prefer app-level control

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Kyle Sluder
On Sep 21, 2012, at 12:07 AM, Shane Stanley wrote: > >> And do you *really* want to test both save paths, especially when one is >> just a convenience wrapper around the other? > > I'm using just the one save path (fileWrapperOfType:error: because I'm saving > packages). What am I missing? I

drawGlyphsForGlyphRange layout issue

2012-09-21 Thread jonat...@mugginsoft.com
The following is used to draw a glyph representing a tab character in an NSLayoutManager subclass. When using say the Monaco font everything looks fine. When switching to Menlo however the glyphs drawn in the method below are positioned lower on the line than those drawn by the super implementati

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Uli Kusterer
On Sep 21, 2012, at 6:19 AM, Graham Cox wrote: > This might sound esoteric, but this is proving to be really, really common. > It's not just me - our users are complaining for exactly the same reason - > they make a change which they don't expect to "stick" because they > deliberately don't sav

Re: drawGlyphsForGlyphRange layout issue

2012-09-21 Thread Ross Carter
On Sep 21, 2012, at 6:54 AM, "jonat...@mugginsoft.com" wrote: > The following is used to draw a glyph representing a tab character in an > NSLayoutManager subclass. > When using say the Monaco font everything looks fine. > When switching to Menlo however the glyphs drawn in the method below ar

Re: NSDocument -close called multiple times?

2012-09-21 Thread Kevin Perry
Oh dear. Forget you heard me mention anything about unpublished API. The lack of an "_" threw me off... Yes, you'll probably want to keep your own flag. -KP On Sep 20, 2012, at 11:41 PM, Markus Spoettl wrote: > Just to clarify: -isClosed is not something that is available on NSDocument > or

Re: drawGlyphsForGlyphRange layout issue

2012-09-21 Thread Kyle Sluder
On Fri, Sep 21, 2012, at 03:54 AM, jonat...@mugginsoft.com wrote: > There is obviously something about the layout that I am missing here > which is implemented by the super implementation. > Any pointers would be appreciated. 1. Consider asking your question on the coretext-dev list. 2. Watch the

Re: NSDocument -close called multiple times?

2012-09-21 Thread Markus Spoettl
OK, so one further question: Is there any chance that if -close is called the document won't actually be closed and stays open? Regards Markus On 9/21/12 6:49 PM, Kevin Perry wrote: Oh dear. Forget you heard me mention anything about unpublished API. The lack of an "_" threw me off... Yes, y

Re: NSDocument -close called multiple times?

2012-09-21 Thread Kevin Perry
No. -[NSDocument close] is non-cancellable and non-reversible. On Sep 21, 2012, at 9:55 AM, Markus Spoettl wrote: > OK, so one further question: Is there any chance that if -close is called the > document won't actually be closed and stays open? > > Regards > Markus > > On 9/21/12 6:49 PM, Ke

iOS:targeting iOS3 through iOS6

2012-09-21 Thread John Michael Zorko
Hello, all … The iPhone5 and iOS6 is out now, so a client wants me to update the apps i've done for them. The thing is, they still have users on first-generation devices and iPhone 3Gs, so I need to make sure the apps still work there, while also taking advantage of the larger display of the n

iPad drawing and screen rotation

2012-09-21 Thread Donald Hall
I have a master detail project where I draw Bezier paths in the detail view. On rotation from portrait to landscape (or vice versa) the proportions of the drawings are distorted. For example, a circle in one orientation becomes an oval in the other. What is the best way to maintain the aspect ra

Re: kABHomeLabel … and companions

2012-09-21 Thread Vince DeMarco
On Sep 13, 2012, at 7:45 PM, Erik Stainsby wrote: > Hello folks, > > So the AddressBook framework's xxxLabel keys render out as strings encoded > like so: _$!!$_, _$!!$_, _$!!$_ Is there framework > method I am meant to use with the property keys kABHomeLabel, kABWorkLabel, > etc, to rende

Re: kABHomeLabel … and companions

2012-09-21 Thread Erik Stainsby
That is the one. Found it the other day. Tanks Vince. Erik Stainsby erik.stain...@roaringsky.ca On 2012-09-21, at 1:33 PM, Vince DeMarco wrote: > > On Sep 13, 2012, at 7:45 PM, Erik Stainsby > wrote: > >> Hello folks, >> >> So the AddressBook framework's xxxLabel keys render out as string

Re: drawGlyphsForGlyphRange layout issue

2012-09-21 Thread jonat...@mugginsoft.com
On 21 Sep 2012, at 17:12, Ross Carter wrote: > > On Sep 21, 2012, at 6:54 AM, "jonat...@mugginsoft.com" > wrote: > >> The following is used to draw a glyph representing a tab character in an >> NSLayoutManager subclass. >> When using say the Monaco font everything looks fine. >> When switchi

Re: iPad drawing and screen rotation

2012-09-21 Thread Jens Alfke
On Sep 21, 2012, at 12:18 PM, Donald Hall wrote: > I have a master detail project where I draw Bezier paths in the detail view. > On rotation from portrait to landscape (or vice versa) the proportions of the > drawings are distorted. For example, a circle in one orientation becomes an > oval

NSApplicationShowExceptions - useful on main thread only?

2012-09-21 Thread Sean McBride
Hi all, The 10.7 release notes say: "AppKit now has the ability to report uncaught exceptions. It is controlled by a user default: NSApplicationShowExceptions (YES/NO)" My next version will require 10.7+, so I'm finally taking a look at this thing. It seems that it only works for the main

NSSearchField(Cell) changes size with typing

2012-09-21 Thread Erik Stainsby
… and I can't stop it. Argh. There is nothing expressed in my code which addresses the searchField's size methods: – searchTextRectForBounds: – searchButtonRectForBounds: – cancelButtonRectForBounds: This is totally whacky and I'm hoping someone on the list has an immediate "Oh yes, just do x"

Re: NSSearchField(Cell) changes size with typing

2012-09-21 Thread Erik Stainsby
On 2012-09-21, at 4:06 PM, Erik Stainsby wrote: > … and I can't stop it. Argh. > > There is nothing expressed in my code which addresses the searchField's size > methods: > – searchTextRectForBounds: > – searchButtonRectForBounds: > – cancelButtonRectForBounds: > > This is totally whacky and I

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Michael Vannorsdel
I think if you have really good undo support people find autosave less of an annoyance. Most people took advantage of the save-before-experimenting method because several apps had bad or nonexistent undo support so saving was the only way to reliably go back. On Sep 21, 2012, at 10:05 AM, Uli

How to prevent Segue with modal form-sheet and AutoLayout from resizing my view?

2012-09-21 Thread Michael Crawford
This problem is kind of tough to describe without pictures. Thus, there will be links to graphical images to help you understand my dilemma. So, I'm trying to display a modal form-sheet over the app's main view using Storyboards and a segue. I'm using Xcode 4.5 with iOS 6 to implement an iPad

Re: drawGlyphsForGlyphRange layout issue

2012-09-21 Thread Graham Cox
On 21/09/2012, at 8:54 PM, jonat...@mugginsoft.com wrote: > The following is used to draw a glyph representing a tab character in an > NSLayoutManager subclass. You might investigate an alternative (and much easier) solution. NSLayoutManager adopts the NSGlyphStorage protocol. That protocol d

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Alex Zavatone
We had a problem recently in that I was telling my team members to duplicate a PNG file be doing a save as and turning the alpha channel off. They were in Lion and you couldn't Save As out of Preview and name a file a new name and turn off the alpha channel. In the time it took him to try and

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Graham Cox
On 22/09/2012, at 2:05 AM, Uli Kusterer wrote: > I run into it as well. But less and less. It's the same as the reversal of > the scroll wheel direction: It's hard to undo more than a decade of rote > memorization. But it's possible It's an aspect of having to manually save > that we power us

Re: drawGlyphsForGlyphRange layout issue

2012-09-21 Thread Kyle Sluder
On Fri, Sep 21, 2012, at 05:33 PM, Graham Cox wrote: > Another approach is to override > -showCGGlyphs:positions:count:font:matrix:attributes:inContext: which is > the primitive drawing method. All of the positioning and context > flippedness has been handled by this point, so you can usually just

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Ben Kennedy
On 21 Sep 2012, at 4:24 pm, Michael Vannorsdel wrote: > I think if you have really good undo support people find autosave less of an > annoyance. I think if you have really good first aid service then people find repeatedly tripping down the stairs less of an annoyance. b -- Ben Kennedy, chi

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Kyle Sluder
On Sep 21, 2012, at 6:20 PM, Ben Kennedy wrote: > On 21 Sep 2012, at 4:24 pm, Michael Vannorsdel wrote: > >> I think if you have really good undo support people find autosave less of an >> annoyance. > > I think if you have really good first aid service then people find repeatedly > tripping

Re: iPad drawing and screen rotation

2012-09-21 Thread Gordon Apple
Anybody remember Steve Jobs having a fit about ³square pixels² somewhere back in the Lisa or early Mac days? The scale should not change on a rotation, unless you are somehow setting the bounds rect in your drawing view instead of the frame rect when rotated. That could do it. On 9/21/12 7:50 P

Re: Autosave in place - common use case that makes me hate it

2012-09-21 Thread Mikevann
I'm mostly saying is it's something we have to cope with and find ways to make it work for special cases since it's hard to get Apple to let go of mechanics they created to try and make life easier for users (it can be argued whether or not this is true). I've tried the duplicating a backup in

Re: kABHomeLabel … and companions

2012-09-21 Thread Richard Heard
On iOS you would be looking for ABPersonCopyLocalizedPropertyName() on the Mac you would be looking for ABCopyLocalizedPropertyOrLabel(). -Richard On 13/09/2012, at 9:33:06 PM, Erik Stainsby wrote: > I understand that ABAddressBook methods are concerned with ABPerson and > ABGroup entities,

Re: Access Contacts (Address Book) Question

2012-09-21 Thread Jason T. Miller
Per the tccutil(1) man page, you can clear Contacts privacy preferences with the shell command tccutil reset AddressBook The "why" string comes from the NSContactsUsageDescription ("Privacy - Contacts Usage Description" in Xcode) key in Info.plist: $ defaults read "/Applications/iWork

Share NSView between processes

2012-09-21 Thread Zak Nelson
At a high level, I'd like to share an NSView between processes. On Windows, you can share HWNDs across the process boundary, but on mac this doesn't seem possible (http://stackoverflow.com/questions/583202/mac-os-x-can-one-process-render-to-another-processs-window). To get around this, I'm hidi

Toddler-proofing an app (disabling spotlight keyboard shortcut)?

2012-09-21 Thread Clay Heaton
My 20 month old daughter loves to bang on the keys of the keyboard. I made a simple cocos2d app that shows random animal pictures (with noises) when she presses keys. (This has proved very popular with her and she now can identify all of the animals!) Anyhow, she'll sit on my lap and bang the keyb

Re: iOS:targeting iOS3 through iOS6

2012-09-21 Thread Igor Elland
From my experience that's correct. Apple don't want you to support old hardware so they don't facilitate. When you update Xcode it even deleted old versions if it can find. Also new Xcode doesn't support compiling for pre armv7 (if I'm not mistaken here) meaning only 3GS and newer (iPad one is g

Re: iOS:targeting iOS3 through iOS6

2012-09-21 Thread Rick Mann
On Sep 21, 2012, at 12:29 , Igor Elland wrote: >> 1. Is this correct? If not, how do I target old and new devices? No. Set the deployment target to 3.0. You'll have to take care not to use any new APIs, though. Apple doesn't provide an easy way to ensure you're not doing that. I recommend tes

Re: Share NSView between processes

2012-09-21 Thread Mikevann
Well there's CGEventPostToPSN (note you need the ProcessSerialNumber for the process and not its unix pid) but that's mostly useful if you're trying to control an app that's not yours. It might be a better approach to go the IPC route setting up communications and trading data objects between t

Re: NSApplicationShowExceptions - useful on main thread only?

2012-09-21 Thread Ken Thomases
On Sep 21, 2012, at 5:20 PM, Sean McBride wrote: > The 10.7 release notes say: > > "AppKit now has the ability to report uncaught exceptions. It is controlled > by a user default: NSApplicationShowExceptions (YES/NO)" > > My next version will require 10.7+, so I'm finally taking a look at t

Re: Share NSView between processes

2012-09-21 Thread Ken Thomases
On Sep 19, 2012, at 9:05 PM, Zak Nelson wrote: > At a high level, I'd like to share an NSView between processes. That's not a high level. That's a pre-determined implementation approach, which is at best mid-level. You should really rethink this. As stated – "share an NSView between processe