Re: Help on Menu Item

2008-07-23 Thread Jens Alfke
On 23 Jul '08, at 10:19 PM, Adil Saleem wrote: Hi,Is it possible to make a program that appears as a menu item for all applications ? Actually i want to make a custom action which i want to appear in every application's menu (just like About, Quit etc...) or it can just appear in the Apple

Re: Is checking -count worth it?

2008-07-23 Thread Jens Alfke
On 23 Jul '08, at 9:15 PM, Steve Cronin wrote: Is this code worth it? if ([M count]>0) [M removeObject:O]; OR should I just do [M remove O]; No, the first line is not worth it. You've added an extra message-send (which is _not_ cheap) to pre-check something that the NSArray (really CFArr

[MEET] CocoaHeads: Silicon Valley DATE CHANGED

2008-07-23 Thread Stephen Zyszkiewicz
Mac Developers, The CocoaHeads: Silicon Valley meeting tomorrow has been canceled. We may have a meeting next week on the 31st. Please be sure to check the web site beforehand to be sure. Steve ___ Cocoa-dev mailing list (

Re: Sent Actions, Delegates, Outlets

2008-07-23 Thread Oleg Krupnov
On Thu, Jul 24, 2008 at 9:15 AM, Graham Cox <[EMAIL PROTECTED]> wrote: > > On 24 Jul 2008, at 3:58 pm, Oleg Krupnov wrote: > >> Currently the "Sent Actions" section does not even appear in my custom >> view's connections menu at all, how would I make it appear? > > > To clarify: the reason it's not

Re: Sent Actions, Delegates, Outlets

2008-07-23 Thread Graham Cox
On 24 Jul 2008, at 3:58 pm, Oleg Krupnov wrote: Currently the "Sent Actions" section does not even appear in my custom view's connections menu at all, how would I make it appear? To clarify: the reason it's not listed is because the built-in support is for NSControl and its subclasses. If

Re: Help on Menu Item

2008-07-23 Thread Andrew Merenbach
Would a system Service be what you're after? These appear under the application menu > Services. Other than that, I know of no supported way to insert an item into a menu in every program -- although you might also try an NSStatusItem. Note, however, that with that solution, the docs sta

Re: Sent Actions, Delegates, Outlets

2008-07-23 Thread Graham Cox
On 24 Jul 2008, at 3:58 pm, Oleg Krupnov wrote: target/action Is this the same as the following? action is sent to target on a click. The other things you mention are either not detected or not sent on to the target. I don't quite understand how target/action works under the hood. If I

Re: Sent Actions, Delegates, Outlets

2008-07-23 Thread Oleg Krupnov
> target/action Is this the same as the following? > action is sent to target on a click. The other things you mention are either > not detected or not sent on to the target. I don't quite understand how target/action works under the hood. If I were an implementor of NSButton, how would I declar

Re: Sent Actions, Delegates, Outlets

2008-07-23 Thread Graham Cox
On 24 Jul 2008, at 3:34 pm, Oleg Krupnov wrote: I'm building a custom view 1) What is the recommended way of raising external "events" (at least that's what they were called in C#) from within a custom view, in order to trigger actions in other objects that may be observing the view? I assume

Sent Actions, Delegates, Outlets

2008-07-23 Thread Oleg Krupnov
I'm building a custom view 1) What is the recommended way of raising external "events" (at least that's what they were called in C#) from within a custom view, in order to trigger actions in other objects that may be observing the view? I assume it is to use a delegate outlet, right? However I no

Re: Is checking -count worth it?

2008-07-23 Thread Phil
On Thu, Jul 24, 2008 at 4:15 PM, Steve Cronin <[EMAIL PROTECTED]> wrote: > I have a mutable array, M. I want to remove an object, O, from M; O might > not be in M. > M which is being constantly diminished could become empty. > > Is this code worth it? > if ([M count]>0) [M removeObject:O]; > > OR

Help on Menu Item

2008-07-23 Thread Adil Saleem
Hi,Is it possible to make a program that appears as a menu item for all applications ? Actually i want to make a custom action which i want to appear in every application's menu (just like About, Quit etc...) or it can just appear in the Apple menu so that it is always available no matter what

Re: Is checking -count worth it?

2008-07-23 Thread Quincey Morris
On Jul 23, 2008, at 21:15, Steve Cronin wrote: I have a mutable array, M. I want to remove an object, O, from M; O might not be in M. M which is being constantly diminished could become empty. Is this code worth it? if ([M count]>0) [M removeObject:O]; OR should I just do [M remove O]; I a

Re: how to correctly set knob/thumb proportion and scroller orientation in NSScroller

2008-07-23 Thread San Saeteurn
Hello, I want to write a simple program that can take Chinese characters and convert them into their pinyin equivalence. Since Mac OS X has a way of converting pinyin into Chinese characters, I am wondering if there is some sort of Cocoa interface that can allow me to access this functionality an

Re: how to correctly set knob/thumb proportion and scroller orientation in NSScroller

2008-07-23 Thread Graham Cox
There is, in 10.5, setKnobProportion: to make up for the deprecated method. Is there some reason why you just don't embed a view inside an NSScrollView? It's much easier than trying to fiddle about with scrollbars yourself. Graham On 24 Jul 2008, at 2:15 pm, Rua Haszard Morris wrote:

Is checking -count worth it?

2008-07-23 Thread Steve Cronin
Folks; I'm really trying to learn how to write smart fast code. Code that takes maximum advantage of all of the battle-tested intelligence built into Cocoa/ObjC2. Now days with the "halo" and the "JesusPhone", I personally smell an excellent book opportunity... But enough chit-chat. I have

Re: master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread Izidor Jerebic
On 23.7.2008, at 23:42, mmalc crawford wrote: On Jul 23, 2008, at 11:51 AM, Izidor Jerebic wrote: Hm, the docs say: Typically, the content binding is created automatically when the initial NSTableColumn binding is made, binding to the column's NSArrayController. I don't see what is inap

how to correctly set knob/thumb proportion and scroller orientation in NSScroller

2008-07-23 Thread Rua Haszard Morris
I'm implementing a scrollable pane and have come across to slightly weird issues with NSScroller, leading to me wondering whether I'm going about this the wrong way... 1. The thumb proportion can only be set by setFloatValue:knobProportion: method which is deprecated in 10.5. Is there an

Re: Daemon Advice?

2008-07-23 Thread Jens Alfke
On 23 Jul '08, at 2:20 PM, Nick Zitzmann wrote: Calling ObjC methods in a signal handler is not a good idea: You can work around this by using a kqueue to receive the signal, creating a file descriptor to listen on the kque

NSTextView displaying a square instead of carriage return

2008-07-23 Thread chaitanya pandit
Hi, I am subclassing NSTextView and there is a weird thing happening, some times it displays a box (snapshot attached) instead of a carriage return. Any idea what might causing this? Thanks for any help. <>___ Cocoa-dev mailing list (Cocoa-dev@l

Re: NSDocument Save As to Windows share is failing

2008-07-23 Thread Adam R. Maxwell
On Jul 23, 2008, at 8:03 PM, Doug Knowles wrote: - When Save As... is selected from the menu, our implementation of writeToURL:ofType:error: is being called with an URL specifying a location in a hidden temporary folder in the directory (in a shared directory on a Windows machine) targeted by t

Re: NSDocument Save As to Windows share is failing

2008-07-23 Thread Graham Cox
I have experienced this, as a user. In our case it was a permissions issue - have you checked that? cheers, Graham On 24 Jul 2008, at 1:03 pm, Doug Knowles wrote: Has anyone else experienced this, ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.

NSDocument Save As to Windows share is failing

2008-07-23 Thread Doug Knowles
Hi, all, In the application I'm being paid to finish (soon), we're finding that we can't save our document to a directory on a Windows share, and some further experimentation indicates that it's not unique to our app. Since it seems likely that others have seen this phenomenon, I'm looking for adv

A study of the Cocoa Indie Island

2008-07-23 Thread Erik Buck
There is an interesting study regarding the sociology of Cocoa Indie developers at http://madebysofa.com/indiefever/ which I read and enjoyed via http://daringfireball.net/. My wife and I used to describe the various Cocoa developer forums, WWDC, the old MacHack, Stepwise, etc. as my "islan

Re: Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Graham Cox
For zooming, check out NSView's -scaleUnitSquareToSize: which changes the scale factor of the view's transform. Together with -setFrame: (or -setFrameSize:) you can implement arbitrary zooming. If the view is enclosed by a scroller, it will adjust the scrollbars automatically, as well as an

Cleaning up my Data Model

2008-07-23 Thread Richard Gutierrez
I have recently changed my data model structure, and am looking for a way to determine if any of my old array controllers are still bound to objects in my nib file. I have tons of bindings in my application and it would take entirely too long to go through the bindings one-by-one. I simply need to

Re: Spotlight and NSPredicate

2008-07-23 Thread Pedro Teixeira
On 2008/07/23, at 22:15, Matt Neuburg wrote: On Wed, 23 Jul 2008 18:14:56 +0100, Pedro Teixeira <[EMAIL PROTECTED]> said: Is is just me, or its impossible to use Spotlight for its simplest action: search a keyword in all metadata (* = "something"cdw) I really cant find a way to do this using

Re: NSLog on releasebuild

2008-07-23 Thread Jean-Daniel Dupas
By carefull with the basename function. Theoricaly, it require a mutable string (char * and not const char *), so this logging function may crash (even it for now it works). Le 23 juil. 08 à 20:01, Nate Weaver a écrit : This is the route I follow. I use normal NSLog() statements for condit

Re: First Responder, NSUndoManager, and MyDocument

2008-07-23 Thread Todd Heberlein
Because it's handled by something earlier in the responder chain. Your document isn't going to be first responder. Got it. Thanks! I didn't realize my document was so *far* down the list, but it all makes sense now. I should have known better. Thanks again, Todd _

NSViewAnimation and setDocumentView

2008-07-23 Thread Martin Redington
I'm swapping views in my app using -[NSScrollView setDocumentView:] I'd like to fade the old view out, and the new one in. NSViewAnimation looks to be exactly what I want, but doesn't seem to be well suited to use with setDocumentView, which handles the view swapping internally. Does anyone have

Re: First Responder, NSUndoManager, and MyDocument

2008-07-23 Thread Seth Willits
On Jul 23, 2008, at 2:10 PM, Todd Heberlein wrote: What gives? Why doesn't an undo: message get sent to my MyDocument object? Because it's handled by something earlier in the responder chain. Your document isn't going to be first responder. See figure 1-10. http://developer.apple.com/docu

Re: master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread mmalc crawford
On Jul 23, 2008, at 11:51 AM, Izidor Jerebic wrote: Hm, the docs say: Typically, the content binding is created automatically when the initial NSTableColumn binding is made, binding to the column's NSArrayController. I don't see what is inappropriate. It should work, because I set it to th

Re: NSPredicateEditorRowTemplate and ANY predicate

2008-07-23 Thread Peter Ammon
On Jul 23, 2008, at 1:58 AM, [EMAIL PROTECTED] wrote: De: [EMAIL PROTECTED] On Jul 22, 2008, at 12:05 PM, Frédéric Testuz wrote: Hello, Is it possible to prepare a row template for a NSPredicateEditor in IB for a predicate like "ANY keyPath == 'aValue'" ? I'm not sure I understand your

Re: Daemon Advice?

2008-07-23 Thread Nick Zitzmann
On Jul 23, 2008, at 2:09 PM, Karl Moskowski wrote: void handleSignal (int signal) { NSLog(@"Shutting daemon down"); AnObject * anObject = [[AnObject alloc] init]; [anObject doCleanup]; [[NSDistributedNotificationCenter defaultCenter] postNotificationName:@"DaemonHas

Re: Spotlight and NSPredicate

2008-07-23 Thread Matt Neuburg
On Wed, 23 Jul 2008 18:14:56 +0100, Pedro Teixeira <[EMAIL PROTECTED]> said: >Is is just me, or its impossible to use Spotlight for its simplest >action: search a keyword in all metadata (* = "something"cdw) > >I really cant find a way to do this using NSPredicate... http://developer.apple.com/DOC

First Responder, NSUndoManager, and MyDocument

2008-07-23 Thread Todd Heberlein
Just a intellectual curiosity question here: I have a question about First Responder and the Document-based architecture. Why does "undo" go to the NSUndoManager and not my NSDocument subclass? I was playing around with Hillegass's RaiseMan with Undo capabilities (Chap 9), and from lookin

Daemon Advice?

2008-07-23 Thread Karl Moskowski
I'm working on a Foundation tool to be used as a launchd daemon. It's a Leopard-only GC app that uses FSEvents to watch for changed files. I'm using something similar to the below code, and it seems to work correctly when under launchd control. However, information on creating Foundation-ba

Re: Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Rick Mann
Thanks to everyone for their informative answers. I gotta say, I think the docs are a bit lacking, but maybe I just had certain assumptions going in (that a subview's frame should be contained within a superview's bounds, etc.) -- Rick ___ Cocoa

Re: master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread Izidor Jerebic
On 23.7.2008, at 20:08, mmalc crawford wrote: On Jul 23, 2008, at 9:40 AM, Izidor Jerebic wrote: But it again confirmed that bindings are not quite what they should be. This bug should never happen to me or should be resolved in 5 minutes: InterfaceBuilder should prevent illegal combinati

Re: Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Erik Buck
As is the case with all NSViews, the frame of the view defines the area occupied by the view in its superview's coordinate system. The bounds of a view defines that view's own coordinate system irrespective of the frame. Therefore, if the frame size and bounds size for a particular view are d

Re: Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Gordon Apple
You can look at the Sketch sample code for one way. You can lift SKTZoomingScrollView intact, although you may need to implement your own controller to extract related code from the Sketch document class. However, I have still to get it to work properly when using CALayers. Sketch scales the bou

Re: NSLog on releasebuild

2008-07-23 Thread Gregory Weston
Andrew Merenbach wrote: Is there anything particularly wrong with NSLog statements being in a release package? Performance wise? Security wise? Just wondering the root of the question. I'd say that the most important reason for removing the NSLog() statements *might* be the look of the program

Re: NSLog on releasebuild

2008-07-23 Thread Timothy Reaves
> On Jul 23, 2008, at 6:48 PM, Mike wrote: > >> Hello, >> >> During development and debug I typically use tons of NSLog()- >> messages to get info what's happening. >> I don't wish to include these messages to release-build so what is >> common/recommended way to get rid of them? >> >> Should I com

Re: Using NSUserDefaults with NSPreferencePane

2008-07-23 Thread Gregory Weston
Tim Perrett wrote: Hey all, Im having issues saving my preferences from a preference pane im constructing. I have tried using NSUserDefaultsController; to which the values appear to be remembered somewhere, but not as a file in any of the usual places a plist preference file would be found...

Re: Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Quincey Morris
On Jul 23, 2008, at 10:43, Rick Mann wrote: What attribute of the contained views does NSScrollView (or the NSScroller, whatever) use to determine what the scroll bars look like? I read the doc a couple times, but I couldn't quite figure it out. Is it the bounds.size of my contained view? W

Re: Using NSUserDefaults with NSPreferencePane

2008-07-23 Thread Sherm Pendley
On Wed, Jul 23, 2008 at 10:36 AM, Tim Perrett <[EMAIL PROTECTED]> wrote: > > Im having issues saving my preferences from a preference pane im > constructing. I have tried using NSUserDefaultsController; to which the > values appear to be remembered somewhere, but not as a file in any of the > usua

Re: NSArrayController and bindings and RaiseMan

2008-07-23 Thread Todd Heberlein
Before I spend a lot of time on this, I'm just wondering if the undo functionality described in Chapter 9 is even possible without bindings and NSArrayController. Well, NeXTSTEP, OpenStep, Cocoa applications have been doing undo/redo well before Apple relatively recently added Controllers, so

Re: master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread mmalc crawford
On Jul 23, 2008, at 9:40 AM, Izidor Jerebic wrote: But it again confirmed that bindings are not quite what they should be. This bug should never happen to me or should be resolved in 5 minutes: InterfaceBuilder should prevent illegal combinations or there should be a debugging option that

Re: PropertyList -> NSBrowser / NSOutlineView?

2008-07-23 Thread Corbin Dunn
On Jul 22, 2008, at 4:48 PM, Joeles Baker wrote: Hi Ken, Any other hints for a really basic NSBrowser or NSOutlineView sample (not /Developer/Examples/AppKit/OutlineView) ? I can't personally vouch for these, but a full-text search of all doc sets yields: http://developer.apple.com/sam

Re: NSLog on releasebuild

2008-07-23 Thread Nate Weaver
This is the route I follow. I use normal NSLog() statements for conditions that "should never happen", and DebugLog() for debugging: #ifdef DEBUG #define DebugLog(s, ...) NSLog((@"%s %s:%d " s), __func__, basename(__FILE__), __LINE__, ## __VA_ARGS__); #else #define DebugLog(s, ...) #endif T

Dumb question: How does NSScrollView know the size of the thing it's scrolling?

2008-07-23 Thread Rick Mann
What attribute of the contained views does NSScrollView (or the NSScroller, whatever) use to determine what the scroll bars look like? I read the doc a couple times, but I couldn't quite figure it out. Is it the bounds.size of my contained view? What if I'm setting a CoreGraphics CTM to zoo

Spotlight and NSPredicate

2008-07-23 Thread Pedro Teixeira
Is is just me, or its impossible to use Spotlight for its simplest action: search a keyword in all metadata (* = "something"cdw) I really cant find a way to do this using NSPredicate... ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please

NSArrayController and bindings and RaiseMan

2008-07-23 Thread Diop Mercer
Hi. For grins, I'm doing the RaiseMan app from Hillegass 3rd ed. without using NSArrayController or bindings. Currently in chapter 9, I'm stuck trying to implement undo/redo. Simple undo/redo is easy, but the more intelligent undo/redo in the exercise that you can get with bindings and NSArrayCont

Re: NSLog on releasebuild

2008-07-23 Thread Chris Backas
I agree with this. I like to leave my Console open most of the time, to monitor for potential software problems. I really dislike applications that just spew endless nonsense there under even normal conditions. Chris On Jul 23, 2008, at 11:36 AM, Andrew Merenbach wrote: I'd say that the

Re: NSLog on releasebuild

2008-07-23 Thread Mike
Thanks to all. Seems like #ifndef xxx . suites best for my needs which was my original solution. Just wished to ask if there is some switch somewhere in settings to toggle it on/off. btw, is there any predefined var to determine debug/release -build so macro would work automatically?

Using NSUserDefaults with NSPreferencePane

2008-07-23 Thread Tim Perrett
Hey all, Im having issues saving my preferences from a preference pane im constructing. I have tried using NSUserDefaultsController; to which the values appear to be remembered somewhere, but not as a file in any of the usual places a plist preference file would be found... As I need to

Re: master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread Izidor Jerebic
Isn't this list great? After an hour of debugging, all you have to do is send an email and few minutes later your problem is solved :-) It turned out that the bug was this: I poked around master NSTableView and it had a binding of 'content' to the same master array controller that was als

Re: NSLog on releasebuild

2008-07-23 Thread Dmitri Goutnik
On Jul 23, 2008, at 6:48 PM, Mike wrote: Hello, During development and debug I typically use tons of NSLog()- messages to get info what's happening. I don't wish to include these messages to release-build so what is common/recommended way to get rid of them? Should I comment them all out o

Using NSUserDefaults with NSPreferencePane

2008-07-23 Thread Tim Perrett
Hey all, Im having issues saving my preferences from a preference pane im constructing. I have tried using NSUserDefaultsController; to which the values appear to be remembered somewhere, but not as a file in any of the usual places a plist preference file would be found... Shared User D

Re: NSLog on releasebuild

2008-07-23 Thread Shawn Erickson
On Wed, Jul 23, 2008 at 8:33 AM, Phillip Jacobs <[EMAIL PROTECTED]> wrote: > Is there anything particularly wrong with NSLog statements being in a > release package? Performance wise? Security wise? Just wondering the root of > the question. 1) Possible performance issue (just burning CPU for some

Re: NSLog on releasebuild

2008-07-23 Thread Shawn Erickson
On Wed, Jul 23, 2008 at 7:48 AM, Mike <[EMAIL PROTECTED]> wrote: > Hello, > > During development and debug I typically use tons of NSLog()-messages to get > info what's happening. > I don't wish to include these messages to release-build so what is > common/recommended way to get rid of them? > > S

Re: Problem on clearing points and paths on a NSView

2008-07-23 Thread JArod Wen
Ken you are right. Fortunately I set isOpaque to be YES in my view. I added the lines Graham had written before and now it is working perfectly! Thanks buddies for all your help! On Jul 23, 2008, at 2:04 AM, Ken Ferry wrote: On Tue, Jul 22, 2008 at 9:06 PM, Jens Alfke <[EMAIL PROTECTED]>

Re: Inverse Regex Library?

2008-07-23 Thread Steve Byan
On Jul 17, 2008, at 10:09 AM, Philip Mötteli wrote: Does anybody know of a library, that takes a bunch of strings and produces a regex-string from them? E. g: "Word1" "Word2" "Word5" "Word8" "Word11" "Word19" "Word23" "Word45" "Word77" should give "Word[0-9]{1,2}". Or I would even be more h

master-detail: binding array controller to the attribute of selection of master array controller

2008-07-23 Thread Izidor Jerebic
Hello! I have a very simple (one would think) master-detail arrangement: there is a domain object, which has several items, each of items has several parts. In the GUI window which represents domain object, one array controller is bound to FileOwner.items (file owner is a domain object),

Re: NSLog on releasebuild

2008-07-23 Thread Andrew Merenbach
I'd say that the most important reason for removing the NSLog() statements *might* be the look of the program. Many users who use the Console probably wouldn't like it to become cluttered with detritus from spurious log statements. It makes tech support more difficult if they need to look

Re: NSLog on releasebuild

2008-07-23 Thread Phillip Jacobs
Is there anything particularly wrong with NSLog statements being in a release package? Performance wise? Security wise? Just wondering the root of the question. Thanks, -Phillip On Jul 23, 2008, at 10:30 AM, Andrew Merenbach wrote: Hi! I think that you would want an @ symbol before the op

Re: NSLog on releasebuild

2008-07-23 Thread Andrew Merenbach
Hi! I think that you would want an @ symbol before the opening quote: NSLog(@"Whatever"); Cheers, Andrew On Jul 23, 2008, at 8:18 AM, Ian was here wrote: Try this #ifdef DEBUG NSLog("Whatever"); #endif --- On Wed, 7/23/08, Mike <[EMAIL PROTECTED]> wrote: From: Mike <[EMAIL P

Re: NSLog on releasebuild

2008-07-23 Thread Ian was here
Try this #ifdef DEBUG NSLog("Whatever"); #endif --- On Wed, 7/23/08, Mike <[EMAIL PROTECTED]> wrote: > From: Mike <[EMAIL PROTECTED]> > Subject: NSLog on releasebuild > To: "Cocoa-Dev List" > Date: Wednesday, July 23, 2008, 7:48 AM > Hello, > > During development and debug I typically us

NSLog on releasebuild

2008-07-23 Thread Mike
Hello, During development and debug I typically use tons of NSLog()-messages to get info what's happening. I don't wish to include these messages to release-build so what is common/recommended way to get rid of them? Should I comment them all out or is there some easier way to disable the

Re: NSDocument's isDocumentEdited

2008-07-23 Thread Graham Cox
On 23 Jul 2008, at 10:55 pm, John Love wrote: you just need to call updateChangeCount, rather than mess with overriding NSDocument's –isDocumentEdited. Well, yes. q.v. what I stated in my last message. Apple's comments within their "NSDocument.h" state that with: Can I just ask some

Re: NSTask

2008-07-23 Thread Clark Cox
On Tue, Jul 22, 2008 at 11:29 PM, Torsten Curdt <[EMAIL PROTECTED]> wrote: >> Most of the instance methods of NSThread are not available prior to 10.5. > > I see > >> Those that are you would call within the thread by calling +currentThread > > Well, I would have to do that in the new thread and pa

Re: Exception thrown when calling NSConnection connectionWithReceivePort:sendPort:

2008-07-23 Thread Chris Backas
Hi Ken, Thanks for responding. I probably should have mentioned it, as I had a similar thought (but the message was getting so long I feared no one would read it as it was!) DOConnectionSocket is definitely not nil, I watched the process through the debugger. The port and the host as pass

Re: NSDocument's isDocumentEdited

2008-07-23 Thread John Love
In the following, I have expanded on what I believe I have learned Grayson's response. (Any errors are mine, not Grayson's) Apple's comments within their "NSDocument.h" state that with: - (void)updateChangeCount:(NSDocumentChangeType)change "Record the fact that a change affecting the value retu

Re: Checking for KVC compliancy

2008-07-23 Thread Keith Duncan
Cocoa classes seem to throw an exception when trying to bind to a non-KVC method As they should. If you've bound to a non-KVC compliant keypath then it's likely that you've bound to the wrong keypath and that isn't a runtime recoverable error. Keith Duncan [EMAIL PROTECTED], 33software.co

Checking for KVC compliancy

2008-07-23 Thread Milen Dzhumerov
Hi all, Since I'm implementing bindings for all my custom views, I was wondering whether there is a method which I can use to check whether a keypath is KVC compliant before I actually bind to it? Cocoa classes seem to throw an exception when trying to bind to a non-KVC method. If there i

Re: NSPredicateEditorRowTemplate and ANY predicate

2008-07-23 Thread [EMAIL PROTECTED]
>De: [EMAIL PROTECTED] > >On Jul 22, 2008, at 12:05 PM, Frédéric Testuz wrote: > >> Hello, >> >> Is it possible to prepare a row template for a NSPredicateEditor in >> IB for a predicate like "ANY keyPath == 'aValue'" ? >> > >I'm not sure I understand your question. How is this different than

Re: SBApplication error with iTunes 7.7

2008-07-23 Thread Fabian
Thanks has, your help is always appreciated, always enlightening. In fact I think you just solved my main problem as well, which was related to iTunes 7.7 artwork retrieval always returning nil on some systems. I will switch to appscript now, and really should have done it a long time ago. Can't re

Re: Challenge Chapter 8: sorting with key-path

2008-07-23 Thread Alex Heinz
The only problem I can see is that you've spelled "[EMAIL PROTECTED]" incorrectly. Make sure it's spelled right and that should work. (Another) Alex On Jul 22, 2008, at 11:23 PM, Alexandre Badez wrote: Hy, I'm actually reading the "cocoa programming for Mac OS X (third edition)". In cha

Re: Challenge Chapter 8: sorting with key-path

2008-07-23 Thread Alexandre Badez
On Wed, Jul 23, 2008 at 09:19, Martijn <[EMAIL PROTECTED]> wrote: > My guess is you should try personName.length LOL :D Thanks ^^ I'm just a fool, that should learn English before coding... -- Alex ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.co

Re: Challenge Chapter 8: sorting with key-path

2008-07-23 Thread Martijn
My guess is you should try personName.leng*th* ___ 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/Up

Re: Challenge Chapter 8: sorting with key-path

2008-07-23 Thread Alexandre Badez
I understand how to call a method and I've make my app work as I wanted with method and code etc. The problem, is that the challenge's main objective is to do it only in interface builder, and this is where I'm stuck. I should retrieve the lenght of personName (witch is as you guess a NSString) an