Re: NSTrackingArea message lag

2008-06-26 Thread Graham Cox
Why do you need to use tracking areas? I doubt that they are designed to handle hundreds of small regions. If you are dragging within the view, just hit-detect the rects yourself and mark them as needing update. If you need that to happen with just the mouse passing over the view (button no

Re: Newbie question: error in creating a NSData object using handle (Resource Management)

2008-06-26 Thread Tran Kim Bach
> > > if((type2 =='PREC')&&([resID intValue]== 302)) > There is a typo in the above code line:It should be: if((resType1 =='PREC')&&([resID intValue]== 302)) > Regards, Bachtk ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 26, 2008, at 12:19 AM, Graham Cox wrote: Why do you need to use tracking areas? I doubt that they are designed to handle hundreds of small regions. If you are dragging within the view, just hit-detect the rects yourself and mark them as needing update. If you need that to happen with

Re: NSTrackingArea message lag

2008-06-26 Thread Graham Cox
I'm not saying that's definitely the problem, but to find out for sure you'd need to try both and see how if profiles. Tracking rects are not exactly the same task as testing the rects yourself, because the system has to determine when the mouse actually enters and exits those areas, packag

Re: [NSOutlineView] Saving/Restoring the hierarchy disclosure state (Reloaded)

2008-06-26 Thread Manfred Schwind
I'm beginning to wonder if it's possible to save and restore the current disclosure state of the hierarchy of a NSOutlineView. I solved this a while ago. Here is what I am doing: I am saving in my model if an item is expanded or collapsed. To keep the model up-to-date, I am doing the followi

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 25, 2008, at 11:57 PM, Quincey Morris wrote: These statements are a bit puzzling. What does "redrawing" mean here? Are you talking about what you do inside drawRect:, or what you do to cause drawRect: to be invoked? Are you using setNeedsDisplay: or setNeedsDisplayInRect: to trigger d

Re: Issues with addressbook framework

2008-06-26 Thread Papa-Raboon
Aha, fixed it. Basically if any of you get this same issue with loading a framework the way I got around it was to delete the framework and the #import line in my code. Save my file and then re-import the framework, save, re-add my #import line and all my addressbook elements of my code sprung int

Re: NSTrackingArea message lag

2008-06-26 Thread Quincey Morris
On Jun 26, 2008, at 00:51, Markus Spoettl wrote: On Jun 26, 2008, at 12:19 AM, Graham Cox wrote: Why do you need to use tracking areas? I doubt that they are designed to handle hundreds of small regions. If you are dragging within the view, just hit-detect the rects yourself and mark them

NSWindow setIgnoresMouseEvents and Spaces

2008-06-26 Thread Stefano Pigozzi
Hello, I'm modding Apple's RoundTransparentWindow sample in order to draw a gradient overlay on all the screen (to fix the non uniform lighting on my iMac's screen). The applicazion works quite nicely but when I'm switching to another space using the 3d effect method my application doesn'

Re: NSWindow setIgnoresMouseEvents and Spaces

2008-06-26 Thread Jean-Daniel Dupas
Le 26 juin 08 à 11:26, Stefano Pigozzi a écrit : Hello, I'm modding Apple's RoundTransparentWindow sample in order to draw a gradient overlay on all the screen (to fix the non uniform lighting on my iMac's screen). The applicazion works quite nicely but when I'm switching to another sp

Re: NSWindow setIgnoresMouseEvents and Spaces

2008-06-26 Thread Stefano Pigozzi
Il giorno 26/giu/08, alle ore 11:56, Jean-Daniel Dupas ha scritto: Le 26 juin 08 à 11:26, Stefano Pigozzi a écrit : Hello, I'm modding Apple's RoundTransparentWindow sample in order to draw a gradient overlay on all the screen (to fix the non uniform lighting on my iMac's screen). The

Can/should UIViewController work with multiple views?

2008-06-26 Thread Aleksandar Vacić
I'm new to Cocoa and try to learn what are the good ways of developing. One thing I'm doubtful is this... In the iPhone Simulator, when you load Photos app, it's initially empty and displays an image + helpful message. In the app I'm buiding I want to do the same thing - if there is nothin

creating 2D graphs

2008-06-26 Thread ªtîf ÇhåµÐh®¥
Hello, I want to include a graph in my iPhone application. How should I create and display one similar to that shown in 'Stocks' application of iPhone. Is there some API available or will I need to draw those things by using openGL or Quartz? Thanx, ªtîƒ ÇhåµÐh(R)¥ __

Re: Can/should UIViewController work with multiple views?

2008-06-26 Thread Hamish Allan
On Thu, Jun 26, 2008 at 11:44 AM, Aleksandar Vacić <[EMAIL PROTECTED]> wrote: >In the iPhone Simulator, when you load Photos app, iPhone simulator? I have heard tell of such a thing... but Photos app? I'd imagine anyone with direct experience of anything like that would be under NDA and t

[MEET] CocoaHeads Aachen Tonight

2008-06-26 Thread Stefan Hafeneger
Hi, Today is CocoaHeads Aachen meeting. Talks: - Werner Lonsing, "CoreImage: Digital Arts for Cocoa Developer" - Jonathan Diehl, "iPhone and SQLight" Afterwards we will do public viewing Soccer EM 2008 semifinal Russia vs. Spain. For more information please visit our website www.cocoaheads.

Re: NSTrackingArea message lag

2008-06-26 Thread Graham Cox
On 26 Jun 2008, at 6:33 pm, Markus Spoettl wrote: Redrawing means setting needsDisplay. I'm using if (![self needsDisplay]) { [self setNeedsDisplayInRect:rect]; } I found the needsDisplay check to speed it up a little. rect is the tracking area. And does that work? I think this is y

Tiff Properties

2008-06-26 Thread Arvind Nayak
Greetings, I am working on multipage tiff file. I am writing raw data to NSBitmapImageRep. Then getting the TIFFRepresentations to write to a tiff file. When I open the file in preview I could see "TIFF Properties" in the get info pane. I would like to set custom properties to describe the im

Re: creating 2D graphs

2008-06-26 Thread Mike Abdullah
The iPhone SDK is under NDA; you cannot discuss it here On 26 Jun 2008, at 11:56, ªtîf ÇhåµÐh®¥ wrote: Hello, I want to include a graph in my iPhone application. How should I create and display one similar to that shown in 'Stocks' application of iPhone. Is there some API available or will I

Re: [MODERATOR] Re: sphere in openGL ES ++IRC

2008-06-26 Thread Paul Sargent
On Wed, Jun 25, 2008 at 11:20 PM, Scott Anguish <[EMAIL PROTECTED]> wrote: > > On Jun 25, 2008, at 4:47 PM, Simon Fleming wrote: > >> Dear All, >> >> >> >> Can anyone help me create a sphere in openGL ES for the iphone? >> >> > > NO they can't. The iPhone SDK is covered by a non-disclosure agreeme

Re: NSPredicateEditor

2008-06-26 Thread Kyle Sluder
On Wed, Jun 25, 2008 at 4:12 PM, Peter Ammon <[EMAIL PROTECTED]> wrote: > If the holds down the option key and clicks a + button, it will insert > another compound row, so the user can make arbitrarily complex predicates. Well this is incredibly "undiscoverable UI". Bug report time! --Kyle Slude

__CGEvent structure

2008-06-26 Thread Stefan Hafeneger
Hi, I would like to know how the __CGEvent (CGEventRef) struct is defined, so if there is any possibility to attach some more data to an low level event than through the functions defined CGEvent.h. Any ideas? With best wishes, Stefan smime.p7s Description: S/MIME cryptographic signature _

Re: NSWindow setIgnoresMouseEvents and Spaces

2008-06-26 Thread Gregory Weston
On Jun 26, 2008, at 6:44 AM, [EMAIL PROTECTED] wrote: This NSWindow contains only and NSView where I draw the gradient mentioned before. Anyone can suggest a workaround to make this work? You can try with an higher window level. [result setLevel:CGWindowLevelForKey(kCGOverlayWindowLevelKey)

Re: Adding a new type of NSButton

2008-06-26 Thread I. Savant
> I think (or at least I hope) Kevin misspoke and meant View rather than > Model, since that would make more sense if you're talking about subclassing > NSButton. You may be right about that ... but I answer what I see. ;-) > I think "application-specific" is a little too strong. No one's prop

Re: Adding a new type of NSButton

2008-06-26 Thread I. Savant
> Still, the controller and (more-so) the model layers are > more application-specific. Sorry, a correction - that's backwards. The controller layer tends to be more application-specific (less-reusable) than the model layer. I'm still drinking my morning coffee. ;-) -- I.S.

Re: __CGEvent structure

2008-06-26 Thread Jean-Daniel Dupas
Le 26 juin 08 à 14:53, Stefan Hafeneger a écrit : Hi, I would like to know how the __CGEvent (CGEventRef) struct is defined, so if there is any possibility to attach some more data to an low level event than through the functions defined CGEvent.h. Any ideas? With best wishes, Stefan

Re: creating 2D graphs

2008-06-26 Thread Dave DeLong
While the iPhone is under NDA, there are a couple frameworks out there for graphing. Check out http://cocoaheads.byu.edu, where we've been collecting all the links we can find. Search for "graph" to see what we've found. HTH, Dave Sent from my iPod On Jun 26, 2008, at 4:56 AM, "ªtîf Ç

Re: Is it possible for several NSURLConnection instances to share one delegate?

2008-06-26 Thread an0
Thank you all. I am going to try what I've learnt from this thread:) On Thu, Jun 26, 2008 at 12:01 AM, I. Savant <[EMAIL PROTECTED]> wrote: >> Just to mention, the natural approach would be a dictionary whose >> keys are connection objects with a value being a request, or maybe >> another dictiona

Re: Prevent Asynchronous operation of beginSheetModalForWindow

2008-06-26 Thread John Love
Graham, Still pouring over your thesis .. in process, so let me ask just one thing at a time, rather than chew here on the whole thing. (1) learning about anonymous type = (id) .. I make this call within FC: [iboCalculateSheetCtrl showSheetOnParentWindow:itsWindow

Re: Adding a new type of NSButton

2008-06-26 Thread Andy Lee
On Jun 26, 2008, at 9:29 AM, I. Savant wrote: I'm envisioning a scenario where, even if there are a dozen such buttons, they probably all connect to an action in the same controller I agree in the hundred-buttons/one-action case it's clearly the path of least resistance to add a line or two

Re: Adding a new type of NSButton

2008-06-26 Thread I. Savant
> (By the way, I'm glad Hamish mentioned those buttons on web pages that dim > when you click them so you won't click them again. Other than that, the > only example I could think of for this kind of one-way button was a > bubble-wrap game where every bubble is implemented as a button.) Bubble-

[MODERATOR] Re: Can/should UIViewController work with multiple views?

2008-06-26 Thread Scott Anguish
On Jun 26, 2008, at 6:44 AM, Aleksandar Vacić wrote: I'm new to Cocoa and try to learn what are the good ways of developing. One thing I'm doubtful is this... In the iPhone Simulator, when you load Photos app, it's initially empty and displays an image + helpful message. In the app I'm

[Moderator] List Guidelines - Must Read

2008-06-26 Thread Scott Anguish
Discussing NDA Projects (Snow Leopard and iPhone OS) and Private API This list is not an appropriate forum for the discussion of issues that are covered by non-disclosure. This includes Snow Leopard and iPhone OS 2.0. Doing

Re: Adding a new type of NSButton

2008-06-26 Thread Kevin Elliott
On Jun 26, 2008, at 6:29 AM, I. Savant wrote: Sure - if you're using a button in this way in many apps or across many controllers, there'd be an advantage (I suppose) of reducing it to one line (to set the "disables when on" mode), but not much, I'd argue. Again, this assumes no subclassing is

Re: Prevent Asynchronous operation of beginSheetModalForWindow

2008-06-26 Thread Nathan Kinsinger
On Jun 26, 2008, at 8:19 AM, John Love wrote: @implementation CalculateSheetController id *mFileSheetDelegate; id is already typed as a pointer, no need to add another level of indirection here. --Nathan ___ Cocoa-dev mailing list (Cocoa-dev@

Re: Adding a new type of NSButton

2008-06-26 Thread I. Savant
> Even if his scenario matches your description, is a big switch statement > really a good solution? Your suggesting that he throw away the whole point > of the IBAction methodology (sending events to the actual method that is > going to process them) for what advantage? What's he's describing IS

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 26, 2008, at 4:15 AM, Graham Cox wrote: I think this is your problem. After the first rect is marked as needing update, the needsDisplay method will return YES. That then rejects all subsequent rect marking until the next event loop and the view has been redrawn. Then another rect get

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 26, 2008, at 2:01 AM, Quincey Morris wrote: Tracking rectangles were perhaps mostly used for dealing with cursors. Tracking areas (NSTrackingArea) are useful for more things. The NSWindow documentation used to (and I suppose still does) discourages use of setAcceptMouseMovedEvents. Th

NSSpeechSynthesizer and empty strings

2008-06-26 Thread David Brennan
Hi, I have a cocoa app that is using NSSpeechSynthesizer to speak the contains of a NSString to a file. My problem is when it is passed an empty string, - (BOOL)isSpeaking returns true. So I don't know when it is finished. If NSSpeechSynthesizer has nothing to say, I want to create an audio file

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread I. Savant
> If NSSpeechSynthesizer has nothing to say, I want to create an audio > file with 1 second of silence. Maybe I'm misunderstanding the problem, but how about ... if ([myString isEqualToString:@""]) { // Record silence into file ... } else { // Send string to speech synthesizer }

Good mouse tracking design for dynamic view?

2008-06-26 Thread Nathan Vander Wilt
I have a view that displays and allows interaction with a lot (hundreds, even thousands) of small items. I am having trouble nailing down a good design for event handling, and just as I was ready to plead for help I see some other NSTrackingArea discussion that perhaps sheds a little light,

Re: [NSOutlineView] Saving/Restoring the hierarchy disclosure state (Reloaded)

2008-06-26 Thread Jonathan Dann
Here's what I do: @"isExpanded" is a persistent attribute of my model objects. In the delegate - (void)outlineViewItemDidExpand:(NSNotification *)notification; { notification userInfo] valueForKey:@"NSObject"] representedObject] setValue:[NSNumber numberWithBool:YES] forKey:@"isExpande

Re: [Moderator] List Guidelines - Must Read

2008-06-26 Thread Hamish Allan
On Thu, Jun 26, 2008 at 4:51 PM, Scott Anguish <[EMAIL PROTECTED]> wrote: > Discussing NDA Projects (Snow Leopard and iPhone OS) and Private API > > > This list is not an appropriate forum for the discussion of issues that are >

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread David Brennan
Hi, I have just come up with solution. I add a silence to the start of the string. Therefore NSSpeechSynthesizer will always have something to say. NSString *tempString = @"[[inpt PHON]]%[[inpt TEXT]]"; tempString = [tempString stringByAppendingString:[inputText string]]; Regards

Re: PDFKit guidance

2008-06-26 Thread Torsten Curdt
OK, guys thanks for the help so far. I've played a bit. The subclassing of PDFDocument and PDFPage was quite straight forward. (Although unexpected as usually everyone tells you "usually you don't subclass in Cocoa land") Just out of curiosity I've just compiled it with the 10.4 SDK and it

Re: Good mouse tracking design for dynamic view?

2008-06-26 Thread Douglas Davidson
On Jun 26, 2008, at 11:20 AM, Nathan Vander Wilt wrote: So it seems I need to do more bookwork myself, but I'm wondering which direction others would recommend: a) Set up a single tracking area for the whole view, and perform all my own hit testing every time the mouse moves. b) Keep the per

Re: PDFKit guidance

2008-06-26 Thread Douglas Davidson
On Jun 26, 2008, at 11:54 AM, Torsten Curdt wrote: The subclassing of PDFDocument and PDFPage was quite straight forward. (Although unexpected as usually everyone tells you "usually you don't subclass in Cocoa land") I think what we usually say is: don't make subclassing your first reso

Outline View and Bindings

2008-06-26 Thread Gabriel Shahbazian
I have some bindings set up that work perfect well with a Table View (3 column) but when I try and use the Outline View it fails to display the data. Is there something different you need to do with the bindings or does it simply not work with Outline View? Thanks __

NSSpeechSynthesizer and a speech dictionary

2008-06-26 Thread David Brennan
Hi How do I create a speech dictionary for NSSpeechSynthesizer. I would like to be able to save the speech dictionary to file, and then load it into my NSSpeechSynthesizer object using - (void)addSpeechDictionary:(NSDictionary *)speechDictionary. Kind regards, Dave. __

Re: Good mouse tracking design for dynamic view?

2008-06-26 Thread Greg Titus
On Jun 26, 2008, at 11:56 AM, Douglas Davidson wrote: On Jun 26, 2008, at 11:20 AM, Nathan Vander Wilt wrote: So it seems I need to do more bookwork myself, but I'm wondering which direction others would recommend: a) Set up a single tracking area for the whole view, and perform all my ow

Re: Good mouse tracking design for dynamic view?

2008-06-26 Thread Quincey Morris
On Jun 26, 2008, at 11:20, Nathan Vander Wilt wrote: Even though it seems like I'd be reimplementing something Cocoa already offers, I'm leaning towards option A: I'm not sure if I'll be able to foresee all the edge cases, and I'd be reinventing half the hit testing code there anyway. Does

Re: Outline View and Bindings

2008-06-26 Thread Quincey Morris
On Jun 26, 2008, at 12:03, Gabriel Shahbazian wrote: I have some bindings set up that work perfect well with a Table View (3 column) but when I try and use the Outline View it fails to display the data. Is there something different you need to do with the bindings or does it simply not wor

NSTextFieldCell subclass template image inversion

2008-06-26 Thread [EMAIL PROTECTED]
Hello list My NSTextFieldCell subclass is based on ImageAndTextCell.m from the SourceView sample. This displays text and images in a single cell. My difficult is in getting system media template images to invert when the cell is highlighted. The documentation for NSImage - setTemplate stat

Re: Newbie question: error in creating a NSData object using handle (Resource Management)

2008-06-26 Thread Ken Thomases
On Jun 25, 2008, at 9:49 PM, Tran Kim Bach wrote: On Wed, Jun 25, 2008 at 3:36 PM, Ken Thomases <[EMAIL PROTECTED]> wrote Also, in the pseudo-code you provide, the NSData objects will accumulate in the autorelease pool until some point after your "for" loop. You can try using an autorel

Re: Good mouse tracking design for dynamic view?

2008-06-26 Thread Michael Ash
On Thu, Jun 26, 2008 at 2:20 PM, Nathan Vander Wilt <[EMAIL PROTECTED]> wrote: > I have a view that displays and allows interaction with a lot (hundreds, > even thousands) of small items. I am having trouble nailing down a good > design for event handling, and just as I was ready to plead for help

Re: NSTextFieldCell subclass template image inversion

2008-06-26 Thread Quincey Morris
On Jun 26, 2008, at 13:18, [EMAIL PROTECTED] wrote: My difficult is in getting system media template images to invert when the cell is highlighted. The documentation for NSImage - setTemplate states: You can mark an image as a “template image” to notify clients who care that the image cont

Re: [NSOutlineView] Saving/Restoring the hierarchy disclosure state (Reloaded)

2008-06-26 Thread Stéphane Sudre
On Jun 26, 2008, at 10:30 AM, Manfred Schwind wrote: I'm beginning to wonder if it's possible to save and restore the current disclosure state of the hierarchy of a NSOutlineView. I solved this a while ago. Here is what I am doing: I am saving in my model if an item is expanded or collapse

Re: Leak in NSSavePanel

2008-06-26 Thread Jelle Vandebeeck
Hi Corbin, You should check out this link: http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Classes/NSSavePanel_Class/Reference/Reference.html The word singleton is used :-) But I thought [NSSavePanel savePanel] returned an autoreleased object, so I presumed no leaks c

Re: Leak in NSSavePanel

2008-06-26 Thread Andy Lee
On Jun 26, 2008, at 6:23 PM, Jelle Vandebeeck wrote: You should check out this link: http://developer.apple.com/documentation/Cocoa/Reference/ApplicationKit/Classes/NSSavePanel_Class/Reference/Reference.html The word singleton is used :-) As a full-text search in the Xcode doc window would ha

Re: How to get a message when RETURN is pressed in a NSTextField

2008-06-26 Thread Patrick Burleson
On Tue, Jun 24, 2008 at 1:41 AM, Markus Spoettl <[EMAIL PROTECTED]> wrote: > Hi Kenny, > > Thanks for your suggestion. Unfortunately that doesn't work because I cannot > differentiate between the multiple possibilities of what makes the action > fire. The NSTextField action is sent not only for pre

NSArchiver question?

2008-06-26 Thread Damien Cooke
I am getting the following error from this line NSData *data = [NSArchiver archivedDataWithRootObject:viewItem]; -[DCOViewItem encodeWithCoder:]: unrecognized selector sent to instance 0x17fa00 do I need to override this method below for my class DCOViewItem to use the NSArchiver class? (v

Re: NSArchiver question?

2008-06-26 Thread Mike Abdullah
Yes, it is your responsibility to implement the NSCoding protocol in your own classes. On 27 Jun 2008, at 00:09, Damien Cooke wrote: I am getting the following error from this line NSData *data = [NSArchiver archivedDataWithRootObject:viewItem]; -[DCOViewItem encodeWithCoder:]: unrecognized

description and proxy objects

2008-06-26 Thread Torsten Curdt
I am getting the selected object from a controller (that is using bindings) NSDictionary *accountSettings = [accountsController selection]; The returned object is a proxy object. But why isn't the [accountSettings description] passed on? Instead of the print out of the contents of the dicti

NSTableView / NSArrayController Drawing

2008-06-26 Thread Murray Bookchin
Hi All, I'm using an NSArrayController to populate my NSTableView from an array of dictionaries. The problem is my app spends the majority of its cpu time re-drawing the NSTableview (~60-70%) as I add rows, even though the view is "idle" (displaying the top 20 or so rows which aren't changing). I

noob questions regarding KVC accessors for a mutable array property

2008-06-26 Thread Stuart Malin
I am trying to gain a working understanding of KVC. I have made a small app that has a class Party which has a property "attendees" that holds Person objects. The attendees property is KVC compliant for a mutable array (it has index accessors). In another part of my app, I want to find the

Re: NSArchiver question?

2008-06-26 Thread Jonathan Hess
Hey Damien - You should also consider using NSKeyedArchiver over NSArchiver. NSKeyedArchiver is much more flexible and handles archive versioning much better. Jon Hess On Jun 26, 2008, at 4:22 PM, Mike Abdullah wrote: Yes, it is your responsibility to implement the NSCoding protocol in

Re: NSPredicateEditor

2008-06-26 Thread Peter Ammon
On Jun 25, 2008, at 7:27 PM, Chris wrote: The net effect is that NSPredicateEditor can't display a predicate like NOT (foo = "bar") A bug in NSPredicateEditor system perhaps? But surely someone would have seen it before. Hi Chris, NOT type compound predicates only support exactly on

Re: [Moderator] List Guidelines - Must Read

2008-06-26 Thread Scott Ribe
> What we really need is for the cocoa-dev list admin page to require > new subscribers to type in the phrase "I will not make posts about the > iPhone or Snow Leopard" :) You know, I think that's a good idea. Either there, or where downloading the iPhone SDK, rather than just click to acknowledge

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread William Squires
Actually, "if ([myString length] == 0)" is probably better, but just IMHO... :) On Jun 26, 2008, at 1:15 PM, I. Savant wrote: If NSSpeechSynthesizer has nothing to say, I want to create an audio file with 1 second of silence. Maybe I'm misunderstanding the problem, but how about ... if

Re: NSTrackingArea message lag

2008-06-26 Thread Graham Cox
On 27 Jun 2008, at 3:42 am, Markus Spoettl wrote: On Jun 26, 2008, at 4:15 AM, Graham Cox wrote: I think this is your problem. After the first rect is marked as needing update, the needsDisplay method will return YES. That then rejects all subsequent rect marking until the next event loop a

Re: description and proxy objects

2008-06-26 Thread Omar Qazi
On Jun 26, 2008, at 4:36 PM, Torsten Curdt wrote: I am getting the selected object from a controller (that is using bindings) NSDictionary *accountSettings = [accountsController selection]; The returned object is a proxy object. But why isn't the [accountSettings description] passed on? I

Re: NSArchiver question?

2008-06-26 Thread Omar Qazi
On Jun 26, 2008, at 4:09 PM, Damien Cooke wrote: do I need to override this method below for my class DCOViewItem to use the NSArchiver class? (void)encodeWithCoder:(NSCoder *)encoder Yes. Not only that but you also need to implement decodeWithCoder: For information on how to do that, i r

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread Nick Zitzmann
On Jun 26, 2008, at 6:16 PM, William Squires wrote: Actually, "if ([myString length] == 0)" is probably better, but just IMHO... :) No; don't ever do that. It is possible for an NSString to have zero length but not be empty. See

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread Omar Qazi
On Jun 26, 2008, at 5:32 PM, Nick Zitzmann wrote: It is possible for an NSString to have zero length but not be empty. Huh. Didn't know that. I must have done that at least a million times just today. *Opens Xcode* Omar Qazi Hello, Galaxy! 1.310.294.1593 smime.p7s Description: S/M

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 26, 2008, at 5:21 PM, Graham Cox wrote: you can still (and should) use -setNeedsDisplayInRect:, just don't make this conditional on -needsDisplay. I think to really get to the bottom of the delay problem we'd need to see the code in its full context. For example how does your drawRe

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread I. Savant
Actually, "if ([myString length] == 0)" is probably better, but just IMHO... :) for details. Nick beat me to it! ;-) I must say I've been slow on the draw (and largely uncommunicative) lately - a major deadline came a

