[Moderator] Re: [OT] curious about the iPhone dev program

2008-09-03 Thread Scott Anguish
the iPhone SDK Developer SDK is all under non-disclosure and can't be discussed here. On 2-Sep-08, at 11:00 PM, Paul Archibald wrote: Comrades, going off topic here I am getting interested in iPhone development, but I can't tell if dropping a C-note to Apple is really worth it.

Re: Declaring multidimensional arrays in obj-c

2008-09-03 Thread Ken Ferry
On Tue, Sep 2, 2008 at 2:35 PM, Don Arnel [EMAIL PROTECTED] wrote: Thanks, everyone. I guess I'm going the pointer/malloc way. This is surely the right thing to do. However, it _is_ possible to allocate a dynamic amount of space inline with your object, it just doesn't play well with anyone

Re: nibless applications

2008-09-03 Thread Filip van der Meeren
Ok, I don't know where you have found that article because it is bogus! You are perfectly able to create an application without Nibs... Just create a new cocoaproject, delete the nibfile and replace your main with the following code: int main(int argc, char *argv[]) { [NSApplication

Re: nibless applications

2008-09-03 Thread Uli Kusterer
On 02.09.2008, at 22:46, David Alter wrote: I have a situation where it would make a lot of sense to have a nibless application. I think this situation is unique and would suspect that very few people would need to do this. There is some information on how to do this. Lap Cat Software has

Re: Trouble with Scripting Bridge

2008-09-03 Thread Fabian
Looks like you are getting the track for nothing. Try changing [track get]; to track = [track get]; or you will just be querying the reference for gapless. F. On Mon, Sep 1, 2008 at 4:21 PM, Peter Stirling [EMAIL PROTECTED] wrote: '=' and '==' are equivalent in predicate format strings

Message stack limitations

2008-09-03 Thread RGA
In trying to get my head around some design patterns for cocoa, I thought about the game of life (eg http://www.bitstorm.org/ gameoflife/) . This is where you have a grid of cells, and dependant on the number of live cells around a given cell it dies, comes to life, or remains unchanged.

Re: Message stack limitations

2008-09-03 Thread Phil
On Wed, Sep 3, 2008 at 9:23 PM, RGA [EMAIL PROTECTED] wrote: Putting aside for now whether this is the right way to implement, my question is how are messages processed? What is the maximum stack depth for number of recursive messages? How is this affected by the introduction of 64bit

Binding custom views to model arrays (or trees)

2008-09-03 Thread Oleg Krupnov
I am building a custom view that will display model objects. I am using Core Data for the model, NSTreeController for the controller and bindings to keep them all in sync. I have read the GraphicsBindings sample, and I see that in its overridden bind:... message, the custom view requests the

Re: Modal dialog from a document-modal sheet

2008-09-03 Thread Joshua Pennington
If you turn on NSZombieEnabled, it will log a message informing you when a released object has been messaged. http://www.cocoadev.com/index.pl?NSZombieEnabled Just make sure and turn it off once you're done debugging or you're application will be leaking like a sieve! Cheers, Joshua On

Re: nibless applications

2008-09-03 Thread Jeff Johnson
Filip, All you have to do is create a menu? With all due respect, did you read my articles before your bogus judgment? Creating a proper main menu for the app is one of the main difficulties in going nibless. -Jeff On Sep 3, 2008, at 2:41 AM, Filip van der Meeren wrote: Ok, I don't know

Re: How do I use Sort Descriptor binding in IB on my array controller?

2008-09-03 Thread Negm-Awad Amin
Am Sa,30.08.2008 um 16:58 schrieb [EMAIL PROTECTED] [EMAIL PROTECTED] : I'm struggling with this very problem, can anyone point me in the right direction? Many Thanks Amy You can do it the way Quincey described, but I think that you do not need bindings, because your problem sounds

Re: NSTreeController for readapt estructure

2008-09-03 Thread Xin
Well, I implemented prepareContent method for my NSTreeController for create the colors objects with predicate filters. And this work fine. Now, the problem is how update data in NSOutlineView when I add a new colored object. The first option is to call prepareContent, but with this, all

NSTextField won't fade

2008-09-03 Thread Jake Smith
I'm trying to have an NSTextField fade in and then out over several seconds. I've tried sequential animations, linked animations, and finally the method reproduced below. All produce the same result: the text in the NSTextField appears immediately, remains visible for the duration of the

Why do all these methods of measuring string metrics with font attribute fail?

2008-09-03 Thread an0
I should declare up front that I know there are some arcane ways to measure string metrics using things like NSTextStorage, NSLayoutManager and the kin. Given the string and the font used to render it, it is reasonable there should be some straightforward way to tell the metrics of the string when

Menu with multiple document types

2008-09-03 Thread David Melgar
What is the suggested way to handle filling in the menu when the application supports multiple document types which support different menu options? Thanks Sent from my iPhone ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not

[ANN] AppKiDo 0.981, with fixes for Xcode 3

2008-09-03 Thread Andy Lee
A new version of AppKiDo is now available at http://homepage.mac.com/aglee/downloads/appkido.html If you're using Xcode 3.x, this version of AppKiDo uses a new approach to parsing that enables it to pick up all the docs it failed to pick up in 0.97. I had to overhaul a bunch of the

NSOutlineView developer example

2008-09-03 Thread Boris Prohaska
Hi Guys, i tried to understand the NSOutlineView developer example which is in /Developer/Examples/AppKit/OutlineView. It simply shows the entire filesystem. I tried to alter it, so it shows any relative path of the filesystem, but whatever i do, it does not work. Does anybody have an idea,

Re: NSOutlineView developer example

2008-09-03 Thread Benjamin Stiglitz
Hi Guys, i tried to understand the NSOutlineView developer example which is in /Developer/Examples/AppKit/OutlineView. It simply shows the entire filesystem. I tried to alter it, so it shows any relative path of the filesystem, but whatever i do, it does not work. Does anybody have an idea,

NSInteger

2008-09-03 Thread D.K. Johnston
I'm a bit puzzled by the new NSInteger type. Should I be using this now instead of int? (I'm just as puzzled by NSUInteger, of course.) dkj ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator

