Changing folder attributes

2010-04-26 Thread Reinhard Segeler
Hi, my app creates a folder on a MacServer-Volume (FileSharing), but can't change the attributes of that folder using setAttributes:ofItemAtPath:error: . It always receives the error: You do not have appropriate access privileges to save file. I have read and write previliges to the

Creating temporary NSManagedObjects

2010-04-26 Thread vincent habchi
Hi to all, I need to create a short-lived NSManagedObject; ideally, I'd want it not to be inserted in the Core Data underlying framework, because I need it only during the display of an auxiliary window, and I don't want it saved anyway. I've tried a simple alloc, an alloc and init, but to no

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Jack Nutting
On Mon, Apr 26, 2010 at 10:43 AM, vincent habchi vi...@macports.org wrote: I need to create a short-lived NSManagedObject; ideally, I'd want it not to be inserted in the Core Data underlying framework, because I need it only during the display of an auxiliary window, and I don't want it saved

Re: Creating temporary NSManagedObjects

2010-04-26 Thread vincent habchi
Jack, What you want to do, probably, is create an object that doesn't belong to a context (the context is what ends up saving your object to a data store). You should be able to do something like this: // assuming your app delegate contains the managedObjectModel method, which // the

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread vincent habchi
Le 26 avr. 2010 à 11:04, Jack Nutting a écrit : // assuming your app delegate contains the managedObjectModel method, which // the standard Xcode-generated CoreData app typically does NSManagedObjectModel *managedObjectModel = [[NSApplication delegate] managedObjectModel];

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Vincent I need to create a short-lived NSManagedObject; ideally, I'd want it not to be inserted in the Core Data underlying framework, because I need it only during the display of an auxiliary window, and I don't want it saved anyway. I've tried a simple alloc, an alloc and init, but to

Re: Creating temporary NSManagedObjects

2010-04-26 Thread vincent habchi
Hi Joanna, Do you really need an NSManagedObject? Do you ever need to store instances of this particular class? Yes. That NSObject holds some properties associated with a graphical layer. I have a lot of them, that I classically save in order to be able to restore the state of the

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Vincent Yes. That NSObject holds some properties associated with a graphical layer. I have a lot of them, that I classically save in order to be able to restore the state of the application at launch. Now, to highlight a specific item on a given layer, I create a temporary layer, that I

CoreData validation question

