Re: NSGraphiteControlTint in app

2008-11-10 Thread Benjamin Dobson
At a guess, [[[yourWindow standardWindowButton:NSWindowCloseButton] cell] setControlTint:NSGraphiteControlTint]; Repeat for each window button. On 10 Nov 2008, at 07:51:23, Ralph Manns wrote: Hello, I don't think the method setControlTint is the solution I'm looking for, because only a few

Re: Image from font file

2008-11-10 Thread Georg Seifert
Once again me, I just did a bit more searching. I found a quicklook-sample with displays a QLPreviewPanel. It shows the same image then the finder. But I like to get this image as a NSImage inside my app. I use: QLThumbnailImageCreate but only get a thumbmail-like image. Is there any way

Responder Chain Multiple Windows

2008-11-10 Thread Todd Heberlein
I have a Documen-based application, and the besides the document's main window, the user can create additional windows to be opened to show aspects of the document/data from a different perspective; these windows are loaded by an instance of an NSWindowController subclass. Unfortunately,

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread Kyle Sluder
On Sun, Nov 9, 2008 at 10:58 PM, Michael Ash [EMAIL PROTECTED] wrote: Whoops, you're right. Still, NSAffineTransform can obviously do translations, so surely this objection does not make sense? It's a gut reaction. Not being a linear algebra guru, I'm wondering if it's done to avoid confusion;

[MEET] CocoaHeads Frankfurt, tonight 2008-11-10 8pm

2008-11-10 Thread Torsten Curdt
Just a quick reminder: Cocoa chit-chat, code and beers. Tonight at Club Voltaire. http://cocoaheads.org/de/Frankfurt/index.html Hope to see you there! cheers -- Torsten ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin

Re: NSGraphiteControlTint in app

2008-11-10 Thread John Joyce
Hello, I don't think the method setControlTint is the solution I'm looking for, because only a few classes have such a method, NSWindow doesn't. Maybe my question was to general. Is there a way without using private methods to set the complete appearance of an application to

Re: Detect microphone

2008-11-10 Thread Graham Cox
On 10 Nov 2008, at 10:15 pm, chaitanya pandit wrote: Well i tried this before but this doesn't work either Doesn't work covers a multitude of sins; *what* doesn't work? Also, do you know whether the Mac Mini can actually physically detect whether a microphone is plugged into the line-in

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread Graham Cox
On 10 Nov 2008, at 10:07 pm, Kyle Sluder wrote: On Mon, Nov 10, 2008 at 5:56 AM, Graham Cox [EMAIL PROTECTED] wrote: Yet you need to do this all the time if you do rotation of anything at all. Rotation around the origin is almost never in itself useful. Eh, I beg to differ. Rotation

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread Graham Cox
On 10 Nov 2008, at 9:40 pm, Kyle Sluder wrote: Interestingly enough, I can't recall seeing any graphics API that provided rotation around a point. I know DirectX doesn't. Yet you need to do this all the time if you do rotation of anything at all. Rotation around the origin is almost never

NSButtonCell question

2008-11-10 Thread Robert Mullen
I have an NSButtonCell in my NSTableView that has an image set to imitate the arrow link in iTunes with the title showing the display value. Unfortunately the title text is clickable as well as the arrow and both send you off to the linked action. I have searched and seen references to

Re: Core Data entity fetching by date

2008-11-10 Thread Sean McBride
On 11/8/08 11:50 PM, Quincey Morris said: you may decide it's worth simplifying things by adding a separate month attribute to every entity The tradeoff there of course is that the model would then imply a certain calendar. Since most of the world use the Gregorian calendar, that might not be a

Re: Responder Chain Multiple Windows

2008-11-10 Thread Todd Heberlein
On Nov 10, 2008, at 5:31 AM, Graham Cox wrote: On 11 Nov 2008, at 12:11 am, Todd Heberlein wrote: From the documentation it seems that the window's NSDocumentController, even though it isn't the document's main window, should still be in the responder chain. I assume you actually mean

Re: Can't get CABasicAnimation to explicitly animate frame property of CALayer

2008-11-10 Thread David Duncan
On Nov 9, 2008, at 4:04 AM, Oleg Krupnov wrote: Using Core Animation, I want to make a layer change its position and size with animation. So I need to use the frame property of CALayer, which is animatable, according to the documentation. http://developer.apple.com/qa/qa2008/qa1620.html --

Re: Observing NSArrayController selectionIndex always returns null

