Re: ScreenSaverView gets instantiated several times

2009-10-04 Thread Michael Babin
On Oct 4, 2009, at 7:14 PM, Gabriel Zachmann wrote: I've been hunting a bug in my screen saver for several hours, until I've found out the following shocking fact (I think). When the user clicks 'Test' in System Preferences, it "just" creates a new instance of your subclass of ScreenSaverVi

ScreenSaverView gets instantiated several times

2009-10-04 Thread Gabriel Zachmann
I've been hunting a bug in my screen saver for several hours, until I've found out the following shocking fact (I think). When the user clicks 'Test' in System Preferences, it "just" creates a new instance of your subclass of ScreenSaverView! (This can have a major impact on your system des

Re: iPhone NavController within TabBarController (nested table views)

2009-10-04 Thread Luke Hiesterman
Yes, you need a nav controller to be the view controller for one of your tabs. This case is explicitly covered in the iPhone programming guide at developer.apple.com. Check it out. Luke Sent from my iPhone. On Oct 4, 2009, at 3:27 PM, Trygve Inda wrote: My root view is a TabBarControll

Re: Address Book-style editing

2009-10-04 Thread Kyle Sluder
On Thu, Oct 1, 2009 at 10:21 AM, Brad Gibbs wrote: > I'm trying to re-create Address Book's editing style - if a user pushes a > button labeled Edit, subsequent clicks on a label bring up what looks like a > separate view for the new information.  Clicking return after editing > commits the edit a

Re: Address Book-style editing

2009-10-04 Thread Brent Gulanowski
The usual trick is to put a temporary editable text field on top of your text view. Otherwise you would have to re-implement everything from scratch. I heard there might be a class which uses the text field overlay trick in Omni's frameworks but I could be mistaken. On Thu, Oct 1, 2009 at 1:21 PM,

Re: Clickable URLs in a UITextView

2009-10-04 Thread Brent Gulanowski
I think you have to use a UIWebView. On Sun, Oct 4, 2009 at 11:08 AM, DKJ wrote: > I've subclassed a UITextView, and I want it to display clickable URLs. I > put the URL string in the view using its drawRect: method. But when the view > is displayed, the URL isn't clickable. Here's the code I'm

iPhone NavController within TabBarController (nested table views)

2009-10-04 Thread Trygve Inda
My root view is a TabBarController with three tabs. Each one gets its view from a different nib and all is well... The tab controller handles the load/unload as the user clicks the tabs. One of these tabs has a tableview in it's view. I would like to add a second table that is accessed by clicking

Re: rangeOfString & UTF8 - SOLVED

2009-10-04 Thread Steve Cronin
Clark; OK thanks for the whack on the head… I had managed to convince myself that there was something about the utf8 umlats and all that I wasn't understanding … No the problem was simply that there was a trailing space at the end of tString -> 'Geschäftsführer (CEO) ' Thanks for your ti

Re: Checking whether a file is a genuine PDF file

2009-10-04 Thread Paul M
On 5/10/2009, at 4:12 AM, Sherm Pendley wrote: On Sun, Oct 4, 2009 at 8:07 AM, Squ Aire wrote: How can I check whether a file is indeed a true PDF file (that can be, for example, opened in Preview)? Would I be able to filter true PDFs file in an open dialog, or would I just have to stick to

Re: rangeOfString & UTF8

2009-10-04 Thread Clark Cox
On Sun, Oct 4, 2009 at 1:48 PM, Steve Cronin wrote: > Folks; > >  (thePhrase) :  Geschäftsführer (CEO): > >  (tString):  Geschäftsführer (CEO) > > Both >        curPos = [thePhrase rangeOfString: tString > options:NSCaseInsensitiveSearch].location; > > AND > >        NSLocale *tLocale = [[[NSLocal

rangeOfString & UTF8

2009-10-04 Thread Steve Cronin
Folks; (thePhrase) : Geschäftsführer (CEO): (tString): Geschäftsführer (CEO) Both curPos = [thePhrase rangeOfString: tString options:NSCaseInsensitiveSearch].location; AND NSLocale *tLocale = [[[NSLocale alloc] initWithLocaleIdentifier:@"de_DE"] autorelease]; curPos = [thePhrase r

Re: Core-data binding to all entities

2009-10-04 Thread Brent Gulanowski
On Fri, Oct 2, 2009 at 2:39 AM, Martin Hewitson wrote: > Dear list, > > I have a simple core-data model with an entity 'Category' and an entity > 'Note'. The 'Category' entity has a to-many relationship 'notes' to entity > type 'Note'. > > The categories are displayed in an outline view via a tree

Re: whether to use core data... [SOLVED]

2009-10-04 Thread Colin Howarth
Thanks, Brent, Jeffrey, I.S. and everyone else. My apologies to the list for the inappropriateness of my light-hearted initial post. I'm sure that Core Data isn't really as bad (to learn) as it might initially seem. I am equally sure that 'The Documentation' could be improved - but then

Re: whether to use core data...

2009-10-04 Thread Brent Gulanowski
The best way to learn all this stuff is a step at a time. On Sat, Oct 3, 2009 at 11:14 AM, Colin Howarth wrote: > This is a long (but witty and interesting) rambling post about design, > apple documentation, learning Obj-C & Cocoa and so on. > > > I'm writing a raytracing / lens design program.

Re: whether to use core data...

2009-10-04 Thread Chris Hanson
On Oct 4, 2009, at 10:39 AM, Jeffrey Oleander wrote: >> It's not a toy language or API by any stretch of the >> imagination. > > But Core Data seems to be. Please expand on this, and why you feel it to be the case. A great many people are using Core Data successfully in their applications on b

Re: whether to use core data...

2009-10-04 Thread Jeffrey Oleander
> >> Anyway, I ended up with a graph of Objects and > methods which looks nice and consistent and -- clean!  > :-) > > I'm happy with my model. And I'm certain it would benefit > from Core Data. > > > A1: A lot of beginners complain about this. A lot of > intermediate to pros recognize that the do

Re: main nib, firing a secondary nib and it's controller....

2009-10-04 Thread jon
thanks, as a follow up, is this the proper way to create and open the instance? (also globally, so it can be used in other parts of the app?) can this be improved on? (starting up a window Controller object and it's xib file) thanks for the suggestion. -Jon. I also need to deallocated

Re: Bundle is not using icon or CFBundleIdentifier

2009-10-04 Thread Timothy Reaves
On Oct 4, 2009, at 12:35 AM, Todd Heberlein wrote: Anyone want to point out what I'm doing wrong? Any help appreciated. I think I had to do a Project->Add To Project... and then select the icon file in order to get the icon to be used. Dragging the icons into my project didn't do the t

Re: Checking whether a file is a genuine PDF file

2009-10-04 Thread Sherm Pendley
On Sun, Oct 4, 2009 at 8:07 AM, Squ Aire wrote: > > I know that, in an open dialog for example, I can view all PDF files by just > filtering using the "pdf" file extension. But that isn't good enough really, > because a file can have the pdf extension without being a true PDF file. >From /usr/s

Clickable URLs in a UITextView

2009-10-04 Thread DKJ
I've subclassed a UITextView, and I want it to display clickable URLs. I put the URL string in the view using its drawRect: method. But when the view is displayed, the URL isn't clickable. Here's the code I'm using: - (id)initWithFrame:(CGRect)frame { if (self = [super initWithFrame:fr

Checking whether a file is a genuine PDF file

2009-10-04 Thread Squ Aire
I know that, in an open dialog for example, I can view all PDF files by just filtering using the "pdf" file extension. But that isn't good enough really, because a file can have the pdf extension without being a true PDF file. How can I check whether a file is indeed a true PDF file (that can

Re: converting a NSView into an NSImage, when scaling via scaleUnitSquareToSize [SOLVED, kinda]

2009-10-04 Thread Martin Redington
Well, I seem to be able to get the image with the following (where scale is the absolute scale of the view, implemented in the category defined at http://developer.apple.com/mac/library/qa/qa2004/qa1346.html) This still feels wrong (note the use of frame instead of bounds for drawRect call), and I