2010-04-26 Thread Arnold Nefkens
Hello list, I have the following validation method, why is it not working? -(BOOL)validateNumberField2:(id *)ioValue error:(NSError **)outError { NSNumber *inputNumberField2 = *ioValue; NSNumber *numberField2Stat = self.numberField2; NSNumber *numberField1Stat =

Re: CoreData validation question

2010-04-26 Thread Steve Bird
On Apr 26, 2010, at 7:51 AM, Arnold Nefkens wrote: Hello list, I have the following validation method, why is it not working? -(BOOL)validateNumberField2:(id *)ioValue error:(NSError **)outError { NSNumber *inputNumberField2 = *ioValue; NSNumber *numberField2Stat =

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread Jack Nutting
On Mon, Apr 26, 2010 at 11:36 AM, vincent habchi vi...@macports.org wrote: By the way, how do you delete these objects with a null MOC, since you are supposed to call [MOC deleteObject:]? Vincent Good question. I believe a simple release/autorelease will do. -- // jack //

Can't drag a custom data object.

2010-04-26 Thread Billy Flatman
Hi all, I'm trying to put a custom object into past board in order to perform a drag operation. It's working fine if I drag a string, but if I try to pass an object, I can't get it to work. - (BOOL)outlineView:(NSOutlineView*)outlineView writeItems:(NSArray*)items

XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't

2010-04-26 Thread Brad Stone
The same code builds fine after a clean all in 3.2.1 and 3.2. In the new version, 3.2.2, it hangs during the build. Here's the sequence: 1) I open the code 2) clean all 3) I build and it hangs (still says Clean succeeded in the bottom right of the window) 4) I force quit and reopen code 5)

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread Joanna Carter
Hi Jack Good question. I believe a simple release/autorelease will do. If the object has been created by inserting into the context, then it would have to be removed from the contrext. Joanna -- Joanna Carter Carter Consulting ___ Cocoa-dev

Re: CoreData validation question

2010-04-26 Thread Arnold Nefkens
Thanks, That was just what I needed. It now works... Thanks again... Sometimes I am a bit lost. Started with iPhone development Obj-C less then three months ago On 26 apr 2010, at 14:15, Steve Bird wrote: On Apr 26, 2010, at 7:51 AM, Arnold Nefkens wrote: Hello list, I have

Re: XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't

2010-04-26 Thread Rui Pacheco
Does it happen with all projects or always the same? If its always the same project try deleting the project folder and checking it out again. On 26 April 2010 14:06, Brad Stone cocoa-...@softraph.com wrote: The same code builds fine after a clean all in 3.2.1 and 3.2. In the new version,

Re: XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't

2010-04-26 Thread Brad Stone
Nope, just this project. I loaded it on a different Mac, same problem and it's OK in 3.2. The thing is I can't even debug it. On Apr 26, 2010, at 9:14 AM, Rui Pacheco wrote: Does it happen with all projects or always the same? If its always the same project try deleting the project

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread Jack Nutting
Hi Joanna, On Mon, Apr 26, 2010 at 3:11 PM, Joanna Carter cocoa...@carterconsulting.org.uk wrote: Good question.  I believe a simple release/autorelease will do. If the object has been created by inserting into the context, then it would have to be removed from the contrext. Joanna

Re: XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't

2010-04-26 Thread John Pannell
Hi Brad I have no solutions, but can confirm that I have the same issue. I've ended up quitting after all cleans, relaunching, and then building (which works, but is clearly a workaround, not a fix). John Positive Spin Media http://www.positivespinmedia.com On Apr 26, 2010, at 7:18 AM, Brad

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread Joanna Carter
Hi Jack Right, but we were talking about passing in nil as the context when creating the object, so there's no context to remove it from. That's interesting. I have never tried using a nil context. Something more to add to my knowledge repository :-) Thank you Joanna -- Joanna Carter

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread Jack Nutting
On Mon, Apr 26, 2010 at 3:46 PM, Joanna Carter cocoa...@carterconsulting.org.uk wrote: Hi Jack Right, but we were talking about passing in nil as the context when creating the object, so there's no context to remove it from. That's interesting. I have never tried using a nil context.

Re: NSApplicationMain question

2010-04-26 Thread Bill Appleton
hi all, thanks for the help! i am making really rapid progress did anyone have some more color on question (2) the need to create a raw NSScroller and control it like a NSSlider (min, max, value, proportion) is that possible? in other words all the shared code for imaging the offset page is

Re: NSApplicationMain question

2010-04-26 Thread Jack Nutting
On Mon, Apr 26, 2010 at 3:51 PM, Bill Appleton billapple...@dreamfactory.com wrote: did anyone have some more color on question (2)  the need to create a raw NSScroller and control it like a NSSlider  (min, max, value, proportion) is that possible? in other words all the shared code for

Re: XCode 3.2.2 Hangs after Clean All but Previous Version Doesn't

2010-04-26 Thread Thomas Clement
On Apr 26, 2010, at 3:06 PM, Brad Stone wrote: The same code builds fine after a clean all in 3.2.1 and 3.2. In the new version, 3.2.2, it hangs during the build. Has anyone else experienced this? It only happens with this code. This is a bug in Xcode. File a bug report. Thomas

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Vincent It would! :) No kidding, I really do not understand what is your dictionary for. You don't have to tell me in French, I hope my English is sufficient, but could you briefly explain me (in five lines or so) what your category is supposed to do? La catégorie rajoute une méthode,

Re: NSApplicationMain question

2010-04-26 Thread Bill Appleton
it needs to look like a scroll bar... is that possible? On Mon, Apr 26, 2010 at 6:54 AM, Jack Nutting jnutt...@gmail.com wrote: On Mon, Apr 26, 2010 at 3:51 PM, Bill Appleton billapple...@dreamfactory.com wrote: did anyone have some more color on question (2) the need to create a raw