NSPopUpButton setPreferredEdge

2008-06-26 Thread Francisco Tolmasky
I'm attempting to make a pop up button that pops its menu to the left of itself. However, setting setPullsDown:YES and setPreferredEdge:NSMinXEdge does not appear to work. In fact, setPreferredEdge seems to be largely ignored, whether I set it in code or even quickly testing it in IB. Am

Re: description and proxy objects

2008-06-26 Thread Kyle Sluder
On Thu, Jun 26, 2008 at 7:36 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: > I am getting the selected object from a controller (that is using bindings) > > NSDictionary *accountSettings = [accountsController selection]; > > The returned object is a proxy object. But why isn't the [accountSettings

Re: NSTrackingArea message lag

2008-06-26 Thread Kyle Sluder
On Thu, Jun 26, 2008 at 8:41 PM, Markus Spoettl <[EMAIL PROTECTED]> wrote: > Notice the drawing mechanism didn't change, so the drawing wasn't causing > the lag. I have no other explanation than a strange delay in the delivery of > tracking area messages. What causes the delay I don't know, it's ve

Re: NSTextFieldCell subclass template image inversion

2008-06-26 Thread Brandon Walkin
You can make a template image white by telling its cell: [cell setBackgroundStyle:NSBackgroundStyleDark] Cheers, Brandon On 26-Jun-08, at 4:18 PM, [EMAIL PROTECTED] wrote: Hello list My NSTextFieldCell subclass is based on ImageAndTextCell.m from the SourceView sample. This displays text

