Command line tool using NSImage?

2010-08-21 Thread Jaime Magiera
Hello, I've got a OSX command line tool that I wish to run in a shell and via a WebObjects application. The binary tool is linked to a framework I wrote which contains NSImage manipulations. It seems the [NSApplication sharedApplication] trick isn't working. I'm still getting... Aug 21 02:56:

Re: Command line tool using NSImage?

2010-08-21 Thread Ken Thomases
On Aug 21, 2010, at 2:26 AM, Jaime Magiera wrote: > I've got a OSX command line tool that I wish to run in a shell and via a > WebObjects application. The binary tool is linked to a framework I wrote > which contains NSImage manipulations. It seems the [NSApplication > sharedApplication] trick

Re: Core Animation. issue with scaling

2010-08-21 Thread Ahsan Shafiq
Yes, you are right but now I am unable to handle touches. As I said in my previous post, I also want to update the model. Simply scaling as you mentioned does scale down or scale up the sublayers as well but how to update the model. In Scaling both the position and bounds get changed!! and after an

Re: CoreAnimation - Resizing sublayers along with superlayer animation

2010-08-21 Thread Ahsan Shafiq
Hi You can use scale, but if you also want to detect touches on these layers you have to update the model as well which is nearly impossible to do if you are doing scalling. But apart from this scaling will work just fine. On Fri, Aug 20, 2010 at 3:54 AM, Ignacio Enriquez wrote: > Hi, > > I have

Re: [iPhone] How to change Default.png Image Dynamically

2010-08-21 Thread Tharindu Madushanka
Hi, But it seems like iPhone Phone app has some different Default.png images.. When you exit from Keypad menu.. it will load one image.. When you exit from other tabs, Default image is some other.. Is it possible to do similar thing ??? Keeping several Default images.. Thanks and Kind Regards,

Re: [iPhone] How to change Default.png Image Dynamically

2010-08-21 Thread Ricky Sharp
On Aug 21, 2010, at 7:39 AM, Tharindu Madushanka wrote: > But it seems like iPhone Phone app has some different Default.png images.. > When you exit from Keypad menu.. it will load one image.. > > When you exit from other tabs, Default image is some other.. Is it possible > to do similar thing ?

iOS and Oracle Databases

2010-08-21 Thread Stefan Nobis
Hi. A customer is interested in utilizing the iPad. One feature request is to get direct access to the in-house Oracle database (via VPN). I searched a little bit but was unable to find any useful information. Therefore I assume something like the Oracle Client package or just liboci oder somethin

Re: [iPhone] How to change Default.png Image Dynamically

2010-08-21 Thread Tharindu Madushanka
Hi, ah. ok. Yep. I realized that in iOS4. Then it's an OS feature.. Thanks a lot. I was confused with that :) Tharindu ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to the list. Contact

Re: Command line tool using NSImage?

2010-08-21 Thread Jaime Magiera
On Aug 21, 2010, at 5:33 AM, Ken Thomases wrote: > In short, you can't reliably use AppKit (including NSImage) from a daemon or > remote shell. Thanks for the link. Interesting read. In short, that's really a bummer. It totally negates a chunk of functionality from my framework. I'll have to

Re: Core Data Lightweight Migration Woes

2010-08-21 Thread Jack Nutting
On Fri, Aug 20, 2010 at 8:46 PM, Brad Gibbs wrote: > I highlighted the .xcdatamodel and did a Design > Data Model >  Add New > Version.  That created the Config.xcdatamodeld with an unnumbered version of > the datamodel (Config.xcdatamodel) and a numbered copy named Config > 2.xcdatamodel. > I go

Re: Core Data Lightweight Migration Woes

2010-08-21 Thread Brad Gibbs
Well, that's the way I started doing things, but, on pages 130-131 of the book More iPhone 3 Development (written by Dave Mark & Jeff LaMarche -- your co-authors for Learn Cocoa on the Mac) make a point of saying that the new version is the unnumbered version. In some ways, I wouldn't think it

app with quick-entry dialog