Re: NSApplicationMain question

2010-04-26 Thread Graham Cox
On 26/04/2010, at 11:51 PM, Bill Appleton wrote: in other words all the shared code for imaging the offset page is common, i need a scroll bar that behaves like a puppet DOES nothing NSScroller is just a control, it does nothing except tell you its value. While the HIG advises against it,

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread vincent habchi
Le 26 avr. 2010 à 15:50, Jack Nutting a écrit : Well I haven't actually tried it yet, so don't thank me yet! ;) The docs for initWithEntity:insertIntoManagedObjectContext : do include the text If context is not nil, this method... though, which seems to imply that you should be able to send

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Vincent nice, thanks a lot for talking some time explaining me this. De rien. Your French is almost perfect, congratulations!; far superior to my own English. I am glad my lack of skill in technical French didn't get in the way :-) Joanna -- Joanna Carter Carter Consulting

Re: NSApplicationMain question

2010-04-26 Thread Jack Nutting
On Mon, Apr 26, 2010 at 3:56 PM, Bill Appleton billapple...@dreamfactory.com wrote: it needs to look like a scroll bar... is that possible? Ah, no. Of course not, silly me. I worked on a project years ago that had a similar requirement. It used a subclass of NSScrollView, I think, that

Re: NSApplicationMain question

2010-04-26 Thread Paul Sanders
did anyone have some more color on question (2) the need to create a raw NSScroller and control it like a NSSlider (min, max, value, proportion) is that possible? Yes, just instantiate it and call initWithFrame. Then add it to your window's content view, which will retain it so you can

Re: NSApplicationMain question

2010-04-26 Thread Bill Appleton
hi all, so in the NSScroler docs there is no way to set the min, max, and value -- that is the problem there is a way to set the proportion of the page... or am i missing something? thx On Mon, Apr 26, 2010 at 7:06 AM, Paul Sanders p.sand...@alpinesoft.co.ukwrote: did anyone have some

Re: Creating temporary NSManagedObjects (PS)

2010-04-26 Thread vincent habchi
Le 26 avr. 2010 à 15:50, Jack Nutting a écrit : Well I haven't actually tried it yet, so don't thank me yet! ;) The docs for initWithEntity:insertIntoManagedObjectContext : do include the text If context is not nil, this method... though, which seems to imply that you should be able to send

Re: NSApplicationMain question

2010-04-26 Thread Paul Sanders
so in the NSScroler docs there is no way to set the min, max, and value -- that is the problem

Re: Changing folder attributes

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 12:54 AM, Reinhard Segeler wrote: my app creates a folder on a MacServer-Volume (FileSharing), but can't change the attributes of that folder using setAttributes:ofItemAtPath:error: . It always receives the error: You do not have appropriate access privileges to save

Re: Can't drag a custom data object.

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 5:58 AM, Billy Flatman wrote: I'm trying to put a custom object into past board in order to perform a drag operation. You can’t do that, for the same reason you can’t directly write a custom object to a file. The pasteboard basically stores bytes, so it has to be able to

Re: iPad Programming Tutorial

2010-04-26 Thread ML
How about a good book that explains what IB does, how to set delegates, first responders, connect things up, etc I think that misunderstanding prevents me from using IB as much as I really should. - Original Message - From: Matt Moriarity matt.moriarity...@gmail.com To: Rick Mann

[iPhone] Using iPhone's for development

2010-04-26 Thread Dave
Hi All, We are thinking of getting a 2G device to test with, I've seen a few on eBay etc. that say they have been Unlocked and/or Jailbroken. Is it ok to use a phone that has been hacked in this way as a development iPhone? I've had quick look on the net and can't seem to find a

[iPhone] File coping application

2010-04-26 Thread Arun
Hi All Is it possible to copy files form iPhone on to a Mac when iPhone is connected to USB? If so how can we achieve this? Thanks Arun ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to

Re: Changing folder attributes