Re: Prevent Asynchronous operation of beginSheetModalForWindow

2008-06-26 Thread Graham Cox
On 27 Jun 2008, at 12:19 am, John Love wrote: Still pouring over your thesis I thought it was getting a bit damp around here... ;-) and at the very top: @implementation CalculateSheetController id *mFileSheetDelegate; Within the implementation of showSheetOnParentWindow, I get "assignm

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread James Walker
Nick Zitzmann wrote: It is possible for an NSString to have zero length but not be empty. See for details. The message you quote says that it is possible for an NSString to be empty (in a semantic sense) but have positive l

Re: NSPredicateEditor

2008-06-26 Thread Chris
On Fri, Jun 27, 2008 at 10:09 AM, Peter Ammon <[EMAIL PROTECTED]> wrote: > > On Jun 25, 2008, at 7:27 PM, Chris wrote: > >> >> The net effect is that NSPredicateEditor can't display a predicate like >> >> NOT (foo = "bar") >> >> >> A bug in NSPredicateEditor system perhaps? But surely someone woul

Re: [Moderator] List Guidelines - Must Read

2008-06-26 Thread mmalc Crawford
On Jun 26, 2008, at 11:36 AM, Hamish Allan wrote: Making these general posts repeatedly seems to me to be pretty futile. Those who post iPhone questions here are presumably those who have signed up five minutes beforehand for the purpose. The fact that they post without reading the FAQ or perfo

