Update to xcode 3.1. copystrings failing, returning error code 71?

2008-12-10 Thread aaron smith
Hey All, I just updated to xcode 3.1. When I make a new project, and try to build and go without even doing anything, I get a build fail. Here's the error: "error: can't execute /Developer/Library/Xcode/Plug-Ins/CoreBuildTasks.xcplugin/Contents/Resources/copystrings (No such file or directory)" "C

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread aaron smith
Thanks Carlos, that should work too. On Wed, Dec 10, 2008 at 6:11 PM, Carlos Eduardo Mello <[EMAIL PROTECTED]> wrote: > Maybe I 'm getting all this wrong, but from everything I read on this > thread, apparently the OP wants to do something simple and is trying to do > more work than necessary: > >

Re: Core Data warning: to-many relation does not have an inverse

2008-12-10 Thread Quincey Morris
On Dec 10, 2008, at 22:36, Nathan Vander Wilt wrote: I'm trying to port my model code to use Core Data. My model is something like this: I have a Company. It has two to-many relationships, currentEmployees and previousEmployees which are naturally both to Employees. Employees have a to-on

Re: Problem setting a Core Data Document Icon

2008-12-10 Thread Nathan Vander Wilt
On Dec 10, 2008, at 5:38 PM, vince wrote: I can't seem to set a default icon for my supported docs in a Core Data project. The .icns file is in my Bundle and placed in the Resources bin. I manually inserted the file name in the Target's Supported Document field. I rebooted my system a few t

Core Data warning: to-many relation does not have an inverse

2008-12-10 Thread Nathan Vander Wilt
I'm trying to port my model code to use Core Data. My model is something like this: I have a Company. It has two to-many relationships, currentEmployees and previousEmployees which are naturally both to Employees. Employees have a to-one relationship to the Company that is the inverse of

efficiency of Xquery vs NSXMLElement attributes

2008-12-10 Thread Kieren Eaton
Hi All I know there are always several ways to do things and have come across something which puzzles me as to the efficiency of these 2 ways of getting the same data from an NSXMLNode object. for this exercise assume theNode is an NSXMLNode object which has been initialized and contains

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Ashley Clark
On Dec 10, 2008, at 8:06 PM, Nick Zitzmann wrote: On Dec 10, 2008, at 6:41 PM, Chunk 1978 wrote: i read in the docs that the use of NSCalandarDate is discouraged because it's going to be depreciated for OS X 10.6... i'm not really sure if depreciated means that any code with NSCalandarDate wil

[MEET] BYU CocoaHeads meeting Thu 12/11

2008-12-10 Thread Dave DeLong
Hey everyone, We're having our monthly meeting tomorrow! However, because it's the end of the semester and most of us are college students swamped with projects, the meeting will be very informal. It'll be open format, so we can talk about anything that you have questions about. If you h

[MEET] CocoaHeads-NYC meeting Thu 12/11

2008-12-10 Thread Andy Lee
The December meeting of CocoaHeads-NYC is Thursday 12/11 from 6:00PM to 8:00PM at Tekserve, at 119 West 23rd between 6th and 7th . Mike Akers will talk about Open Radar. You're encouraged to bring Cocoa programming questions and see if any among us can help. Somet

Re: Wizard development on Mac

2008-12-10 Thread Kyle Sluder
On Wed, Dec 10, 2008 at 10:10 AM, Shraddha Karwan <[EMAIL PROTECTED]> wrote: > I have gone through a number of applications from the Developer > documentation but I was not able to figure out which control to be used to > achieve the above navigation effect. Can any one help me in this? Sounds lik

Re: Undo for non-document based applications

2008-12-10 Thread Graham Cox
On 11 Dec 2008, at 2:53 pm, K. Darcy Otto wrote: I'm trying to get undo working with an application that is not document-based. So far, I think I have got the operation on the stack, but have yet to get the menu reflecting this. What I have so far is the initialisation of undoMan (in ini

Re: how to pass arguments by reference

2008-12-10 Thread Mark Woollard
You can't use passing by reference in C or Objective-C, you can with C+ + or Objective-C 2.0, for example the following will compile: test.mm #import // C++ function int func( int& a ) { return a * 2; } // Objective-C class @interface test : NSObject { } // Method using reference - (int

PAM module