2010-04-26 Thread Reinhard Segeler
Am 26.04.2010 um 16:36 schrieb Jens Alfke: On Apr 26, 2010, at 12:54 AM, Reinhard Segeler wrote: my app creates a folder on a MacServer-Volume (FileSharing), but can't change the attributes of that folder using setAttributes:ofItemAtPath:error: . It always receives the error: You do

Re: iPad Programming Tutorial

2010-04-26 Thread Klaus Backert
On 26 Apr 2010, at 17:49, David Rowland wrote: On Apr 26, 2010, at 8:15 AM, ML wrote: How about a good book that explains what IB does, how to set delegates, first responders, connect things up, etc I think that misunderstanding prevents me from using IB as much as I really should.

Re: iPad Programming Tutorial

2010-04-26 Thread Henry McGilton
On Apr 26, 2010, at 8:15 AM, ML wrote: How about a good book that explains what IB does, how to set delegates, first responders, connect things up, etc Here is an example of making a (simple) iPhone project all in code: http://www.trilithon.com/download/CodeOnly.zip There is a

Re: 'Build and Analyze' with XCODE 3.2.2

2010-04-26 Thread David Duncan
On Apr 24, 2010, at 1:33 PM, Quincey Morris wrote: Also, you should preferably follow the memory management rules about naming methods. Either autorelease gregorian before releasing it, or put Create somewhere in your method name. FYI Create is for functions, new is for methods. The

Re: iPad Programming Tutorial

2010-04-26 Thread Henry McGilton
On Apr 26, 2010, at 8:49 AM, David Rowland wrote: On Apr 26, 2010, at 8:15 AM, ML wrote: How about a good book that explains what IB does, how to set delegates, first responders, connect things up, etc I think that misunderstanding prevents me from using IB as much as I really

Re: 'Build and Analyze' with XCODE 3.2.2

2010-04-26 Thread Kyle Sluder
On Mon, Apr 26, 2010 at 9:24 AM, David Duncan david.dun...@apple.com wrote: FYI Create is for functions, new is for methods. The analyzer won't recognize one where the other is proper. There are also adornments you can use to override the analyzer's understanding, but I can't recall them

Re: [iPhone] File coping application

2010-04-26 Thread Kyle Sluder
On Mon, Apr 26, 2010 at 9:04 AM, Arun arun...@gmail.com wrote: Is it possible to copy files form iPhone on to a Mac when iPhone is connected to USB? No. --Kyle Sluder ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin

Re: NSTableview background image for column?

2010-04-26 Thread Sean McBride
On Sat, 24 Apr 2010 14:28:02 -0400, Izak van Langevelde said: An NSTableView needs a column with one single image, spanning the entire column. I have got this working by setting as the background colour of the NSTableView a pattern, consisting of the background image, scaled big enough so it

Re: [iPhone] File coping application

2010-04-26 Thread Thomas Engelmeier
On 26.04.2010, at 18:04, Arun wrote: Is it possible to copy files form iPhone on to a Mac when iPhone is connected to USB? If so how can we achieve this? For your personal pleasure: The iPhone is a MTP device, so you can use ImageCapture to copy images from / to your phone. If you don't

Re: [iPhone] File coping application

2010-04-26 Thread Mark Ritchie
Hey! On 26/Apr/2010, at 9:04 AM, Arun wrote: Is it possible to copy files form iPhone on to a Mac when iPhone is connected to USB? That depends on what kind of files! ;-) (Images for example are easily copied.) What are you trying to do? M. ___

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Quincey Morris
On Apr 26, 2010, at 01:43, vincent habchi wrote: I need to create a short-lived NSManagedObject; ideally, I'd want it not to be inserted in the Core Data underlying framework, because I need it only during the display of an auxiliary window, and I don't want it saved anyway. I've tried a

Re: Changing folder attributes

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 9:12 AM, Reinhard Segeler wrote: my app creates a folder on a MacServer-Volume (FileSharing), but can't change the attributes of that folder using setAttributes:ofItemAtPath:error: . It always receives the error: You do not have appropriate access privileges to save

Capturing frames in 64-bits arch