Re: nibless applications

2008-09-03 Thread Shawn Erickson
On Tue, Sep 2, 2008 at 1:46 PM, David Alter [EMAIL PROTECTED] wrote: I have a situation where it would make a lot of sense to have a nibless application. What is the situation. It is really that hard to have a nib with only a main menu it in and the do everything else programmatically? Is

Re: View animator, how to do explicit animations / animation groups?

2008-09-03 Thread Matt Long
Are you trying to remove views or animations? Animations are removed from a layer by default which can be overridden in the removedOnCompletion property (in CAAnimation) in an explicit animation. If you're trying to remove views, however, your code is wrong. You need to find the view you

Re: Re: NSOutlineView developer example

2008-09-03 Thread Boris Prohaska
Hi, try to change the path and look what happens. It does not work. Boris Am 03.09.2008 um 16:49 schrieb Benjamin Stiglitz: Hi Guys, i tried to understand the NSOutlineView developer example which is in /Developer/Examples/AppKit/OutlineView. It simply shows the entire filesystem. I tried

Re: [MEET] CocoaHeads Mac Developer Meetings

2008-09-03 Thread Andy Mroczkowski
* Philadelphia, PA - Thursday September 11, 2008 07:00 PM EST Topic to be announced. http://cocoaheads.org/us/PhiladelphiaPennsylvania/index.html http://upcoming.yahoo.com/event/1071293/ -- Andy Mroczkowski: [EMAIL PROTECTED] Philly CocoaHeads:

Re: NSInteger

2008-09-03 Thread Shawn Erickson
On Wed, Sep 3, 2008 at 7:58 AM, D.K. Johnston [EMAIL PROTECTED] wrote: I'm a bit puzzled by the new NSInteger type. Should I be using this now instead of int? (I'm just as puzzled by NSUInteger, of course.) It is a type that will change size as needed based on compiling for 32b or 64b. It is

NSTextView's scroller problem when scaling