2008-12-10 Thread Macarov Anatoli
How to compile a PAM module? Where to download libpam-dev or files pam_appl.h, libpam.so? I'd like to get PAM module from yubico-pam.c, here what I'm guided by:http://code.google.com/p/yubico-pam/wiki/ReadMe. This is error when compiling: "configure: error: PAM header files not found, install libp

Wizard development on Mac

2008-12-10 Thread Shraddha Karwan
Hi, I have a MS Windows based Application Wizard written in C#. It is a typical Next-Next-Finish types Wizard. I want to develop a similar Application Wizard for Mac OS X 10.5.4. I have gone through a number of applications from the Developer documentation but I was not able to figure out which co

Prolem with CalCalendar programming

2008-12-10 Thread Vijay Kanse
Hello All, I have two problems with calcalendar store framework programming. 1. I need all the event which are present in iCal calendar.Event may be present in year 2025 or 2050. and if the event is recurring then i need only one event. 2. if the event is recurring then i need only one event with

Re: Setting A Background Image On A Window

2008-12-10 Thread Michael Ash
On Wed, Dec 10, 2008 at 4:47 PM, Neil <[EMAIL PROTECTED]> wrote: > I've googled around and poked at the documentation in Xcode, but I can't > seem to find any references to this. I'm trying to do something like > setBackgroundColor, but instead of picking a color, I want to pick an image. > > The

Re: CoreData -- addPersistentStoreWithType crashing [solved]

