Re: TextField not updated in a sheet for document-based Cocoa app

2012-06-12 Thread Gilles Celli
Graham, Thanks for your fast response. I'll look at this ASAP, and will let you know how it goes :-) Cheers, Gilles On Jun 12, 2012, at 2:27 AM, Graham Cox wrote: > > On 12/06/2012, at 12:29 AM, Gilles Celli wrote: > >> the sheet is properly displayed (with its TextField and button) for the

NSSavePanel default file type

2012-06-12 Thread Kurt Sutter
Hi list Our app allows to export its documents in a variety of formats, such as jpeg, tiff, png, pdf . Hence, we have set up the NSSavePanel to sport a file types popup that allows the user to select the desired file type. Now we want that save panel to remember the format of the last export op

Re: Crash(?) Questions

2012-06-12 Thread koko
Yes, I was using beginSheetModalForWindow: completionHandler So I have changed to: [NSApp beginSheet:op modalForWindow:[self window] modalDelegate:self didEndSelector:@selector(sheetDidEnd:returnCode:contextInfo:) contextInfo:nil]; - (void)sheetDidEnd:(NSWindow *)sheet returnCode:(NSInteger)

Re: Crash(?) Questions

2012-06-12 Thread Mike Abdullah
On 12 Jun 2012, at 11:00, koko wrote: > Yes, I was using beginSheetModalForWindow: completionHandler > > So I have changed to: > > [NSApp beginSheet:op modalForWindow:[self window] modalDelegate:self > didEndSelector:@selector(sheetDidEnd:returnCode:contextInfo:) > contextInfo:nil]; > > -

Re: Crash(?) Questions

2012-06-12 Thread koko
op is an NSOpenPanel [self window] is an NSWindow owned by a NSWindowController subclass -koko On Jun 12, 2012, at 12:20 PM, Mike Abdullah wrote: > > On 12 Jun 2012, at 11:00, koko wrote: > >> Yes, I was using beginSheetModalForWindow: completionHandler >> >> So I have changed to: >> >>

String Encoding

2012-06-12 Thread koko
I have international users who may have things like umlaut in file names / paths which I may get as CStrings given our Model. What NS string encoding should be used to preserve the umlaut and not crash? Is NSUTF8 OK? -koko ___ Cocoa-dev mailing l

Re: String Encoding

2012-06-12 Thread Wim Lewis
On 12 Jun 2012, at 12:42 PM, koko wrote: > I have international users who may have things like umlaut in file names / > paths which I may get as CStrings given our Model. > > What NS string encoding should be used to preserve the umlaut and not crash? > Is NSUTF8 OK? UTF-8 can represent any U

CLANG linker returning "illegal text-relocation to..." for x64

2012-06-12 Thread Vojtěch Meluzín
Hi, I just moved to Lion and its new XCode 4. I'm calling the compiler directly, so no XCode processing. I basically cloned the way XCode uses the compiler. For x86 everything works just fine, in fact CLANG seems to have the same options as GCC used before. But with x64 it ends up with weird linki

Re: String Encoding

2012-06-12 Thread Aki Inoue
When dealing with the file system pathnames, you should use the file system representation methods from NSString/NSFileManager. Specifically, -[NSFileManager fileSystemRepresentationWithPath:] and -[NSFileManager stringWithFileSystemRepresentation:]. Aki On 2012/06/12, at 12:42, koko wrote:

Re: String Encoding

2012-06-12 Thread Stephane Sudre
Do you have examples in mind where the result of - [NSFileManager fileSystemRepresentationWithPath] differs from the one of - [NSString UTF8String]? On Tue, Jun 12, 2012 at 1:40 PM, Aki Inoue wrote: > When dealing with the file system pathnames, you should use the file system > representation me

Re: NSSavePanel default file type

2012-06-12 Thread Martin Wierschin
> Our app allows to export its documents in a variety of formats, such as jpeg, > tiff, png, pdf . Hence, we have set up the NSSavePanel to sport a file types > popup that allows the user to select the desired file type. ... > So, how can I set the item in the popup that is initially selected whe

Re: String Encoding

2012-06-12 Thread koko
OK. NSUTF8 it is. I just sent a beta to Norway so I'll know more in the next 24 hours. -koko On Jun 12, 2012, at 3:13 PM, Stephane Sudre wrote: > Do you have examples in mind where the result of - [NSFileManager > fileSystemRepresentationWithPath] differs from the one of - [NSString > UTF8St

Re: String Encoding

2012-06-12 Thread Aki Inoue
All the accented chars, for example, are represented differently. Aki Inoue On 2012/06/12, at 14:43, koko wrote: > OK. NSUTF8 it is. I just sent a beta to Norway so I'll know more in the > next 24 hours. > > -koko > > > On Jun 12, 2012, at 3:13 PM, Stephane Sudre wrote: > >> Do you hav

Re: Crash(?) Questions

2012-06-12 Thread Graham Cox
On 13/06/2012, at 4:34 AM, koko wrote: > op is an NSOpenPanel that class has its own -beginSheetModal... method - you should use that. --Graham ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator co

Re: NSSavePanel default file type

2012-06-12 Thread Kurt Sutter
I could, if there were an official api to get that NSPopUpButton. Is there? I did not find one. Kurt On 12. Jun 2012, at 23:15, Martin Wierschin wrote: >> Our app allows to export its documents in a variety of formats, such as >> jpeg, tiff, png, pdf . Hence, we have set up the NSSavePanel to

Re: NSSavePanel default file type

2012-06-12 Thread Todd Freese
Are you using a pre-built export dialog or a standard save dialog with a custom accessory view? Sounds like you need to use a custom accessory view, although this would most likely require you to code all the export features. Todd On Jun 12, 2012, at 10:11 PM, Kurt Sutter wrote: > I could, if

Cocoaheads Lake Forest meets tomorrow (Wednesday) night - continuing a reading group on Matt Neuburg's Programming iOS 5, 2nd edition

2012-06-12 Thread Scott Ellsworth
CocoaHeads Lake Forest will be meeting on the second Wednesday of the month. We will be meeting at the Orange County Public Library (El Toro) community room, 24672 Raymond Way, Lake Forest, CA 92630 Please join us from 7pm to 9pm on Wednesday, 6/13. Matt Neuburg's Programming iOS 5, second editi

NSImageView display problem

2012-06-12 Thread Abhijeet Singh
Hi,In my application I am displaying an image received from some third party camera library function in NSImageView on screen. On "Capture" button click the image is first saved on hard disk and then I display that image on screen. It works fine during the first time when I start my application.