2010-04-26 Thread Ignacio Enriquez
Hi All. I am working with QTKit.framework and I want to make my application works in 64 also. but I am having some troubles when capturing frames in 64bits arch (from iSight). I asked the same question in Quicktime-API list but no luck, so, maybe here I can get some help ;) (

Re: [iPhone] File coping application

2010-04-26 Thread Ricky Sharp
On Apr 26, 2010, at 11:40 AM, Kyle Sluder wrote: On Mon, Apr 26, 2010 at 9:04 AM, Arun arun...@gmail.com wrote: Is it possible to copy files form iPhone on to a Mac when iPhone is connected to USB? No. Just to add though that you _can_ transfer files via WiFi. But of course, only for

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Quincey Notwithstanding the discussion in this thread so far, I don't quite understand why you wouldn't do this the easy way: create a NSManagedObject in your managed context, and delete it when you're done with it. If you are editing a list of objects, using a NSTableView, then one

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Quincey Morris
On Apr 26, 2010, at 11:32, Joanna Carter wrote: If you are editing a list of objects, using a NSTableView, then one reason why you might not want to create temporary objects in the main context is that those objects get displayed in the NSTableView, even though you might not want them to

Re: Capturing frames in 64-bits arch

2010-04-26 Thread douglas welton
Did you try kCVPixelFormatType_48RGB? On Apr 26, 2010, at 1:26 PM, Ignacio Enriquez wrote: Hi All. I am working with QTKit.framework and I want to make my application works in 64 also. but I am having some troubles when capturing frames in 64bits arch (from iSight). I asked the same

Re: Creating temporary NSManagedObjects

2010-04-26 Thread Joanna Carter
Hi Quincey Yes, I remember the discussion about this scenario: when the managed object represents a *future* permanent resident of the Core Data object graph. Outside of a discussion of that scenario, I wouldn't necessarily call this a temporary object. In the OP's scenario, there is no

Re: [iPhone] File coping application

2010-04-26 Thread John Joyce
Subject: Re: [iPhone] File coping application To: Arun arun...@gmail.com Cc: cocoa-dev@lists.apple.com Message-ID: 59e8cb02-f49c-4bfb-bffb-fa4fcfb21...@gmail.com Content-Type: text/plain; charset=us-ascii On 26.04.2010, at 18:04, Arun wrote: Is it possible to copy files form iPhone

Re: Capturing frames in 64-bits arch

2010-04-26 Thread Ignacio Enriquez
Yes I did. It didn't work. I wonder what I am missing. maybe other additional setting? On Tue, Apr 27, 2010 at 4:14 AM, douglas welton douglas_wel...@earthlink.net wrote: Did you try kCVPixelFormatType_48RGB? On Apr 26, 2010, at 1:26 PM, Ignacio Enriquez wrote: Hi All. I am working with

conflict between Core Graphics and NSView graphics

2010-04-26 Thread Bill Appleton
hi all i converted a bunch of quickdraw code to core graphics successfully -- it worked now i am converting a bunch of carbon UI code to cocoa but when I draw text, my fonts are wrong and my font sizes are much too big i am getting the CGContextRef from the NSWindow in the drawRect handler,

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread David Duncan
On Apr 26, 2010, at 12:24 PM, Bill Appleton wrote: but when I draw text, my fonts are wrong and my font sizes are much too big i am getting the CGContextRef from the NSWindow in the drawRect handler, and then setting the CG font and size, etc. like before Try checking the text matrix.

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Aki Inoue
Bill, How are you rendering the text ? We recommend sticking to Cocoa text rendering API in order to support proper Unicode rendering. Thanks, Aki On Apr 26, 2010, at 12:24 PM, Bill Appleton wrote: hi all i converted a bunch of quickdraw code to core graphics successfully -- it worked

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Bill Appleton
hi Aki, i am using CGContextShowGlyphsWithAdvances i have a very large amount of core graphics code, i thought it was compatible with cocoa i see the text in the right spot but the size is gigantic thanks, bill On Mon, Apr 26, 2010 at 12:34 PM, Aki Inoue a...@apple.com wrote: Bill,

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Aki Inoue
OK, sounds like you're being affected by the text matrix. In CG, there are 3 font properties that determine the font rendering: font name, font size, and text matrix. You need to manage all 3. The easiest approach is to use -[NSFont setInContext:] to let the Cocoa object set all 3 properties

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Bill Appleton
thanks all! On Mon, Apr 26, 2010 at 12:50 PM, Aki Inoue a...@apple.com wrote: OK, sounds like you're being affected by the text matrix. In CG, there are 3 font properties that determine the font rendering: font name, font size, and text matrix. You need to manage all 3. The easiest

why doesn't the compiler complain?

2010-04-26 Thread Matt Neuburg
I am so confused about something in Objective-C that I thought was perfectly clear and that I understood perfectly well. Please give me some kind of dope slap to get my brain back on track. The Objective-C docs say: Methods in different classes that have the same selector (the same name) must

Re: why doesn't the compiler complain?

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 1:01 PM, Matt Neuburg wrote: Methods in different classes that have the same selector (the same name) must also share the same return and argument types. This constraint is imposed by the compiler... It's more like should, and the reason is because of the ambiguity of

Re: why doesn't the compiler complain?

2010-04-26 Thread Greg Parker
On Apr 26, 2010, at 1:01 PM, Matt Neuburg wrote: I am so confused about something in Objective-C that I thought was perfectly clear and that I understood perfectly well. Please give me some kind of dope slap to get my brain back on track. The Objective-C docs say: Methods in different

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 12:50 PM, Aki Inoue wrote: In CG, there are 3 font properties that determine the font rendering: font name, font size, and text matrix. You need to manage all 3. Is the text matrix just used for special effects like obliquing? Using it to scale the text could produce

Re: [iPhone] File coping application

2010-04-26 Thread Jens Alfke
Copying files while docked can be done with iPhone OS 3.2 (i.e. on the iPad). This is how you import/export iWork documents, for example, or get PDFs into apps like GoodReader. But it can't be done under control of the app, or even in the Finder — currently the user has to go through a

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Aki Inoue
We always us the text matrix instead of font size. While it is true that the advancements and glyph outline could be affected by the font point size down in the font system, the CG graphics model doesn't work that way. What we recommend is to stick to the Cocoa Text System that tries very hard

NSManagedObject, retain count and dealloc:

2010-04-26 Thread vincent habchi
Hi again, I am unable to see a NSManagedObject go through the dealloc: method, even after its removal from the MOC. It seems these objects are created after a initWithEntity:insertIntoMOC: with an initial retain count of 2, and, of course, it is impossible to make the retain count (by honest

Re: NSManagedObject, retain count and dealloc:

2010-04-26 Thread Sean McBride
On Mon, 26 Apr 2010 23:14:04 +0200, vincent habchi said: I am unable to see a NSManagedObject go through the dealloc: method, even after its removal from the MOC. It seems these objects are created after a initWithEntity:insertIntoMOC: with an initial retain count of 2, and, of course, it is

Re: NSManagedObject, retain count and dealloc:

2010-04-26 Thread Joanna Carter
Hi Vincent I am unable to see a NSManagedObject go through the dealloc: method, even after its removal from the MOC. It seems these objects are created after a initWithEntity:insertIntoMOC: with an initial retain count of 2, and, of course, it is impossible to make the retain count (by

Re: white screen windows at first

2010-04-26 Thread Nick Zitzmann
On Apr 26, 2010, at 3:35 PM, Bill Appleton wrote: when my windows are first shown there is no drawing inside, they are white but when i slowly move the mouse over to the close box and the close box responds to the mouse hover suddenly they draw their content properly does this ring any

Re: white screen windows at first

2010-04-26 Thread Paul Sanders
It sounds like [NSWindow flushWindow] isn't getting called. Nothing is sent to the window server until that happens. In a 'normal' Cocoa app, this is taken care of in the event loop but in your case that evidently isn't happening. It might be good enough just to call it at the end of your

Re: white screen windows at first

2010-04-26 Thread Bill Appleton
they are all in a single thread, but it is like this [NSApplication sharedApplication]; init a bunch of stuff create a bunch of windows and show them [NSApp run]; is this causing the issue? thx bill On Mon, Apr 26, 2010 at 2:40 PM, Nick Zitzmann n...@chronosnet.com wrote: On

Re: white screen windows at first

2010-04-26 Thread Bill Appleton
i added flush window to the drawRect method -- no help it IS calling draw rect right before the window is shown then you see it --- all white thx bill On Mon, Apr 26, 2010 at 2:47 PM, Paul Sanders p.sand...@alpinesoft.co.ukwrote: It sounds like [NSWindow flushWindow] isn't getting

Re: NSManagedObject, retain count and dealloc:

2010-04-26 Thread Kyle Sluder
On Mon, Apr 26, 2010 at 2:14 PM, vincent habchi vi...@macports.org wrote: I am unable to see a NSManagedObject go through the dealloc: method, even after its removal from the MOC. It seems these objects are created after a initWithEntity:insertIntoMOC: with an initial retain count of 2, and,

Re: why doesn't the compiler complain?

2010-04-26 Thread Matt Neuburg
On or about 4/26/10 1:22 PM, thus spake Greg Parker gpar...@apple.com: On Apr 26, 2010, at 1:01 PM, Matt Neuburg wrote: Here's my test: MyClass: - (void) tryme: (NSString*) s; MyClass2: - (void) tryme: (NSArray*) s; MyClass* thing = [[MyClass alloc] init]; NSString* s = @Howdy;

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Mike Abdullah
On 26 Apr 2010, at 20:24, Bill Appleton wrote: hi all i converted a bunch of quickdraw code to core graphics successfully -- it worked now i am converting a bunch of carbon UI code to cocoa but when I draw text, my fonts are wrong and my font sizes are much too big i am getting

-[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController)

2010-04-26 Thread Jack Repenning
One of my testers (and, naturally, none of the test systems I can get my hands on) reports this Console error when performing a certain operation: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController) I think I sorta know what some of it means, but

Re: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController)

2010-04-26 Thread Nick Zitzmann
On Apr 26, 2010, at 5:23 PM, Jack Repenning wrote: One of my testers (and, naturally, none of the test systems I can get my hands on) reports this Console error when performing a certain operation: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class

Re: conflict between Core Graphics and NSView graphics

2010-04-26 Thread Bill Appleton
that CGContextRef is the same as [[thewind graphicsContext] graphicsPort] in the scope if the drawRect routine (i am away from that machine, the code is probably wrong, but you can see what i mean) so the two methods return the same context On Mon, Apr 26, 2010 at 3:58 PM, Mike Abdullah

Re: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController)