2008-11-10 Thread Sean McBride
On 11/9/08 3:59 AM, Ken Tozier said: Changes do trigger the observer's observeValueForKeyPath method but trying to fetch the value using [inChange objectForKey: NSKeyValueChangeNewKey] Always returns null. Is this a bug in NSArrayController? Yes. See (Missing) KVO notification old and new

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread James W. Walker
On Nov 10, 2008, at 2:40 AM, Kyle Sluder wrote: If I remember correctly, matrix multiplication does not distribute over matrix addition, and since a transformation matrix stack is essentially a product of sums, the API designers might, as you suggest, have simply left the functionality out for

Re: Responder Chain Multiple Windows

2008-11-10 Thread j o a r
On Nov 10, 2008, at 9:00 AM, Todd Heberlein wrote: Oops. Yes, MyDocument is a subclass of NSDocument and BrowserViewController is a subclass of NSWindowController ...should probably be called BrowserWindowController in that case...:-) In MyDocument I have a method that has the

Re: Detect microphone

2008-11-10 Thread chaitanya pandit
On 10-Nov-08, at 4:55 PM, Graham Cox wrote: On 10 Nov 2008, at 10:15 pm, chaitanya pandit wrote: Well i tried this before but this doesn't work either Doesn't work covers a multitude of sins; *what* doesn't work? Oh, i was assuming that the AudioHardwareGetProperty method will return

Badged icons

2008-11-10 Thread Andy Bell
Hi, Is there another way of creating badged icons other than creating a resource fork for the file? I am working on a project which monitors files and would like to overlay a badge on the files being monitored so that the user can easily identify them within Finder. Thanks Andy

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread Kyle Sluder
On Mon, Nov 10, 2008 at 5:56 AM, Graham Cox [EMAIL PROTECTED] wrote: Yet you need to do this all the time if you do rotation of anything at all. Rotation around the origin is almost never in itself useful. Eh, I beg to differ. Rotation about the origin is one of the most common operations in

Re: ObjC data structure for C++/ObjC++ objects?

2008-11-10 Thread Thomas Engelmeier
On 08.11.2008, at 02:41, Jonathan Bailey wrote: I am trying to find a way to create a dynamically-growable objective C data structure within objective C++ code, such as a NSMutableDictionary, that can store values that are pointers to an objective C++ or straight-up C++ object. Personally,

Re: Responder Chain Multiple Windows

2008-11-10 Thread Todd Heberlein
What if you make the window controller the delegate of the window? Ka-ching! Thanks. that did it. Todd ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact the

advice needed please

2008-11-10 Thread Michael de Haan
I am repeating a post that I posted on the obj C group...realized that the traffic there is very low. Hi all, May I ask the group the following...perhaps a little OT...if so, I apologize. I am just starting off in Obj C...have a basic understanding of C. Bought Kochan's book (Programming

duplicate decalration for protocol

2008-11-10 Thread pan xuan
Hi, I have two classes that both conform to a protocol ABC. Now the third class needs to import those two classes and I got a warning duplicate declaration for protocol ABC. Could anybody tell me how to reduce this kind of warning? Thanks BR, Pan

Floating point pixel data / image handling confusion

2008-11-10 Thread Felix Ulber
Hi Folks, I am working on an Cocoa Application whose main purpose is to display some stuff in OpenGL. In conjunction with that I need to be able to read in floating point images (most likely from an exr file) and resize them. Unfortunately, with NSImage and NSBitmapImage it seems I can get only

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread dreamcat7
Just to make even clearer what Quincey has said; For NSTableView you MUST follow Quincey's conventions for the data representation. If you do not then simply the NSTableView control will not work. This is due to some very specific restrictions and limitations in the NSTableView Cocoa

MVC and Cocoa question

2008-11-10 Thread Steven Guitar
i am working on the challenge exercises for aaron hillegass' book, 3rd edition, for chapter 18 challenge. i have setup the application with a subclass of NSDocument (MyDocument), a subclass of NSView (DrawPadView), and a model component called Shape. basically as the user uses the mouse to

Re: A trapped keyDown event

2008-11-10 Thread Eric Gorr
I now have a simple test application which demonstrates this problem http://ericgorr.net/CocoaWithPP.zip Although, instead of Cmd-N, use Cmd-Q with the NSPanel active. The application won't quit. If one clicks on the window and presses Cmd-Q, the application will quit. I have entered a

Re: Detect microphone

2008-11-10 Thread Kyle Sluder
On Mon, Nov 10, 2008 at 6:44 AM, chaitanya pandit [EMAIL PROTECTED] wrote: I tried to record an audio with Quicktime player, it didn't warn me about absence of a microphone (Which ideally it should have) so i guess there really isn't a way to know of a connected mic. Electrically there's no

Re: MVC Question . . .