2008-09-03 Thread chaitanya pandit
I have a NStextView set up using IB and i am scaling the clipView by using the following code from the textEdit sample code - (void)setScaleFactor:(CGFloat)newScaleFactor { if (scaleFactor != newScaleFactor) { scaleFactor = newScaleFactor; NSView *clipView = [[self

Changing the default audio output hardware

2008-09-03 Thread Half Activist
Hi, Does anybody know how to change the system's default sound output programatically speaking of course ;-) Regards. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list.

Re: Font Color In CTLineDraw?

2008-09-03 Thread Mike Rossetti
Thanks for clearing that up David. Apparently one cannot open an NSGraphicsContext within a CGContext, but I will experiment more this evening. I'm discovering that drawing attributed text via CTLineDraw has significant limitation, but for my purposes I believe I can live within those

Re: NSInteger

2008-09-03 Thread Nick Zitzmann
On Sep 3, 2008, at 8:58 AM, D.K. Johnston wrote: I'm a bit puzzled by the new NSInteger type. Should I be using this now instead of int? (I'm just as puzzled by NSUInteger, of course.) Yes! Otherwise you'll run into problems if you try to compile your application for 64-bit

Re: utf8 to NSString crasher

2008-09-03 Thread Shawn Erickson
On Tue, Sep 2, 2008 at 8:07 PM, Waqar Malik [EMAIL PROTECTED] wrote: Well I really want to convert wchar_t to NSString, and the only way to convert to NSString was to convert to UTF8 apparently wchar_t-utf8 is converting correctly. Who is creating the wchar_t strings? What encoding is being

Re: [ANN] AppKiDo 0.981, with fixes for Xcode 3

2008-09-03 Thread Buddy Kurz
Many thanks for your continued work on this very useful tool. Can't wait to use the unspeakable platform version. -buddy On Sep 3, 2008, at 7:17 AM, Andy Lee wrote: A new version of AppKiDo is now available at http://homepage.mac.com/aglee/downloads/appkido.html If you're using Xcode 3.x,

Re: Font Color In CTLineDraw?

2008-09-03 Thread Jean-Daniel Dupas
Le 3 sept. 08 à 17:17, Mike Rossetti a écrit : Thanks for clearing that up David. Apparently one cannot open an NSGraphicsContext within a CGContext, but I will experiment more this evening. I'm discovering that drawing attributed text via CTLineDraw has significant limitation, but for

Oracle and Objective C++

2008-09-03 Thread Randy Bradley
I'm having difficulty importing data from an Oracle database into a Cocoa application. I've installed the Oracle client and OCCI examples. The example occidml.cpp seemed to make and run just fine from the command line. Now, I would like to get some data from Oracle into my Cocoa

Re: Message stack limitations

2008-09-03 Thread Michael Ash
On Wed, Sep 3, 2008 at 5:23 AM, RGA [EMAIL PROTECTED] wrote: Putting aside for now whether this is the right way to implement, my question is how are messages processed? Messages are processed using a family of functions called objc_msgSend. You can find declarations and a bit of discussion of

Re: nibless applications

2008-09-03 Thread Michael Ash
On Tue, Sep 2, 2008 at 4:46 PM, David Alter [EMAIL PROTECTED] wrote: I have a situation where it would make a lot of sense to have a nibless application. I think this situation is unique and would suspect that very few people would need to do this. There is some information on how to do this.

Re: utf8 to NSString crasher

2008-09-03 Thread Michael Ash
On Tue, Sep 2, 2008 at 10:29 PM, Waqar Malik [EMAIL PROTECTED] wrote: Is there a canonical way to convert wchat_t to NSString? There isn't, because there is essentially no canonical wchar_t. The only requirements for wchar_t is that it be at least 8 bits wide and that it be compatible with the

Re: utf8 to NSString crasher

2008-09-03 Thread Waqar Malik
Thanks every body for all the help. The issued turned out to the invalid wchar_t string so NSString is returning nil. If NSString can't convert the whole string it returns nil. --Waqar ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please

NSDate autorelease problem

2008-09-03 Thread jeffs87
Hi, I'm trying to calculate the elapsed time by calling this twice and getting the difference. double Seconds() { return [[NSDate date] timeIntervalSince1970]; } This is being called from an audio play back proc which is being called about 100 times a second. I'm getting this error

Re: NSDate autorelease problem

2008-09-03 Thread Jean-Daniel Dupas
Le 3 sept. 08 à 19:02, [EMAIL PROTECTED] a écrit : Hi, I'm trying to calculate the elapsed time by calling this twice and getting the difference. double Seconds() { return [[NSDate date] timeIntervalSince1970]; } This is being called from an audio play back proc which is being called

Re: NSDate autorelease problem

2008-09-03 Thread Jules Colding
On 03/09/2008, at 19.02, [EMAIL PROTECTED] wrote: Hi, I'm trying to calculate the elapsed time by calling this twice and getting the difference. double Seconds() { return [[NSDate date] timeIntervalSince1970]; } There is no need to use cocoa for everything. Use gettimeofday()

Re: NSDate autorelease problem

2008-09-03 Thread j o a r
On Sep 3, 2008, at 10:02 AM, [EMAIL PROTECTED] wrote: I'm trying to calculate the elapsed time by calling this twice and getting the difference. double Seconds() { return [[NSDate date] timeIntervalSince1970]; } How about replacing that with: return [NSDate

Re: NSOutlineView developer example

2008-09-03 Thread Boris Prohaska
So i tried to change te path in the +[FileSystemItem rootItem] method, but this still doesn't work. Has anyone any ideas? Thanks for help Boris Am 03.09.2008 um 17:07 schrieb Boris Prohaska: Hi, try to change the path and look what happens. It does not work. Boris Am 03.09.2008 um 16:49

Re: NSDate autorelease problem

2008-09-03 Thread Gregory Weston
[EMAIL PROTECTED] wrote: I'm trying to calculate the elapsed time by calling this twice and getting the difference. double Seconds() { return [[NSDate date] timeIntervalSince1970]; } This is being called from an audio play back proc which is being called about 100 times a second. I'm

Re: NSDate autorelease problem

2008-09-03 Thread David Duncan
On Sep 3, 2008, at 10:02 AM, [EMAIL PROTECTED] wrote: This is being called from an audio play back proc which is being called about 100 times a second. I'm getting this error message in the log window a whole bunch of times. The audio proc should gives you a time stamp that you can use

Re: NSTableView/NSOutlineView variable row height

2008-09-03 Thread Kevin Meaney
Thanks for this Chris. I'll check it out and let you know how I get on with it. Kevin On 3 Sep 2008, at 03:55, Chris Suter wrote: Hi Kevin, On Tue, Sep 2, 2008 at 3:58 AM, Kevin Meaney [EMAIL PROTECTED] wrote: I feel like I am missing something that should be obvious. Pointers would

Creating a runloop to handle specific mouse events

2008-09-03 Thread Berk Özer
Hi all! At one point, my application blocks the runloop and I have to poll for mouse events by calling [NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:]. I'm not happy with the polling. It seems to me that creating a separate thread and configuring its runloop to process

Disclosure Triangle - how to set Selected programatically?

2008-09-03 Thread Elsa Kahsen
Quick question - how does one set an NSButton of style DisclosureTriangle to selected programatically? Seems like it should be simple but I can't figure out a way. Thanks. Elsa ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post

Setting color of NSPopupButtons

2008-09-03 Thread Elsa Kahsen
Actually I realize I had two questions. Here is my follow up question. How do you set the fore and background colors of NSPopupButtons? -setBackgroundColor doesn't seem to apply to NSPopupButtons. Thanks a lot. Elsa ___ Cocoa-dev mailing list

Linker error: symbol(s) not found

2008-09-03 Thread Joachim
Dear list, I'm getting a linker error, and it's not a missing inclusion of a framework. I suspect it has to do with mixing .m and .mm files, but I'm actually pretty clueless. This is the output from the build: DGBoardRepFromGame(DGGame*, char*), referenced from: -[DGTinyEngine

Re: View animator, how to do explicit animations / animation groups?

2008-09-03 Thread Thomas Engelmeier
Am 03.09.2008 um 17:06 schrieb Matt Long: Are you trying to remove views or animations? Animations are removed from a layer by default which can be overridden in the removedOnCompletion property (in CAAnimation) in an explicit animation. I need some trigger to remove views when their

Re: Linker error: symbol(s) not found

2008-09-03 Thread Julien Jalon
In the header declaring DGBoardRepFromGame, make sure to declare it extern C. #ifdef __cplusplus extern C { #endif extern DGBoardRepFromGame(DGGame*, char*); #ifdef __cplusplus } #endif On Wed, Sep 3, 2008 at 10:40 PM, Joachim [EMAIL PROTECTED] wrote: Dear list, I'm getting a linker error,

Re: Disclosure Triangle - how to set Selected programatically?

2008-09-03 Thread Corbin Dunn
On Sep 3, 2008, at 11:16 AM, Elsa Kahsen wrote: Quick question - how does one set an NSButton of style DisclosureTriangle to selected programatically? Seems like it should be simple but I can't figure out a way. What do you mean by selected? You can call setState: to change the direction

Re: Setting color of NSPopupButtons

2008-09-03 Thread Peter Ammon
On Sep 3, 2008, at 11:19 AM, Elsa Kahsen wrote: Actually I realize I had two questions. Here is my follow up question. How do you set the fore and background colors of NSPopupButtons? -setBackgroundColor doesn't seem to apply to NSPopupButtons. Thanks a lot. What do you mean by

Re: Garbage collection and compiling of non GC framework (MCPKit library)

2008-09-03 Thread Nick Zitzmann
On Sep 3, 2008, at 2:11 PM, matt wrote: Is there any way of using a non GC bundled framework in a GC app? There isn't, sorry. Otherwise... Does anyone have any information on compiling the MCPKit framrwork ? I haven't ever built that framework, but having done some work with GC-

Re: NSString/NSMutable String Concatenation

2008-09-03 Thread Randall Meadows
On Sep 3, 2008, at 3:57 PM, Michael Stearne wrote: I'm new to OS X development and Objective C. I have a NSString (or NSMutableString if that is wiser) and I would like to add text on to the end of it. In PHP it would be something like: $myString=$myString. more stuff; I have looked

Re: Message stack limitations

2008-09-03 Thread Andrew Farmer
On 03 Sep 08, at 02:23, RGA wrote: In trying to get my head around some design patterns for cocoa, I thought about the game of life (eg http://www.bitstorm.org/gameoflife/) . This is where you have a grid of cells, and dependant on the number of live cells around a given cell it dies,

Selection in NSCollectionView

2008-09-03 Thread Rick Mann
I'm making a window similar to IB's Library palette. The middle view is an NSCollectionView, bound to the selection of a tree controller running the top view. It draws fine. However, I don't seem to be able to change the selected item in the collection view. A third view, bound to the

Re: NSOutlineView developer example

2008-09-03 Thread Graham Cox
On 4 Sep 2008, at 3:42 am, Boris Prohaska wrote: but this still doesn't work Define doesn't work. If you expect help you have to be a lot more precise. What errors did you get? What are the symptoms? What have you tried? Remember that no-one is as interested in this problem as you -

Re: Selection in NSCollectionView

2008-09-03 Thread Quincey Morris
On Sep 3, 2008, at 16:05, Rick Mann wrote: However, I don't seem to be able to change the selected item in the collection view. A third view, bound to the NSArrayController that runs the collection view, shows the values in the first object in the collection view. But if I try to click on

cmd+w and File menu

2008-09-03 Thread Wesley Smith
I have an application where I generate a number of the menus from scripts and runtime. Something I noticed when I replace the File menu defined in the app's MainMenu.nib is that I can no longer use cmd+w to close windows. I'm not totally sure why this is. The application loads scripts, which

NSString/NSMutable String Concatenation

2008-09-03 Thread Michael Stearne
Hi. I'm new to OS X development and Objective C. I have a NSString (or NSMutableString if that is wiser) and I would like to add text on to the end of it. In PHP it would be something like: $myString=$myString. more stuff; I have looked around for docs on this but they are confusing (based on

Re: cmd+w and File menu

2008-09-03 Thread Wesley Smith
Hi list, I just realized (after all these years) the File-Close Window was in the File menu. Please ignore my previous post. wes On Wed, Sep 3, 2008 at 2:41 PM, Wesley Smith [EMAIL PROTECTED] wrote: I have an application where I generate a number of the menus from scripts and runtime.

Re: Font Color In CTLineDraw?

2008-09-03 Thread Mike Rossetti
Jean-Daniel, That was it! Thanks a bunch! Mike On Sep 3, 2008, at 10:04 AM, Jean-Daniel Dupas wrote: Create an NSGraphicsContext from you CGContext: + [NSGraphicsContext graphicsContextWithGraphicsPort:flipped:]; Set it as the current context + [NSGraphicsContext setCurrentContext:];

Re: process monitoring panic

2008-09-03 Thread Paul Archibald
I do not have the source code to the subprocess, so I think I will need to find another solution. I can't call setvbuf from my code, can I? I am using the TaskWrapper class from the Moriarity sample for my task handling. It is pretty old, maybe it is not compatible with Leopard or Xcode 3?

NSMatrix mouse puzzle

2008-09-03 Thread D.K. Johnston
I've got a matrix of buttons in a window that I want to disable for a short period, while data is being displayed. So I wrote something like this: [theMatrix setEnabled:NO]; // wait 10 seconds NSUInteger i = 0, resume = time( nil ) + 10; while( i

Re: NSMatrix mouse puzzle

2008-09-03 Thread Graham Cox
On 4 Sep 2008, at 2:40 pm, D.K. Johnston wrote: // wait 10 seconds NSUInteger i = 0, resume = time( nil ) + 10; while( i resume ) index = time( nil ); Don't do this! This is not a good way to wait for a period of time, even if waiting for a