2010-04-26 Thread Chris Parker
Hi Jack, On 26 Apr 2010, at 4:23 PM, Jack Repenning wrote: One of my testers (and, naturally, none of the test systems I can get my hands on) reports this Console error when performing a certain operation: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class

Re: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController)

2010-04-26 Thread Jack Repenning
On Apr 26, 2010, at 4:34 PM, Chris Parker wrote: if you're setting the deployment target for the nib correctly then IB should warn you that you're encoding something that 10.4 knows nothing about. Ah, swell ... yet one more spot to configure this. With your help, I found nib info in IB, with

Re: white screen windows at first

2010-04-26 Thread Fritz Anderson
On 26 Apr 2010, at 5:04 PM, Bill Appleton wrote: they are all in a single thread, but it is like this [NSApplication sharedApplication]; init a bunch of stuff create a bunch of windows and show them [NSApp run]; is this causing the issue? What backing type are you setting for

Re: -[NSKeyedUnarchiver decodeObjectForKey:]: cannot decode object of class (NSDictionaryController)

2010-04-26 Thread Chris Parker
On 26 Apr 2010, at 5:03 PM, Jack Repenning wrote: On Apr 26, 2010, at 4:34 PM, Chris Parker wrote: if you're setting the deployment target for the nib correctly then IB should warn you that you're encoding something that 10.4 knows nothing about. Ah, swell ... yet one more spot to

