Sandboxing: Can't bookmark enclosing folder of user-selected file

2013-12-22 Thread Leo
I'm sandboxing an app for the first time. The app has been out for a few years by now, non-sandboxed. The app receives batches of PDF files and exports them with some changes. Users can select files from NSOpenPanel or drag-and-drop. There are two options: -export files into a specific

Re: CALayer's delegate prevents implicit animation?

2013-12-22 Thread Uli Kusterer
On 18 Dec 2013, at 21:46, Sean McBride s...@rogue-research.com wrote: Wait, what? You're saying a CALayer's delegate can't be its parent NSView? Why? Where does it say that? I've been doing that for years without apparent problem. I'd be interested to hear more… It broke with 10.9 at

NSArray firstObject?

2013-12-22 Thread Trygve Inda
https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Founda tion/Classes/NSArray_Class/NSArray.html#//apple_ref/doc/uid/2137-SW40 firstObject Returns the first object in the array. - (id)firstObject Return Value The first object in the array. If the array is empty, returns

Re: NSArray firstObject?

2013-12-22 Thread Michael Starke
It's been a private API until 10.9 and iOS 7. Clearly a documentation error. On 22 Dec 2013, at 18:31, Trygve Inda cocoa...@xericdesign.com wrote: https://developer.apple.com/library/mac/documentation/Cocoa/Reference/Founda

Re: NSArray firstObject?

2013-12-22 Thread Seth Willits
On Dec 22, 2013, at 9:31 AM, Trygve Inda cocoa...@xericdesign.com wrote: Available in OS X v10.6 and later. This seems to be an error in the docs as the method does not seem to exist for me. What do you mean? As I recall, when it was announced at WWDC the method become public only

Re: NSArray firstObject?

2013-12-22 Thread Maxthon Chan
Yes. This method is there since 10.6 so you can safely call it. using latest header or category on it. On Dec 23, 2013, at 1:49, Seth Willits sli...@araelium.com wrote: On Dec 22, 2013, at 9:31 AM, Trygve Inda cocoa...@xericdesign.com wrote: Available in OS X v10.6 and later. This seems

Re: NSArray firstObject?

2013-12-22 Thread Fritz Anderson
On Dec 22, 2013, at 11:31 AM, Trygve Inda cocoa...@xericdesign.com wrote: [Quotes the documentation that says -[NSArray firstObject] is available since Mac OS 10.6.] This seems to be an error in the docs as the method does not seem to exist for me. I didn't see the method at all in the docs

Re: NSArray firstObject?

2013-12-22 Thread Michael Starke
On 22 Dec 2013, at 19:01, Fritz Anderson fri...@manoverboard.org wrote: On Dec 22, 2013, at 11:46 AM, Michael Starke michael.sta...@hicknhack-software.com wrote: It's been a private API until 10.9 and iOS 7. Clearly a documentation error. That's not what NSArray.h says… -

NSTextTable with only certain text selectabled

2013-12-22 Thread Andrew Arrow
How do I make a drag select on a NSTextView with an NSAttributedString that contains a 2 column NSTextTable, only select the text in the 1st column? You can see a video of the mac app skype doing this here: https://dl.dropboxusercontent.com/u/2510380/skype.mov Thanks!

UISlider with custom images narrow thumb

2013-12-22 Thread John Spicer
I'm trying to get a UISlider working with custom images. I've gone through the docs, and I know how to set the images. The question (and the problem) is a little different. Our design department has given us a thumb image that is wide at the bottom, and narrow at the top (1 pixel). When I use

Mavericks CA Layer Issue

2013-12-22 Thread Banisetty Avinash
Hi All With latest Mac OS 10.9, I am facing an issue with layers. The issue is sublayers(CALayer) are not allowed to expand beyond the bounds of parent layer(CALayer), which is all working fine for rest of the OS Versions. We are using the 10.5 sdks and deployment target as 10.5 for our

NSUserDefault setPersistentDomain:forName: crash issue

2013-12-22 Thread parth r
Hi all, I am getting a crash as below when i am trying to set the dictionary for persistent domain. Attempt to set a non-property-list object as an NSUserDefaults/CFPreferences value abort() calledThread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libsystem_kernel.dylib

Re: iOS screen physical size (or px density)

2013-12-22 Thread Doug Hill
In the ideal world, you would scale your content to work on an arbitrarily sized UIView and not worry about actual screen dimensions/density. From my experience, this pays off most in the long run, especially when new devices come out. This involves designing your app so it doesn't use fixed size

HTML emails from Objective C

2013-12-22 Thread Bryan Schmiedeler
I am trying to write an HTML email using Objective C. I have the HTML all done, now I am just putting it into mutable string line by line. I am using / to escape when I need a quote in the HTML.  This I think will work but sure seems tedious. Is there something I am missing, some library that

DockTile sample code, Principal class is DockTile ?

2013-12-22 Thread Eden
In Apple's DockTile sample code there is a an app and a dock tile plug-in. In the DockTilePlugIn-Info.plist, the Principal class is valued as DockTile, but there is no such class-- the class in the source code is DockTilePlugIn. Isn't that a mistake? But the thing works anyway? The

Re: OS X : Different icon for Status Item