2008-11-10 Thread Michael A. Crawford
On Nov 9, 2008, at 1:01 PM, Ken Thomases wrote: On Nov 8, 2008, at 7:46 PM, Michael A. Crawford wrote: I have a model-view-control class hierarchy that I'd like to add an auxiliary (test-only) view to. I've created a 2nd NIB with an NSPanel instance associated with a sub-classed

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread mmalcolm crawford
On Nov 10, 2008, at 7:36 AM, dreamcat7 wrote: For NSTableView you MUST follow Quincey's conventions for the data representation. No, you don't. Quincey's statement that the most natural fit with a NSTableView would probably be an array of dictionaries is true, but there is no *need* to

GC and propertyListFromData:mutabilityOption:format:errorDescription:

2008-11-10 Thread Michael Link
The documentation for propertyListFromData:mutabilityOption:format:errorDescription: says that errorDescription needs to be released by the caller. In a garbage collected environment is this still the case? Should NSMakeCollectable() be called on errorDescription? Is it safe to call

Re: Detect microphone

2008-11-10 Thread chaitanya pandit
Well i tried this before but this doesn't work either - (BOOL)micConnected { BOOL retVal = YES; UInt32 size; OSStatus err =noErr; size = sizeof(AudioDeviceID); AudioDeviceID inputDeviceID; err =

How to write a remote control app for Mac

2008-11-10 Thread David
Hello, Can someone point me to general documentation that would give me an idea how to write a remote control application for the Mac. The hardest part seem to be how to capture what's currently on the screen and when it changes. I have no idea where to look. Is it even possible to do this while

Re: Inviting to comment on Cocoa categories