Re: NSApplicationMain question

2010-04-26 Thread Charles Srstka
On Apr 26, 2010, at 9:32 AM, Paul Sanders wrote: If you want to support Tiger, you will have to use the deprecated method. If not, don't. You don’t *have* to use the deprecated method — you can simply test for the OS X version and only use the deprecated method if the version is lower than

question about read-only rule for Memory Management

2010-04-26 Thread Philip Mobley
Assume that an array of images is loaded at the start of the app. There are a number of views which will be displaying multiple copies of the image, but they will be accessing the image array as a read-only property, and I do not plan to have these views adjust the reference count for each

Re: NSApplicationMain question

2010-04-26 Thread Bill Appleton
are you saying there is a way to set the min, max and value on an nsscroller? sorry, not clear on that thx bill On Mon, Apr 26, 2010 at 6:46 PM, Charles Srstka cocoa...@charlessoft.comwrote: On Apr 26, 2010, at 9:32 AM, Paul Sanders wrote: If you want to support Tiger, you will have to

Re: question about read-only rule for Memory Management

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 6:57 PM, Philip Mobley wrote: Question: is the BELOW method named appropriately? - (UIImage *) getImageWithTag:(NSString *)tag; Usually Cocoa method names drop the “get” prefix, so ideally the name would just be “imageWithTag:”. But yes, there’s no need to say “copy”