2010-08-21 Thread Martin Hewitson
Dear list, I'm building an app which supports a quick-entry dialog triggered by a global hot-key so that the user can make entries while working in another app. I have this all working fine except for one thing. When the quick-entry dialog is dismissed, the main app window is made active, and e

Re: [iPhone] How to change Default.png Image Dynamically

2010-08-21 Thread Michael Ash
On Sat, Aug 21, 2010 at 8:39 AM, Tharindu Madushanka wrote: > Hi, > > But it seems like iPhone Phone app has some different Default.png images.. > When you exit from Keypad menu.. it will load one image.. > > When you exit from other tabs, Default image is some other.. Is it possible > to do simil

NSMatrix selectedRow, selectedColumn

2010-08-21 Thread koko
Below is the implementation of an NSMatrix subclass. What I do not understand is the NSLog output from -mouseDown. No matter which cell I click I always get the following, i.e row and column are always -1. 2010-08-21 11:16:48.705 Customize It[965:813] mouse down 2010-08-21 11:16:48.706 Custo

Re: NSMatrix selectedRow, selectedColumn

2010-08-21 Thread Graham Cox
On 21/08/2010, at 7:19 PM, k...@highrolls.net wrote: > - (void)mouseDown:(NSEvent *)theEvent { > > > NSLog(@"r %d c %d", [self selectedRow], [self selectedColumn]); > } Since you've completely overridden the standard -mouseDown: event handling, NSMatrix is unable to process the click i

Re: Command line tool using NSImage?

2010-08-21 Thread Alastair Houghton
On 21 Aug 2010, at 14:35, Jaime Magiera wrote: > On Aug 21, 2010, at 5:33 AM, Ken Thomases wrote: > >> In short, you can't reliably use AppKit (including NSImage) from a daemon or >> remote shell. > > Thanks for the link. Interesting read. > > In short, that's really a bummer. It totally negat

Re: Command line tool using NSImage?

2010-08-21 Thread Ken Thomases
On Aug 21, 2010, at 8:35 AM, Jaime Magiera wrote: > Has anyone heard of Apple coming up with a solution to this conundrum? Or is > it Bug Report time? There has to be some way to do it securely. What exactly are you trying to do? For some tasks, there may be a safe mechanism. For example, are

Re: NSMatrix selectedRow, selectedColumn

2010-08-21 Thread koko
Do I have egg on my face or what ... thanks Graham On Aug 21, 2010, at 11:37 AM, Graham Cox wrote: On 21/08/2010, at 7:19 PM, k...@highrolls.net wrote: - (void)mouseDown:(NSEvent *)theEvent { NSLog(@"r %d c %d", [self selectedRow], [self selectedColumn]); } Since you've completel

warning: initialization from distinct Objective-C type