2013-12-22 Thread Simon Maurice
Hi Jerry, there are two methods which are used with NSStatusItem: - (void)setImage: - (void)setAlternateImage: They both do exactly what you think they would. The setImage method just sets the standard image and alternate image is when it's activated. They both take an NSImage See the

Question about adding NSTextView into a zoomed parent view (10.9)

2013-12-22 Thread Tae Won Ha
Hi, guys. I have got a problem with adding NSTextView into a zoomed parent view. I've got the following situation: - A custom NSView in an NSScrollView, let's denote this NSView by viewA. - viewA is zoomed by -scaleUnitSquareToSize: - I create an instance of NSTextView with an NSScrollView (and

iTune Plist changes from NSUserdefaults

2013-12-22 Thread Madhavi Gundeti
Hi, I am developing one MAC application to change iTunes Parental control setting programmatically. I am using NSUserdefaults class to achieve above. Please find the sample code. #define kBundleIdentifier @com.apple.iTunes NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];

Re: HTML emails from Objective C

2013-12-22 Thread Diederik Meijer | Ten Horses
Can you post your code please? Op Nov 26, 2013, om 9:16 PM heeft Bryan Schmiedeler bryanschmiede...@me.com het volgende geschreven: I am trying to write an HTML email using Objective C. I have the HTML all done, now I am just putting it into mutable string line by line. I am using / to

Re: NSArray firstObject?

2013-12-22 Thread Trygve Inda
Yes. This method is there since 10.6 so you can safely call it. using latest header or category on it. On Dec 23, 2013, at 1:49, Seth Willits sli...@araelium.com wrote: On Dec 22, 2013, at 9:31 AM, Trygve Inda cocoa...@xericdesign.com wrote: Available in OS X v10.6 and later. This

Re: HTML emails from Objective C

2013-12-22 Thread Mike Abdullah
On 26 Nov 2013, at 20:16, Bryan Schmiedeler bryanschmiede...@me.com wrote: I am trying to write an HTML email using Objective C. I have the HTML all done, now I am just putting it into mutable string line by line. I am using / to escape when I need a quote in the HTML. This I think

Re: Mavericks CA Layer Issue

2013-12-22 Thread Cody Garvin
Did you make sure masksToBounds is set to NO? Please excuse mobile typos On Nov 22, 2013, at 2:28 AM, Banisetty Avinash baniset...@ivycomptech.com wrote: Hi All With latest Mac OS 10.9, I am facing an issue with layers. The issue is sublayers(CALayer) are not allowed to expand beyond

Re: How to accept drag of a URL on the dock icon?

2013-12-22 Thread Andy Lee
Thanks, Ken. I stumbled onto the solution by way of an old page about how to drag text snippets onto the dock icon in an PyObjC app. Who knows how long I'd have been scratching my head if I hadn't guessed the same approach might work for URLs. For a minute it looked like I could use the same

Re: NSArray firstObject?

2013-12-22 Thread Ken Thomases
On Dec 22, 2013, at 12:57 PM, Trygve Inda wrote: So just declare it in a category and leave it out of the implementation? That of course gives me a warning that my implementation is incomplete. -(id)firstObject; The category should have no implementation (i.e. no @implementation NSArray

Re: Sandboxing: Can't bookmark enclosing folder of user-selected file

2013-12-22 Thread Mike Abdullah
Sounds to me you like you want to read up on the Related Items feature of the sandbox. On 22 Dec 2013, at 09:38, Leo le...@rogers.com wrote: I'm sandboxing an app for the first time. The app has been out for a few years by now, non-sandboxed. The app receives batches of PDF files and

Re: iTune Plist changes from NSUserdefaults

2013-12-22 Thread Jens Alfke
On Dec 11, 2013, at 4:45 AM, Madhavi Gundeti madhavi.gundet...@gmail.com wrote: Please let me know what I am missing here. Why I am not able to change these settings as root user. Because every user has their own defaults. If you use NSUserDefaults in a process whose userid is root, you’re

Re: HTML emails from Objective C

2013-12-22 Thread Jens Alfke
On Nov 26, 2013, at 12:16 PM, Bryan Schmiedeler bryanschmiede...@me.com wrote: I have the HTML all done, now I am just putting it into mutable string line by line. I am using / to escape when I need a quote in the HTML. Are you saying you’re putting the HTML in hardcoded string constants in

Re: Sandboxing: Can't bookmark enclosing folder of user-selected file

2013-12-22 Thread Leo
___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) 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:

Re: HTML emails from Objective C

2013-12-22 Thread Uli Kusterer
On 26 Nov 2013, at 21:16, Bryan Schmiedeler bryanschmiede...@me.com wrote: I am trying to write an HTML email using Objective C. I have the HTML all done, now I am just putting it into mutable string line by line. I am using / to escape when I need a quote in the HTML. This I think will

Re: Mavericks CA Layer Issue

2013-12-22 Thread Appa Rao Mulpuri
Hi Cody, Finally got the Working solution: We Subclassed CALayer and set it to Superview with WantsLayer and override masksToBounds property to return always NO. Question is: not getting why this is Mavericks specific? Is Apple fixed any issue in CALayer specific to this or it is a Bug in