Re: NSPopUpButton setPreferredEdge

2008-06-26 Thread Peter Ammon
On Jun 26, 2008, at 5:49 PM, Francisco Tolmasky wrote: I'm attempting to make a pop up button that pops its menu to the left of itself. However, setting setPullsDown:YES and setPreferredEdge:NSMinXEdge does not appear to work. In fact, setPreferredEdge seems to be largely ignored, whethe

Re: Newbie question: error in creating a NSData object using handle (Resource Management)

2008-06-26 Thread Tran Kim Bach
Wow, thanks Ken a lot.About the endian issues, I have a compatible swap function to convert data to Big-endian (and vice verse). Then, I will correct big-endian issues. I may know where the problem is. When I read to your suggestion, On Fri, Jun 27, 2008 at 6:11 AM, Ken Thomases <[EMAIL PROTECTED]

Re: Newbie question: error in creating a NSData object using handle (Resource Management)

2008-06-26 Thread Graham Cox
Just an aside that may or may not be relevant. In the old days, often variable-length resources and other OS types would have a struct defined for them that used a fixed field size to represent some variable length field in the real resource, for example: typedef struct { short count;

Re: NSSpeechSynthesizer and empty strings

2008-06-26 Thread Michael Ash
On Thu, Jun 26, 2008 at 8:32 PM, Nick Zitzmann <[EMAIL PROTECTED]> wrote: > > On Jun 26, 2008, at 6:16 PM, William Squires wrote: > >> Actually, "if ([myString length] == 0)" is probably better, but just >> IMHO... :) > > > No; don't ever do that. It is possible for an NSString to have zero length