Re: NSApplicationMain question

2010-04-26 Thread Jens Alfke
On Apr 26, 2010, at 7:13 PM, Bill Appleton wrote: are you saying there is a way to set the min, max and value on an nsscroller? sorry, not clear on that Um, yes; just use the accessors inherited from NSControl. —Jens___ Cocoa-dev mailing list

awakeFromFetch Called Multiple Times

2010-04-26 Thread Milen Dzhumerov
Hi all, I've been under the impression that awakeFromFetch / awakeFromInsert were supposed to be called in pairs with will/didTurnIntoFault (i.e., never have two consecutive awakeX calls). I'm now observing that awakeFromFetch is getting called twice in succession during a context merge and

How to add search filters like those in Finder?

2010-04-26 Thread Maya Trifonova
Hi all, I need to implement add/remove filters for search results like those in Finder with the + and - and save search buttons (Those that appear under the spotlite search field when something is typed in it). When the + button is pushed another filter appears with popup buttons like

Re: iPad Programming Tutorial

2010-04-26 Thread Matt Moriarity
I'm going to have to agree with Rick, IB is the way to go. ___ 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)lists.apple.com

Make About window respond to ⌘W in UI-less app lication

2010-04-26 Thread Michael Dippery
I'm building a Cocoa application that runs as an item in the status bar, and I'm using LSUIElement to prevent the app's icon from appearing in the Dock. This application has an About window and an item to activate that window, using the standard Cocoa mechanism for doing so (that is,

Re: Make About window respond to ⌘W in UI-le ss application

2010-04-26 Thread Kyle Sluder
On Mon, Apr 26, 2010 at 3:21 PM, Michael Dippery mdipp...@gmail.com wrote: Is there a way to get the About window to respond to ⌘W? If you're an LSUIElement app, you don't have a menu bar. Therefore you don't get to respond to menu key equivalents. --Kyle Sluder

Re: How to add search filters like those in Finder?

2010-04-26 Thread Quincey Morris
On Apr 26, 2010, at 04:25, Maya Trifonova wrote: I need to implement add/remove filters for search results like those in Finder with the + and - and save search buttons (Those that appear under the spotlite search field when something is typed in it). When the + button is pushed another

Re: How to add search filters like those in Finder?

2010-04-26 Thread Kyle Sluder
On Mon, Apr 26, 2010 at 4:25 AM, Maya Trifonova psixa...@gmail.com wrote: My question is.. what kind of cocoa UI element is the whole line (with the add/remove buttons and popup buttons) and how should I implement showing and hiding? I couldn't find sample code with similar UI elements. You

  1   2   >