2008-11-10 Thread Roland King
possibly drifting towards off topic here but ... An Affine Transform (in the context we're talking about here here) is a transform which maps straight lines to straight lines. If it was straight when you started, it's straight after you're done. It also preserves the relative distance

Re: Detect microphone

2008-11-10 Thread Kyle Sluder
On Mon, Nov 10, 2008 at 2:45 AM, chaitanya pandit [EMAIL PROTECTED] wrote: But on my Mac Mini which doesn't have a built in microphone it still returns YES for isConnected and the device returned is Built-in input That would be the line-in jack. Have you tried asking on the coreaudio-api list?

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread I. Savant
On Mon, Nov 10, 2008 at 1:48 PM, mmalcolm crawford [EMAIL PROTECTED] wrote: NSTableView does not place any restriction on the way its data is *represented*, just how it is *provided*. The more important point of focus here is that the *NSTableDataSource protocol* exists precisely *because*

Re: How to write a remote control app for Mac

2008-11-10 Thread Charles Steinman
Vine Server is open-source (GPL). http://sourceforge.net/projects/osxvnc/ Cheers, Chuck - Original Message From: David [EMAIL PROTECTED] To: Cocoa-Dev Mail cocoa-dev@lists.apple.com Sent: Monday, November 10, 2008 11:49:58 AM Subject: How to write a remote control app for Mac

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread dreamcat7
Hi, Sorry maybe i should have clarified that but i believed that Quincey had already explained about the datasource methods. You *must* (if you dont want to end up in a heap of self-inflicted mess) represent your data in those way - WHEN you intend to link to an NSTableView using

Re: MVC and Cocoa question

2008-11-10 Thread Kyle Sluder
On Mon, Nov 10, 2008 at 11:56 AM, Steven Guitar [EMAIL PROTECTED] wrote: basically as the user uses the mouse to draw shapes, i have an NSMutableArray in DrawPadView that contains the various shapes drawn by the user. No. Bad. This is model information, it should be stored in the model.

Re: GC and propertyListFromData:mutabilityOption:format:errorDescription:

2008-11-10 Thread Quincey Morris
On Nov 10, 2008, at 11:04, Michael Link wrote: The documentation for propertyListFromData:mutabilityOption:format:errorDescription: says that errorDescription needs to be released by the caller. In a garbage collected environment is this still the case? Should NSMakeCollectable() be

Stop NSFileManager copyFile in progress? Can you kill a thread?

2008-11-10 Thread David
I have NSFIleManager copying files in a secondary thread. The user can select to cancel the copy. Is there a way to force NSFileManager to stop copying a file? The files could be of arbitrary size. A large file could take quite a while to end. I currently check if the thread has been cancelled

Re: How to manage (My)SQL data in Cocoa

2008-11-10 Thread mmalcolm crawford
On Nov 10, 2008, at 12:39 PM, dreamcat7 wrote: Sorry maybe i should have clarified that but i believed that Quincey had already explained about the datasource methods. You *must* (if you dont want to end up in a heap of self-inflicted mess) represent your data in those way - WHEN you

variable sensitive to Active Build Configuration

2008-11-10 Thread JB
Hi all, I'm building a small app that talks to a web service, so I would like use different URLs for the DEBUG vs. RELEASE targets (staging and production URLs, respectively). What is the best way to conditionally set a variable based on the Active Build Configuration? Many thanks! JB

Quicktime Movie View error

2008-11-10 Thread Christopher Kempke
I'm trying to create a very, very simple QuickTime viewer in Cocoa. I create a new Application, add QTKit and Quicktime frameworks, and drag a QuickTime Movie View into the main window.All is well if I run now (although the movie view is blank). Going back into Interface Builder, I

Re: MVC and Cocoa question

2008-11-10 Thread Graham Cox
On 11 Nov 2008, at 3:56 am, Steven Guitar wrote: i am working on the challenge exercises for aaron hillegass' book, 3rd edition, for chapter 18 challenge. i have setup the application with a subclass of NSDocument (MyDocument), a subclass of NSView (DrawPadView), and a model component

Re: variable sensitive to Active Build Configuration

2008-11-10 Thread Rob Keniger
On 11/11/2008, at 8:47 AM, JB wrote: I'm building a small app that talks to a web service, so I would like use different URLs for the DEBUG vs. RELEASE targets (staging and production URLs, respectively). What is the best way to conditionally set a variable based on the Active Build

Re: Cocoa and NSLog

2008-11-10 Thread Barry Wark
On Sun, Nov 9, 2008 at 2:03 PM, Tommy Nordgren [EMAIL PROTECTED] wrote: Is it possible to open an Additional file for use by logging in Cocoa (I want it to contain ONLY the info logged from my App) I would suggest you check out the Apple System Logging facility (asl.h). It allows you to send

Re: Floating point pixel data / image handling confusion

2008-11-10 Thread Adam R. Maxwell
On Nov 10, 2008, at 4:53 AM, Felix Ulber wrote: I am working on an Cocoa Application whose main purpose is to display some stuff in OpenGL. In conjunction with that I need to be able to read in floating point images (most likely from an exr file) and resize them. Unfortunately, with NSImage

Re: Stop NSFileManager copyFile in progress? Can you kill a thread?

2008-11-10 Thread Adam R. Maxwell
On Nov 10, 2008, at 1:45 PM, David wrote: I have NSFIleManager copying files in a secondary thread. The user can select to cancel the copy. Is there a way to force NSFileManager to stop copying a file? The files could be of arbitrary size. A large file could take quite a while to end. I

Distributed Objects, proxy NSDistantObjects over-retained on OSX 10.5?

2008-11-10 Thread Dave Cox
and dealloced. -- ./server [1] 236 20081110 12:08:33 [ 236] server... ./client 20081110 12:09:42 [ 241] client... 20081110 12:09:42 [ 241] client: server has retainCount 1 20081110 12:09:43 [ 236] server: CServer dealloc 20081110 12:09

Proxy NSDistantObject on broken connection returns zero rather than throwing exceptions on OSX 10.5?

2008-11-10 Thread Dave Cox
, format); vfprintf(stdout, format, args); va_end(args); fflush(stdout); } Test run on OSX 10.4.11 ./server [1] 257 20081110 12:14:21 [ 257] server... ./client 20081110 12:14:34 [ 259] client

Re: Quicktime Movie View error

2008-11-10 Thread Joey Hagedorn
On Nov 10, 2008, at 3:01 PM, Christopher Kempke wrote: I'm trying to create a very, very simple QuickTime viewer in Cocoa. I create a new Application, add QTKit and Quicktime frameworks, and drag a QuickTime Movie View into the main window.All is well if I run now (although the movie

Re: How to write a remote control app for Mac

2008-11-10 Thread Michael Ash
On Mon, Nov 10, 2008 at 2:49 PM, David [EMAIL PROTECTED] wrote: Hello, Can someone point me to general documentation that would give me an idea how to write a remote control application for the Mac. The hardest part seem to be how to capture what's currently on the screen and when it

Re: Stop NSFileManager copyFile in progress? Can you kill a thread?

2008-11-10 Thread Michael Ash
On Mon, Nov 10, 2008 at 4:45 PM, David [EMAIL PROTECTED] wrote: I have NSFIleManager copying files in a secondary thread. The user can select to cancel the copy. Is there a way to force NSFileManager to stop copying a file? The files could be of arbitrary size. A large file could take quite a

Re: duplicate decalration for protocol

2008-11-10 Thread Andrew Farmer
On 10 Nov 08, at 01:40, pan xuan wrote: I have two classes that both conform to a protocol ABC. Now the third class needs to import those two classes and I got a warning duplicate declaration for protocol ABC. Could anybody tell me how to reduce this kind of warning? Assuming that you're