2008-12-10 Thread Ben Lachman
This was exactly the problem. It should be in the CoreData docs, or better yet caught by the MOM compiler (I suppose GCC/LLVM can't really catch this sort of thing since these are properly formed ObjC classes). Anyway, I spent a ton of time debugging this for it really just being a syntax

Undo for non-document based applications

2008-12-10 Thread K. Darcy Otto
I'm trying to get undo working with an application that is not document-based. So far, I think I have got the operation on the stack, but have yet to get the menu reflecting this. What I have so far is the initialisation of undoMan (in init:), but when I get the operation onto the stack (

Re: Live updating NSPredicateEditorRowTemplate?

2008-12-10 Thread Guy Umbright
As I mentioned, I can get new rows to add with an updated list via the code attached to the OP. The problem is that if I uncomment the "[_editor reloadCriteria];" line the last popup of the initial row doesn't paint and I get the following message in the debug console: "2008-12-10 20:49:41

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Carlos Eduardo Mello
Maybe I 'm getting all this wrong, but from everything I read on this thread, apparently the OP wants to do something simple and is trying to do more work than necessary: "Now what I want to do is show/hide view1/view2 depending on which button you click. What I'm confused about is achieving

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Nick Zitzmann
On Dec 10, 2008, at 6:41 PM, Chunk 1978 wrote: i read in the docs that the use of NSCalandarDate is discouraged because it's going to be depreciated for OS X 10.6... i'm not really sure if depreciated means that any code with NSCalandarDate will no longer function with the new OS or if it will

Re: how to pass arguments by reference

2008-12-10 Thread Peter N Lewis
But the error when compiling is "parse error before & token". Is passing by reference not allowed or is there any other syntax that I should follow? References are a C++ feature. Objective C++ works just fine, but you need to compile as Objective C++ by using an extension of .mm. Since this

Re: The thread that starts by NSTask didn't clear up

2008-12-10 Thread Xianyu Ge
I appreciate that you give me you hand, Thank you very much, I have solved this questions, and I also learn knowledge that NSTask is just a wrapper around execve(), no threading involved. Thanks. 2008/12/10 Etienne Guérard <[EMAIL PROTECTED]> > OK > It seems that in leopard NSTask uses a thread t

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Chunk 1978
i read in the docs that the use of NSCalandarDate is discouraged because it's going to be depreciated for OS X 10.6... i'm not really sure if depreciated means that any code with NSCalandarDate will no longer function with the new OS or if it will just be considered out dated... On Wed, Dec 10, 20

Problem setting a Core Data Document Icon

2008-12-10 Thread vince
I can't seem to set a default icon for my supported docs in a Core Data project. The .icns file is in my Bundle and placed in the Resources bin. I manually inserted the file name in the Target's Supported Document field. I rebooted my system a few times since and still no changes to the newly save

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Ashley Clark
If you save off a starting time object you could use NSDateComponents. NSDate *startDate = /* set at beginning */ NSCalendar *cal = [NSCalendar currentCalendar]; NSCalendarUnit units = NSHourCalendarUnit | NSMinuteCalendarUnit | NSSecondCalendarUnit; NSDateComponents *comps = [cal components

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Nathan Day
You need something like NSLog(@"%.2d Hours, %.2d Minutes and %2d Seconds Remaining", hoursSelected-seconds/3600, (hoursSelected*60-seconds/60)%60, (hoursSelected*3600-seconds)%60 ); On 11/12/2008, at 11:03 , Chunk 1978 wrote: i believe i painted myself into a corner here... i have a NSPop

Re: Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Graham Cox
On 11 Dec 2008, at 11:03 am, Chunk 1978 wrote: i believe i painted myself into a corner here... i have a NSPopUpButton with 3 items. 1 Hour, 2 Hours, 3 Hours. each item has respected tag numbers 1, 2 and 3. i'm attempting to print out time remaining but i can only get as far as displaying se

Countdown With NSTimer - Hours, Minutes, Seconds Remaining?

2008-12-10 Thread Chunk 1978
i believe i painted myself into a corner here... i have a NSPopUpButton with 3 items. 1 Hour, 2 Hours, 3 Hours. each item has respected tag numbers 1, 2 and 3. i'm attempting to print out time remaining but i can only get as far as displaying seconds remaining with this: NSLog(@"%.2d Seconds Re

Re: Starting Cocoa apps from the command line

2008-12-10 Thread Jason Stephenson
Andrew Farmer wrote: I'm not sure, but I can tell you that mplayer does what you're talking about and works fine. You may want to take a look at how they do it. OpenOffice.org, too. It builds an app bundle, etc., using command line tools. It may not be a good place to start, though. It is ab

large texts in NSTextView on 10.4

2008-12-10 Thread Giuseppe Cantavenera
I have to deal with very large texts in a textView , on OS X 10.4. Does anybody now how to implement a subclass of NSLayoutManager that acts like "nonContigousLayout" on 10.5, so to achieve acceptable performance also on 10.4 ? Which methods should I override? Thanks. ___

Re: Problem drawing outside of drawRect: in a custom table cell

2008-12-10 Thread Graham Cox
On 11 Dec 2008, at 3:46 am, Corbin Dunn wrote: There are various reasons why this happens; for one, the focus ring may bleed into the rect that was invalidated. But, as you have noticed, you should not rely on invalidating just a small portion and hoping only that portion should redraw.

Re: How to launch window of the application on clicking of dock icon?

2008-12-10 Thread Ömer Kardaş
You can also use -windowShouldClose event and simply hide your application instead of closing the window. Clicking on the dockicon will simply show it. - (BOOL)windowShouldClose:(id)window { [[NSApplication sharedApplication] hide:self]; return NO; } On Dec 10, 2008, at 7:49

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Ken Thomases
On Dec 10, 2008, at 4:30 PM, aaron smith wrote: "Views don't need to be contained in a window in the nib. You can drag a view from the library directly into the nib. You can then set up outlets from, for example, File's Owner to these views to reference them later in the code." -So, by doing thi

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Brandon Walkin
The NSPanels are unnecessary middle men in your case. Rather than using an NSPanel in order to access its contentView, instead create a new standalone view object in IB by dragging in a custom view from the library to the document window (not the canvas). Then double click the view's icon i

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread aaron smith
Sweet. Thanks Nick! On Wed, Dec 10, 2008 at 2:38 PM, Nick Zitzmann <[EMAIL PROTECTED]> wrote: > > On Dec 10, 2008, at 3:30 PM, aaron smith wrote: > >> -So I would use a separate nib that contains NSPanels, with the views >> layed out in that, load the nib, then attach it's content to the main >> w

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Nick Zitzmann
On Dec 10, 2008, at 3:30 PM, aaron smith wrote: -So I would use a separate nib that contains NSPanels, with the views layed out in that, load the nib, then attach it's content to the main windows content? You don't even need panels; custom views can be placed at the top of a nib. -I did

Re: Starting Cocoa apps from the command line

2008-12-10 Thread Andrew Farmer
On 10 Dec 08, at 13:47, Shayne Wissler wrote: I have a Cocoa application that I am compiling in the traditional UNIX manner using Makefiles and I want to be able to invoke it with command-line arguments and without creating/installing it like traditional OSX apps, as in "x.app/Contents/MacOS/x".

Re: Table view containing cells with both an image and text

2008-12-10 Thread Corbin Dunn
On Dec 10, 2008, at 2:15 PM, Randall Meadows wrote: On Dec 10, 2008, at 2:41 PM, Corbin Dunn wrote: On Dec 10, 2008, at 1:14 PM, Randall Meadows wrote: - the cellFrame passed into -drawInteriorWithFrame:inView: is not really the interior of the frame; I've had to do No; it really is! Yo

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread aaron smith
Hey Ken and Nick, thanks for the feedback. I have continuing questions if you wouldn't mind. "archive them in a nib, load the nib, and then attach them to the window or window's content view." -So I would use a separate nib that contains NSPanels, with the views layed out in that, load the nib, th

Core Data triggering an objc_assign_strongCast crash?!

2008-12-10 Thread Nick Zitzmann
I've suddenly been experiencing a problem where calling - [NSManagedObject validateForDelete:] causes the method to call objc_assign_strongCast, which then mysteriously crashes. The application does not use GC, but the object is properly retained, so it's not that. Has anyone ever seen this

Re: Starting Cocoa apps from the command line

2008-12-10 Thread Sean McBride
On 2008-Dec-10, at 16:47, Shayne Wissler wrote: Is there a way to do this without making some kind of wrapper caller that generates the directory and a script or some such? Or is it wholly frowned upon to do what I'm wanting, and if so, why does it half-work rather than fail with a decent error

Re: Table view containing cells with both an image and text

2008-12-10 Thread Randall Meadows
On Dec 10, 2008, at 2:41 PM, Corbin Dunn wrote: On Dec 10, 2008, at 1:14 PM, Randall Meadows wrote: - the cellFrame passed into -drawInteriorWithFrame:inView: is not really the interior of the frame; I've had to do No; it really is! You're this >< close to convincing me! :) cellFrame.orig

Re: Starting Cocoa apps from the command line

2008-12-10 Thread Steven W Riggins
If you are building a cocoa application, make it a normal cocoa application and use the open command to launch it. On Dec 10, 2008, at 1:47 PM, Shayne Wissler wrote: Is there a way to do this without making some kind of wrapper caller that generates the directory and a script or some such? Or

Re: Starting Cocoa apps from the command line

2008-12-10 Thread Mani Ghasemlou
Unless I misunderstood your situation, I believe using the "open" command should work. Example: open x.app Cheers, Mani On Wed, Dec 10, 2008 at 4:47 PM, Shayne Wissler <[EMAIL PROTECTED]> wrote: > Hello, > > I have a Cocoa application that I am compiling in the traditional UNIX > mann

Re: Setting A Background Image On A Window

2008-12-10 Thread Brandon Walkin
Try making an NSColor from your image using +colorWithPatternImage:, and set that color object on the window using -setBackgroundColor:. On 10-Dec-08, at 4:47 PM, Neil wrote: I've googled around and poked at the documentation in Xcode, but I can't seem to find any references to this. I'm tr

Re: CoreData -- addPersistentStoreWithType crashing

2008-12-10 Thread Melissa J. Turner
Hi Ben - What's the backtrace you get when you crash your application in the debugger? +Melissa On Dec 10, 2008, at 02:58, Ben Lachman wrote: Hi all: I've been making some changes to one of my apps which include a change to the data model. Now whenever I start up the app it crashes (

Starting Cocoa apps from the command line

2008-12-10 Thread Shayne Wissler
Hello, I have a Cocoa application that I am compiling in the traditional UNIX manner using Makefiles and I want to be able to invoke it with command-line arguments and without creating/installing it like traditional OSX apps, as in "x.app/Contents/MacOS/x". When I tried the usual thing that works

Setting A Background Image On A Window

2008-12-10 Thread Neil
I've googled around and poked at the documentation in Xcode, but I can't seem to find any references to this. I'm trying to do something like setBackgroundColor, but instead of picking a color, I want to pick an image. The end goal is to program an emulator for a small medical device like

Re: Table view containing cells with both an image and text

2008-12-10 Thread Corbin Dunn
On Dec 10, 2008, at 1:14 PM, Randall Meadows wrote: On Dec 10, 2008, at 1:41 PM, Corbin Dunn wrote: On Dec 10, 2008, at 11:54 AM, Eric Gorr wrote: I need a column in my NSTableView with cells that contain both an image and some text. My first inclination is to subclass NSCell and have my

Re: Table view containing cells with both an image and text

2008-12-10 Thread Corbin Dunn
Yeah, you are right, that is the case. However, I'd recommend subclassing NSTextFieldCell and having it draw an image. It'll make other stuff work for you automatically (cell expansion tooltips, type selection). See: Interesting. So,

Re: Table view containing cells with both an image and text

2008-12-10 Thread Randall Meadows
On Dec 10, 2008, at 1:41 PM, Corbin Dunn wrote: On Dec 10, 2008, at 11:54 AM, Eric Gorr wrote: I need a column in my NSTableView with cells that contain both an image and some text. My first inclination is to subclass NSCell and have my subclass manage both a NSImageCell and a NSTextField

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Brandon Walkin
Hi, I've released a free plugin for Interface Builder 3 that contains an easy to use tabbed toolbar that should suit your needs. You can grab it here: http://www.brandonwalkin.com/blog/2008/11/13/introducing-bwtoolkit/ Cheers, Brandon On 10-Dec-08, at 3:50 PM, aaron smith wrote: Hey All,

Re: Table view containing cells with both an image and text

2008-12-10 Thread Eric Gorr
On Dec 10, 2008, at 3:41 PM, Corbin Dunn wrote: On Dec 10, 2008, at 11:54 AM, Eric Gorr wrote: I need a column in my NSTableView with cells that contain both an image and some text. My first inclination is to subclass NSCell and have my subclass manage both a NSImageCell and a NSTextFie

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Ken Thomases
On Dec 10, 2008, at 2:50 PM, aaron smith wrote: Hey All, this could be a newbie question, or a somewhat mid-level question. Basically, I don't understand how I can create "views" that aren't associated with an NSWindow, or NSPanel. Here's a breakdown of what I'm trying to accomplish.. -I have a

Re: Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread Nick Zitzmann
On Dec 10, 2008, at 1:50 PM, aaron smith wrote: How do I go about create views separately, and attaching them to the NSWindow, based on the toolbar buttons. Create them programmatically using -initWithFrame:, do any setup work you have to do, then add them as either the content view of a w

Re: Date Formatter year input without year display

2008-12-10 Thread Ashley Clark
On Dec 10, 2008, at 10:48 AM, Paul Bruneau wrote: Hi- I ran into a problem with my production scheduling application as the new year approached. In IB I am using a 10.0 date formatter bound to NSDate properties of a model object. I used: %1m/%1d, %1I:%M%p which gave me something like:

Newbie. Creating SubViews that aren't associated with NSWindow, or NSPanel?

2008-12-10 Thread aaron smith
Hey All, this could be a newbie question, or a somewhat mid-level question. Basically, I don't understand how I can create "views" that aren't associated with an NSWindow, or NSPanel. Here's a breakdown of what I'm trying to accomplish.. -I have a MainMenu nib. -in that it has the usual 1 window.

Re: Table view containing cells with both an image and text

2008-12-10 Thread Corbin Dunn
On Dec 10, 2008, at 11:54 AM, Eric Gorr wrote: I need a column in my NSTableView with cells that contain both an image and some text. My first inclination is to subclass NSCell and have my subclass manage both a NSImageCell and a NSTextFieldCell. Basically, I would imagine would override

Re: Detecting the Enter Key

2008-12-10 Thread Alex Heinz
On Dec 10, 2008, at 2:39 PM, Eric Gorr wrote: On Dec 10, 2008, at 2:28 PM, Michael Ash wrote: On Wed, Dec 10, 2008 at 12:43 PM, Eric Gorr <[EMAIL PROTECTED]> wrote: One way to check to see if the enter key has been pressed is to: [theEvent keyCode] == 0x04C where 0x04C is the keyCode cor

Re: Detecting the Enter Key

2008-12-10 Thread jmunson
I'm certain he means: Physical key: actual key on keyboard that was pressed (may be independent of the letter/word/symbol on the key face) Logical key: this would map to the letter/word/symbol on the key face, regardless of physical placement on the board HTH, Peace, Love, and Light,

Table view containing cells with both an image and text

2008-12-10 Thread Eric Gorr
I need a column in my NSTableView with cells that contain both an image and some text. My first inclination is to subclass NSCell and have my subclass manage both a NSImageCell and a NSTextFieldCell. Basically, I would imagine would override: - (void)drawWithFrame:(NSRect)cellFrame inView

Re: Detecting the Enter Key

2008-12-10 Thread Eric Gorr
On Dec 10, 2008, at 2:28 PM, Michael Ash wrote: On Wed, Dec 10, 2008 at 12:43 PM, Eric Gorr <[EMAIL PROTECTED]> wrote: One way to check to see if the enter key has been pressed is to: [theEvent keyCode] == 0x04C where 0x04C is the keyCode corresponding to the enter key. (Is there an Apple d

Re: Detecting the Enter Key

2008-12-10 Thread Michael Ash
On Wed, Dec 10, 2008 at 12:43 PM, Eric Gorr <[EMAIL PROTECTED]> wrote: > One way to check to see if the enter key has been pressed is to: > > [theEvent keyCode] == 0x04C > > where 0x04C is the keyCode corresponding to the enter key. > (Is there an Apple defined constant for this key code?) > > > >

Re: how to pass arguments by reference

2008-12-10 Thread Clark S. Cox III
C, and by extension Objective-C, do not have references in the C++ sense. You'll have to pass a pointer to the thing that you want your method to be able to modify. Sent from my iPhone On Dec 10, 2008, at 7:43, Nick Rogers <[EMAIL PROTECTED]> wrote: Hi, I have the following in my .m file:

Re: Distributing apps

2008-12-10 Thread Volker in Lists
Hi, when you build your app in Xcode with the Release target setting, you will get your app with the standard app icon in the build folder. This folder usually resides within your project directory. Via the targets Get Info panel you can set app icon - which you have to supply yourself, t

Re: Distributing apps

2008-12-10 Thread Benjamin Dobson
On 10 Dec 2008, at 18:15:51, Richard S. French wrote: I have found a lot of Cocoa books and tutorials about writing applications. I haven’t found any instructions as to how to put that application into an icon that can be run when clicked on your desktop or downloaded by others. Please le

Distributing apps

2008-12-10 Thread Richard S. French
I have found a lot of Cocoa books and tutorials about writing applications. I haven¹t found any instructions as to how to put that application into an icon that can be run when clicked on your desktop or downloaded by others. Please let me know if I¹ve missed it. Thanks, Richard. __

Re: Multithreading and Mach ports

2008-12-10 Thread John Love
Reference: http://developer.apple.com/documentation/Cocoa/Conceptual/Multithreading/RunLoopManagement/chapter_6_section_5.html#/ /apple_ref/doc/uid/1057i-CH16-SW7 While I'm trying to piece your replies together, I have a quick question .. reference Listing 5-15 and, in particular, the

Re: Searchable persistent file reference

2008-12-10 Thread Gary L. Wade
An alias stores quite a bit of information in it to allow you to find a file object (files, folder, disks) if it moves or is renamed or if any of the elements of its path is renamed, and can usually work with varied file systems. I am not familiar with BSAlias or NDAlias, but if they provide a goo

Re: Detecting the Enter Key

2008-12-10 Thread Benjamin Dobson
I would go for the second one. I would guess that the second one would pick up all the various Enter keys, whereas the first would only pick up a single key. The second also looks much more elegant to me. I do not have any experience with this; I am merely saying what looks best from my poi

Re: Detecting the Enter Key

2008-12-10 Thread Ken Thomases
On Dec 10, 2008, at 11:43 AM, Eric Gorr wrote: One way to check to see if the enter key has been pressed is to: [theEvent keyCode] == 0x04C where 0x04C is the keyCode corresponding to the enter key. (Is there an Apple defined constant for this key code?) kVK_ANSI_KeypadEnter but it's only d

Detecting the Enter Key

2008-12-10 Thread Eric Gorr
One way to check to see if the enter key has been pressed is to: [theEvent keyCode] == 0x04C where 0x04C is the keyCode corresponding to the enter key. (Is there an Apple defined constant for this key code?) Another way, found at: http://developer.apple.com/samplecode/TrackBall/listing9.html

Re: How Can I Notify DrawRect Method?

2008-12-10 Thread jmunson
You both have valid points. However, I think you are missing something. That something being the overall "goal" of the application as predicated by that never-ever-returns: Time. That goal can be multi-faceted. For example, one item in the overall list is "target platform." By decidi

Re: NSOutlineView problem with Text cells.

2008-12-10 Thread Corbin Dunn
On Dec 10, 2008, at 9:09 AM, Arun wrote: Hi I have an App in which i use NSOutlineView in the left hand side for Navigational controls. The Root and child's have text cells. I am have changed the font size for the texts in the text cells. After this the text in the cells are not aligned. Th

Re: How Can I Notify DrawRect Method?

2008-12-10 Thread Michael Ash
On Wed, Dec 10, 2008 at 7:05 AM, I. Savant <[EMAIL PROTECTED]> wrote: > On Dec 9, 2008, at 10:32 PM, Michael Ash wrote: > >> This is a common response whenever I talk about not optimizing where >> it's not useful. But the thing is, trying to optimize every little >> thing makes your app *slower*. >

NSOutlineView problem with Text cells.

2008-12-10 Thread Arun
Hi I have an App in which i use NSOutlineView in the left hand side for Navigational controls. The Root and child's have text cells. I am have changed the font size for the texts in the text cells. After this the text in the cells are not aligned. The leave a lot of space in the bottom and looks a

NSView subviews mutability - follow up to NSDictionary mutability test thread

2008-12-10 Thread jonat...@mugginsoft.com
A follow up of sorts to Cocoabuilder - ([EMAIL PROTECTED]) NSDictionary mutability test from Cocoabuilder - (Bill Bumgarner) Re: NSDictionary mutability test Performance An NSMutableDictionary instance can be returned from a method declared as returning (NSDictionary*) without risk that the

Date Formatter year input without year display

2008-12-10 Thread Paul Bruneau
Hi- I ran into a problem with my production scheduling application as the new year approached. In IB I am using a 10.0 date formatter bound to NSDate properties of a model object. I used: %1m/%1d, %1I:%M%p which gave me something like: 12/23, 12:30PM This was used mostly for display, bu

Re: Problem drawing outside of drawRect: in a custom table cell

2008-12-10 Thread Corbin Dunn
On Dec 10, 2008, at 2:44 AM, Graham Cox wrote: I need to draw outside of the usual drawRect: method (no really, I do!) The reason is that I have a custom cell that is used in a table/ outline view that draws a colour swatch. When clicked it pops up a menu of colours so the user can choose

Re: Depressed, Etched Style For Toolbar?

2008-12-10 Thread Mike Abdullah
Look at the various NSToolbar methods with "select" in their name. Search around with those for examples. On 10 Dec 2008, at 16:21, Chunk 1978 wrote: when validating a toolbar item, how do i call this style? (see image attached) ___ Cocoa-dev mai

Re: Wake up Reason

2008-12-10 Thread Derek Chesterfield
From my system.log: Dec 1 08:20:49 kernel[0]: USB caused wake event (EHCI) I assume different wake events are also logged. On 10 Dec 2008, at 11:11, sheen mac wrote: Is it possible to know the reason the MacBook wake from sleep? ___ Cocoa-dev ma

RE: how to pass arguments by reference

2008-12-10 Thread Stefan Sinclair
While I'm not sure if the GCC objective-C compiler accepts C++ references (I've never tried), one quick & easy thing to double check is that your source file is a ".mm" file as opposed to a ".m" file, so that the C++ compiler will be used as opposed to the C compiler. -Stefan> From: [EMAIL PR

NSTextField setStringValue not updating properly

2008-12-10 Thread jmunson
Namaste! I've written a simple interface for ICA as part of my application. In that interface I have an NSTextField which holds a default path & filename. Next to that field I have an NSButton for changing that information. It opens an NSSavePanel. I also have a Preview button that grabs t

Depressed, Etched Style For Toolbar?

2008-12-10 Thread Chunk 1978
when validating a toolbar item, how do i call this style? (see image attached) <>___ 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)li

Re: Return Control To Next Active App Without Hiding?

2008-12-10 Thread Benjamin Dobson
I haven't tested this, but could you use [NSApp deactivate];? On 10 Dec 2008, at 09:22:18, Chunk 1978 wrote: the closest thing i've come to being able to bring front the most recent app is using this: [NSApp hide:self]; [NSApp unhideWithoutActivation]; but that flashes my app, and kinda look

Re: how to pass arguments by reference

2008-12-10 Thread James Montgomerie
What you're looking to do is a C++ism, it's not available in Objective- C; there's no explicit support for pass by reference. It's certainly possible to achieve the same ends though. For primitive types, you'll have to pass a pointer. Declare the method as taking, for example 'int *' if yo

Re: how to pass arguments by reference

2008-12-10 Thread jmunson
is this: (*int) the same as: (int *) ? I've always seen (int *) as the declaration... Quoting Dave DeLong <[EMAIL PROTECTED]>: Spoke too soon... whoops. Put an asterisk before the type, indicating that the type is going to come in as a pointer to the data and not the actual data. Then wh

Re: how to pass arguments by reference

2008-12-10 Thread Dave DeLong
This is what I get for typing in an email window and not a code editor... - (void) foo:(int*)bar { (*bar)++; } Dave On Dec 10, 2008, at 8:54 AM, Dave DeLong wrote: - (void) foo:(*int)bar { (*bar)++; } ___ Cocoa-dev mailing list (Cocoa-dev@li

IB Scroll View position problem

2008-12-10 Thread Randy Bradley
I have two scroll views in my application, each with a table view, in addition to a bunch of other items. Everything is locked to the upper left corner of the window view. When the window is resized, I would like the scroll views to expand and shrink along with the window. The smaller scrol

Re: Custom NSTableView cells

2008-12-10 Thread René v Amerongen
On 10 dec 2008, at 02:40, Graham Cox wrote: I could use a little guidance, please, on customizing cells for display in an NSTableView. My table has but one column, but each cell in that column is made up of 2 or more views. I think I have what I need as far as the cells go, but it's fee

Re: how to pass arguments by reference

2008-12-10 Thread Dave DeLong
Spoke too soon... whoops. Put an asterisk before the type, indicating that the type is going to come in as a pointer to the data and not the actual data. Then when you call the method, you use the ampersand to pass a pointer to your data, like so: (in some class definition somewhere. A

Re: how to pass arguments by reference

2008-12-10 Thread Ken Thomases
On Dec 10, 2008, at 9:45 AM, Dave DeLong wrote: Put the & before the variable type: - (UInt32) traverseTreeStraightReturnedDirection: (&int)treeDirection... I haven't tried that, but it doesn't look right. It doesn't correspond to any C or C++ syntax I've ever seen. On Dec 10, 2008, a

Re: how to pass arguments by reference

2008-12-10 Thread Nick Rogers
Hi, thanks for the reply. Now I have: - (UInt32)traverseTreeStraightReturnedDirection:(&int)treeDirection returnedTreeDepth:(&int)treeDepth returnedKey:(&HPlusCatalogKey)catKey lookForKey:(HPlusCatalogKey)l

Re: how to pass arguments by reference

2008-12-10 Thread Dave DeLong
Put the & before the variable type: - (UInt32) traverseTreeStraightReturnedDirection:(&int)treeDirection... HTH, Dave On Dec 10, 2008, at 8:43 AM, Nick Rogers wrote: Hi, I have the following in my .m file: - (UInt32)traverseTreeStraightReturnedDirection:(int&)treeDirection

Re: Very odd issue when try to implement the drag and drop functions for NSOutlineview

2008-12-10 Thread chaitanya pandit
Hi, This was a reply that i posted recently for a similar question, i think you are missing step 2 To re-order the items in the tableView, you will have to implement a custom drag type. Say for example you name your custom drag type as @"myDragType" then 1] Register your table view to accep

how to pass arguments by reference

2008-12-10 Thread Nick Rogers
Hi, I have the following in my .m file: - (UInt32)traverseTreeStraightReturnedDirection:(int&)treeDirection returnedTreeDepth:(int&)treeDepth returnedKey:(HPlusCatalogKey&)catKey lookForKey:(HPlusCatalogKe

Very odd issue when try to implement the drag and drop functions for NSOutlineview

2008-12-10 Thread Alex . Wang
Hi, everyone. Currently I am working on a project which uses the NSOutlineview heavily. I thought the drag and drop functions are very important, so I am trying to implement that. However, after refer to some tutorials, I still can't make it work... My steps are : 1. create a controller to manage t

Re: Problem drawing outside of drawRect: in a custom table cell

2008-12-10 Thread Graham Cox
On 11 Dec 2008, at 1:23 am, Erik Buck wrote: You don't have to draw outside of -drawRect:. Instead of invalidating the table, just call -setNeedsDisplayInRect: or - displayInRect: and pass only the rect of the row that needs to be redrawn. Thanks - I'm well aware of how that works. The

Re: Searchable persistent file reference

2008-12-10 Thread matt . gough
On 10 Dec 2008, at 14:59, Ben wrote: I am trying to store a reference to a file in a database, such that if the file moves, I can still search for it in my database. I have read up on the Carbon Alias Manager and the third party BSAlias/NDAlias classes but none of these quite seem to fit the

  1   2   >