2010-08-21 Thread koko
How should I make the assignment to 'fm' below to get rid of this warning? warning: initialization from distinct Objective-C type /* drawWithFrame:inView */ - (void)drawInteriorWithFrame:(NSRect)cellFrame inView:(NSView *)controlView { FramesMatrix* fm = controlVi

Re: app with quick-entry dialog

2010-08-21 Thread Michael Ash
On Sat, Aug 21, 2010 at 12:16 PM, Martin Hewitson wrote: > Dear list, > > I'm building an app which supports a quick-entry dialog triggered by a global > hot-key so that the user can make entries while working in another app. I > have this all working fine except for one thing. When the quick-en

Re: Core Animation. issue with scaling

2010-08-21 Thread Eric Wing
On 8/21/10, Ahsan Shafiq wrote: > Yes, you are right but now I am unable to handle touches. > As I said in my previous post, I also want to update the model. Simply > scaling as you mentioned does scale down or scale up the sublayers as well > but how to update the model. In Scaling both the posit

Re: warning: initialization from distinct Objective-C type

2010-08-21 Thread Jean-Daniel Dupas
Le 21 août 2010 à 23:52, k...@highrolls.net a écrit : > How should I make the assignment to 'fm' below to get rid of this warning? > > warning: initialization from distinct Objective-C type > > > > /* drawWithFrame:inView */ > - (void)drawInteriorWithFrame:(NSRect)cellFrame inView:(NSView *)c

[iPhone] NSPredicate formatting questions

2010-08-21 Thread Sandro Noël
Greetings. i'm trying to set a predicate to query some deep object in my model. my model is as so. member is part of a category the category has a name. while in a member resultset i want to filter the content on category names. [NSPredicate predicateWithFormat:@"(caregory.name IN %@)",[selec

bind:toObject:withKeyPath:options: being called twice

2010-08-21 Thread Charles Srstka
My custom view implements -optionDescriptionsForBinding: as follows: - (NSArray *)optionDescriptionsForBinding:(NSString *)binding { NSMutableArray *descs = [NSMutableArray arrayWithArray:[super optionDescriptionsForBinding:binding]]; if([binding isEqualToStr

Re: [iPhone] NSPredicate formatting questions

2010-08-21 Thread Wyatt Webb
On Aug 21, 2010, at 3:40 PM, Sandro Noël wrote: > while in a member resultset i want to filter the content on category names. > > [NSPredicate predicateWithFormat:@"(caregory.name IN %@)",[selections > objectForKey:kPredicateFieldNamesArray]]; > > I crash with: > 'unimplemented

Re: [iPhone] NSPredicate formatting questions

2010-08-21 Thread Sandro Noël
Oh my god, I feel ashamed... that's what I get for working late. I'm sorry. On 2010-08-21, at 11:38 PM, Wyatt Webb wrote: > > On Aug 21, 2010, at 3:40 PM, Sandro Noël wrote: > >> while in a member resultset i want to filter the content on category names. >> >> [NSPredicate predicateWithForm

Re: [iPhone] NSPredicate formatting questions

2010-08-21 Thread Wyatt Webb
On Aug 21, 2010, at 9:15 PM, Sandro Noël wrote: > Oh my god, I feel ashamed... > that's what I get for working late. > > I'm sorry. No worries. It happens to us all. Better than chasing it for another couple of hours!___ Cocoa-dev mailing list (Coco

Making an NSMethodInvocation from the current method

2010-08-21 Thread Roland King
Is there a built-in function to make an NSMethodInvocation from 'the current method I'm in with all current parameters', or does anyone have any code they've written to do this? Motivation, I'm writing a display class which can get updated from a background thread, it has a whole load of metho

Re: Making an NSMethodInvocation from the current method

2010-08-21 Thread Tony Romano
Use GCD. dispatch_sync(dispatch_get_main_queue(), ^{ // Call your function here MyFunction (param 1, param2, ...); }); Tony Romano http://www.cocoaegghead.com On Aug 21, 2010, at 10:03 PM, Roland King wrote: Is there a built-

Formatting float numbers

2010-08-21 Thread Adriano Brandão
Hi, I'm having some troubles in formatting float numbers. If I wish to display 25.342 using only 2 decimal places I could use %.2f and it would do the job. But if the number to be formatted is flat (like 25.000) I get 25.00 as a result. After a little bit of research I found out that I could use

Re: Getting Source List font sizes right

2010-08-21 Thread Markus Müller
Are you setting a custom cell? maybe you have to check in SourceView if they´re using another fontsize (check in IB). Regards, Markus Am 06.08.10 23:33, schrieb Rick Mann: I've got half a source list working, using Leopard's support. However, I can't get the section title font size correct,

Re: Problems with NSCell setObjectValue

2010-08-21 Thread Hrishikesh Murukkathampoondi
>The 'dataCellForTableColumn:...' delegate method is intended to return a data >cell for the >table column to use>, but *not* to configure the cell value for >the specific row it's going >to represent. Remember that the object val>ue >comes from the data source object, not the del>egate object,

Re: Problems with NSCell setObjectValue

2010-08-21 Thread Quincey Morris
On Aug 21, 2010, at 23:24, Hrishikesh Murukkathampoondi wrote: >> The 'dataCellForTableColumn:...' delegate method is intended to return a >> data cell for the >table column to use>, but *not* to configure the cell >> value for the specific row it's going >to represent. Remember that the >> obj