Re: NSTrackingArea message lag

2008-06-26 Thread Markus Spoettl
On Jun 26, 2008, at 6:11 PM, Kyle Sluder wrote: Well you've avoided the problem, but you should still remove the condition on -needsDisplay. It's semantically incorrect. I did that (I thought I mentioned that). Regards Markus -- __ Markus Spoettl sm

subclassing CAAnimation

2008-06-26 Thread Matthew Johnson
I would like to subclass CAAnimation to implement an animation with custom rendering. I can't find any details about how animations work with the render tree to render each frame. There doesn't appear to be public API for this yet. This is an experimental project so I don't mind using un

Re: NSTableView / NSArrayController Drawing

2008-06-26 Thread Ken Thomases
On Jun 26, 2008, at 6:43 PM, Murray Bookchin wrote: I'm using an NSArrayController to populate my NSTableView from an array of dictionaries. The problem is my app spends the majority of its cpu time re-drawing the NSTableview (~60-70%) as I add rows, even though the view is "idle" (display

Re: noob questions regarding KVC accessors for a mutable array property

2008-06-26 Thread Ken Thomases
On Jun 26, 2008, at 6:54 PM, Stuart Malin wrote: I am trying to gain a working understanding of KVC. I have made a small app that has a class Party which has a property "attendees" that holds Person objects. The attendees property is KVC compliant for a mutable array (it has index accessors

Re: noob questions regarding KVC accessors for a mutable array property

2008-06-26 Thread Scott Anguish
the better way is to implement the indexed accessors described in the KVC doc. in fact I know at least one engineer would would like the doc to specifically say that you should NOT have an accessor that returns an array like this. On Jun 26, 2008, at 7:54 PM, Stuart Malin wrote: Separat

Re: subclassing CAAnimation

2008-06-26 Thread Scott Anguish
On Jun 26, 2008, at 11:49 PM, Matthew Johnson wrote: I would like to subclass CAAnimation to implement an animation with custom rendering. I can't find any details about how animations work with the render tree to render each frame. There doesn't appear to be public API for this yet. Th

Re: description and proxy objects

2008-06-26 Thread Ken Thomases
On Jun 26, 2008, at 8:05 PM, Kyle Sluder wrote: On Thu, Jun 26, 2008 at 7:36 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: I am getting the selected object from a controller (that is using bindings) NSDictionary *accountSettings = [accountsController selection]; The returned object is a pro

Re: [Moderator] List Guidelines - Must Read

2008-06-26 Thread Jens Alfke
On 26 Jun '08, at 11:36 AM, Hamish Allan wrote: What we really need is for the cocoa-dev list admin page to require new subscribers to type in the phrase "I will not make posts about the iPhone or Snow Leopard" :) No, you've bought into the whole reality distortion field. What we _really_ n

Re: [Moderator] List Guidelines - Must Read

2008-06-26 Thread Omar Qazi
On Jun 26, 2008, at 11:01 PM, Jens Alfke wrote: No, you've bought into the whole reality distortion field. What we _really_ need is for Apple to allow developer discussion of NDA'ed products. If there were an *Ph*n* mailing list on this server, and if that list were mentioned in the SDK or

What does 'thread safe' mean?

2008-06-26 Thread Kevin Ferguson
Greetings, I am not entirely sure as to what exactly a thread is, but seeing as anything I've ever programmed is light weight, I've never needed to worry before. And to be honest, such is still the case. This question is merely to satisfy my personal curiosity on the topic, and I can't se