Re: Creating a tiled image from resource images

2009-10-30 Thread I. Savant
On Oct 30, 2009, at 2:27 PM, Michael Abendroth wrote: i would like to (programmatically) create a tiled image from resource images I created. I will have to use 9 tiles to create the image I want. I think I read somewhere that some methods exist in Cocoa that make this very easy, but I cannot

Re: Cocoa bindings problem

2009-10-30 Thread I. Savant
On Oct 30, 2009, at 3:01 PM, Squ Aire wrote: Thanks for the tip. However, the value transformer idea did not work. Even though it ended up showing exactly the same date (the value transformer just strips the time from the date) for each row, selecting multiple rows still leaves us with

Re: Seemingly Documentation confusion?

2009-10-29 Thread I. Savant
On Oct 29, 2009, at 7:58 AM, Michael de Haan wrote: In NSDraggingDestination Protocol Reference (informal protocol), it states: ... The methods ( which include ) - prepareForDragOperation: required method - performDragOperation: required method -

Re: Binding To Array Controller From A Different XIB?

2009-10-29 Thread I. Savant
On Thu, Oct 29, 2009 at 1:07 PM, Chunk 1978 chunk1...@gmail.com wrote: i've created an NSMenuItem in the MainMenu.xib that targets an action in a different XIB thru the first responder.  the action removes an object from the array.  however, i'd like to binn the NSMenuItem object to the array

Re: Binding To Array Controller From A Different XIB?

2009-10-29 Thread I . Savant
On Oct 29, 2009, at 1:57 PM, Quincey Morris wrote: The natural mechanism for controlling the appearance of such a menu item (including its text, its check mark and its enabled state) is to use interface validation (validateUserInterfaceItem: or validateMenuItem:) in each possible

Re: Software visualisation tool

2009-10-28 Thread I. Savant
On Oct 28, 2009, at 10:20 AM, MacProjects wrote: Pardon for being a bit off-cocoa-topic, but thought this is a good place to ask. You thought a Cocoa development list with strict topic rules was a good place to post questions about which visualization applications are best? Come

Re: keyPathsForValuesAffectingValueForkey: not updating immediately

2009-10-27 Thread I. Savant
On Oct 26, 2009, at 10:03 PM, Brad Gibbs wrote: I did read the documentation, which is why I used +keyPathsForValuesAffectingFullAddress. I also tried +keyPathsForValuesAffectingValueForFullAddress: Both methods work, but only after changing the view and then coming back to it. Read

Re: Make a solid line look like 3D

2009-10-26 Thread I. Savant
On Oct 26, 2009, at 12:44 PM, Matthias Arndt wrote: For some reasons I still don't understand (Argh!) the drawRect: method of my view didn't pass the right rectangle to the object actually responsible for the drawing. I just fixed the code to aim for the best performance improvement: Don't

Re: Make a solid line look like 3D

2009-10-26 Thread I. Savant
On Oct 26, 2009, at 1:10 PM, Jean-Daniel Dupas wrote: What do you expect as rectangle ? drawRect: parameter is the smaller rectangle that contains all rect marked as dirty. If you want to exact list of dirty rects, you can query it using the -getRectsBeingDrawn:count: methods. This is

Re: keyPathsForValuesAffectingValueForkey: not updating immediately

2009-10-26 Thread I. Savant
On Oct 26, 2009, at 9:07 PM, Brad Gibbs wrote: I have a Core Data app with a category on a model object, Address. The category has a method to return a fullAddress property, which is composed of the streetAddress, city, state and zipCode. Did you read the documentation for this method?

Re: Make a solid line look like 3D

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 2:42 PM, Matthias Arndt wrote: My code draws lines some thousand times with different angles. I'd like to have the lines to look similar to 3D objects. So currently I draw each line segment three times: 1. one time with a thick line in black 2. the second time with a

Re: Make a solid line look like 3D

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 5:44 PM, Matthias Arndt wrote: Thanks for your response. I'm nearly convinced to look into the gradients tomorrow, although I'm afraid it won't result in a better performance: Empty the path, calculate the angle, create the rect (with rounded edges), apply the gradient

Re: Is there a cocoa treeview?

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 6:49 PM, Gevik wrote: Coming from .NET, I was wondering if there is anything like a TreeView control in Cocoa? NSOutlineView? -- I.S. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin

Re: Make a solid line look like 3D

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 7:22 PM, Graham Cox wrote: screensavers should be low impact - personally, if a screensaver uses more that about 10-15% cpu, I'll ditch it imediately Really? It's not as if your computer has anything better to do. Again: battery. Many of us are laptop users. The OP

Re: Make a solid line look like 3D

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 7:48 PM, I. Savant wrote: Quincey's suggestion to cache is right on the money: draw it with bezier paths once, then only display the finished product as PDF data. You could even separate it out into different 'overlays' for each 'thread file'. That minimizes any

Re: Make a solid line look like 3D

2009-10-25 Thread I. Savant
On Oct 25, 2009, at 8:00 PM, Graham Cox wrote: But caching to a bitmap of some kind is a much bigger win, provided you do it at the scale you need to draw it at (and recache if that scale changes). Using CGLayer can generate really big speedups, so that's worth looking into, but even the

Re: Hiding tab view items

2009-10-21 Thread I. Savant
On Oct 21, 2009, at 9:03 AM, BareFeet wrote: [tabView removeTabViewItem:oldItem] But isn't that going to destroy the tab item, the view it contains, and everything in that view? Can I get it back when that tab view item is valid again, or do I have to programmatically create all the

Re: Sending a Selector to another Class.

2009-10-21 Thread I. Savant
On Oct 21, 2009, at 12:23 PM, Joshua Garnham wrote: How would I send a Selector to another class? I know to send it to a selector in the same file you do [self performSelector:@selector(doSomething)]; and for sending it to another class I've tried [otherClass

Re: Curious about SSH -- actually about: Keychain -- (passive aggressive)

2009-10-19 Thread I. Savant
On Oct 19, 2009, at 8:32 AM, Stuart Malin wrote: What you perceived as passive aggressive is... I.S.'s style, which, if you were a regular reader of the list, you'd be familiar with; a style that (I suspect) ameliorates his frustration and enables him to answer yet-once-again a query that

Re: Calculating a total from a collection of numeric attributes

2009-10-18 Thread I. Savant
On Oct 17, 2009, at 7:40 PM, Ian Piper wrote: I have a Core Data entity that has an attribute called charge (stored as a float). So I am storing a number of records each of which has a charge. I simply want to be able to show a running total of charges as I add or remove items. I was

Re: Curious about SSH

2009-10-18 Thread I. Savant
On Oct 18, 2009, at 11:26 AM, Brent Smith wrote: Is there a certain class or framework that people are using to store Keychain Information? Yes. Apps like Coda, and Transmit, and Versions that store passwords, how do they add them to Apples Keychain access, for use with apps like

Re: NSCollectionView issues

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 10:32 AM, Half Activist wrote: I'm using a NSCollectionView to display a stack of items (a table) but since what's display is far too complex to be laid out programmatically I went for the NSCollectionView. And it's been all problems from the beginning. Yes,

Re: NSCollectionView issues

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 11:42 AM, Jim Turner wrote: If you need to get the ViewItem for a specific index (available via NSCollectionView's itemAtIndex: under 10.6) Bah - I failed to notice -itemAtIndex: is also 10.6-only. I mostly agree with the train wreck sentiment. The 10.5

Re: Extract plain text content from a Text View

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 3:37 PM, Ian Piper wrote: Is there a way to get the plain text content out of an NSTextStorage object (displaying using a Text View) that contains rich text and images? An NSTextStorage is a subclass of NSMutableAttributedString, which is a subclass of

Re: Extract plain text content from a Text View

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 3:44 PM, I. Savant wrote: I want to figure out a way to build a search predicate that will allow me to search a Text View and I think this is likely to be the only way. Seems a bit odd. Could you elaborate? Let *me* elaborate on *that*. :-) You normally use

Re: File Encryption / Decription

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 10:05 PM, Chunk 1978 wrote: what is the best way to encrypt and then decrepit a file in Cocoa? I suppose you could burn the encrypted file to a disk then neglect said disk. Bit rot would make the file quite decrepit. ;-) But seriously folks*, there are a few

Re: Slider with tag?

2009-10-16 Thread I. Savant
On Oct 16, 2009, at 10:33 PM, Sean McBride wrote: On 10/14/09 10:24 PM, Gabriel Zachmann said: Could someone please explain to me how I can present a little tag to the user that moves along with a slider's handle (above or below), in which I can give some feedback to the user about the

Re: Examples of MVC pattern with Core Data

2009-10-14 Thread I. Savant
On Oct 14, 2009, at 11:29 AM, Kyle Sluder wrote: On Oct 14, 2009, at 7:03 AM, Darren Wheatley dar...@tenjinconsulting.co.uk wrote: I've been Googling and searching the XCode docs for good examples of using the MVC pattern with Core Data, but not had a lot of success. Because MVC is so

Re: SelectedRowIndexes

2009-10-14 Thread I. Savant
On Oct 14, 2009, at 11:55 AM, gMail.com wrote: Oh, come on, at least pick a witty pseudonym. :-D when I call [tableView selectedRowIndexes]; I always get a indexSet already sorted by row. Instead I need to sort it as the selection order. I mean, if the user selected the rows in the order

Re: Safari problem

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 9:54 AM, fawad shafi wrote: i am developing an application in which i need that System permanently disables/hides the status bars at the top and bottom of safari for the duration of session. They do not reappear at any point. ' If you're really trying to show/hide the

Re: Core Data with OpenGL

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 9:58 AM, Erik Buck wrote: I think that the Core Data model and any generated classes should be left untouched because you may want to regenerate the classes later. I use Categories to add View specific drawing methods to the objects that represent Core Data entities.

Re: Preserving camelCase when prefixing a method name?

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 10:24 AM, Graham Cox wrote: I think just making the first character uppercase would be sufficient, but I'm not sure how to do that reliably with the unichar data type, so that's my first question. Why not replace the first character with an upper-case version

Re: Adding 'Help' to your App.

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 12:37 PM, Joshua Garnham wrote: Just wondering if there is some documentation on how to add 'help' to your app. You're just wondering? Seriously? How about SEARCHING, then? -- I.S. ___ Cocoa-dev mailing list

Re: arrayWithContentsOfFile

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 2:43 PM, DKJ wrote: I'm using this code to read an array from a plist: NSArray *data = [NSArray arrayWithContentsOfFile:[NSHomeDirectory() stringByAppendingPathComponent:@/Documents/file.plist]]; The docs say this method returns nil when the file doesn't exist

Re: arrayWithContentsOfFile

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 2:54 PM, Jens Alfke wrote: The docs say it returns nil if the file doesn't exist, and he's getting an empty array. That was his question. ... You must have misread his code — he's using NSHomeDirectory() as a prefix. My apologies, you're absolutely right. I read that

Re: arrayWithContentsOfFile

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 3:08 PM, DKJ wrote: I looked in the directory itself before running the code, and the plist files weren't there at all. Let me see if I understand what you're saying: You are expecting there to be *no* PLIST files (and so, you expect to get nil) but are getting an

Re: arrayWithContentsOfFile

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 3:23 PM, DKJ wrote: On 2009-10-13, at 12:12 , I. Savant wrote: Let me see if I understand what you're saying: You are expecting there to be *no* PLIST files (and so, you expect to get nil) but are getting an empty array? Bingo. Again, can you post your relevant

Re: arrayWithContentsOfFile

2009-10-13 Thread I. Savant
On Oct 13, 2009, at 3:52 PM, DKJ wrote: NSArray *data; data = [NSArray arrayWithContentsOfFile:[NSHomeDirectory() stringByAppendingPathComponent:@/Documents/file.plist]]; if( data == nil ) do this; There's no

Re: More Core Data Questions

2009-10-12 Thread I. Savant
On Oct 12, 2009, at 3:31 PM, Jon Hull wrote: 1) Can I count on a to-many relationship keeping the order of the managedObjects it points to? The order is very important in this case, and I need a way to ensure that the order does not change when the object is saved and reloaded. No.

Re: Core Data with OpenGL

2009-10-12 Thread I. Savant
On Oct 12, 2009, at 4:27 PM, Ben Trumbull wrote: but in this case it must draw itself. No, it doesn't must do anything. Views draw themselves, model objects are state, and controllers are intermediaries. ... What problem are you trying to solve by knowingly violating the MVC design

Re: More Core Data Questions

2009-10-12 Thread I. Savant
On Oct 12, 2009, at 4:32 PM, Jon Hull wrote: I have spent the last 48 hours (re)reading core data docs. My head is swimming in docs. Understandable. It's a complicated technology (especially when you consider its interaction with Bindings). The short answer is yes, I understand to

Re: Newbie Core Data question.

2009-10-11 Thread I. Savant
On Oct 11, 2009, at 6:00 AM, Gustavo Pizano wrote: but I can't set the Key Model and key path to something to work.. Let's forget about the drag and drop part for now and simplify the problem. You said earlier: I have a window with 2 custom views, each view with their corresponding

Re: Newbie Core Data question.

2009-10-11 Thread I. Savant
On Oct 11, 2009, at 9:20 AM, Gustavo Pizano wrote: Thanks for the link, I will then see the example and try to understand these bindings better, I thought they were something similar as in WO-EOF, but its seems lot of things changed here. You might want to search the list archives for

Re: NSCollectionView delegate methods aren't called

2009-10-11 Thread I. Savant
On Oct 11, 2009, at 3:28 PM, Rick Mann wrote: I'm trying to implement drag drop in my NSCollectionView, following the 10.6 release notes. I've got my delegate set, but nothing was happening. I then implemented each of the methods to see if any were called, and none are. I've verified that

Re: real verses Virtual memory

2009-10-10 Thread I. Savant
On Oct 10, 2009, at 3:35 PM, Thomas Wetmore wrote: Please take this off list. That's an awfully presumptuous demand, don't you think? It's a relevant and interesting Cocoa topic. I've been following it with interest and it's quite obvious others have as well. -- I.S.

Re: Hide an Item on Desktop

2009-10-09 Thread I. Savant
On Oct 8, 2009, at 9:18 PM, M Pulis wrote: Please do not advise this hack. It is not supported by the Finder. Wrong. -- I.S. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or moderator comments to

Re: Hide an Item on Desktop

2009-10-09 Thread I. Savant
On Oct 9, 2009, at 2:00 AM, M Pulis wrote: Following trends, it is easy to imagine a future Desktop becoming an increasingly protected space. One thing I have learned in 25 years is never underestimate Apple's ability to change and force our world to recompile. 10.6 just killed off an

Re: debugging cursors

2009-10-08 Thread I. Savant
On Oct 8, 2009, at 4:50 PM, David M. Cotter wrote: Really?? does nobody know how to do this? Likely not, because you're not explaining why. You mention changed the cursor out from under me ... is this because you're having some problem in your app or do you really want to try changing

Re: debugging cursors

2009-10-08 Thread I. Savant
On Oct 8, 2009, at 5:02 PM, David M. Cotter wrote: sorry, yes. when the user types a number in a box and presses enter, i create a cursor based on that number and set it. one second later, without any of my code running, the OS seems to change the cursor to an arrow. i want to find out

Re: debugging cursors

2009-10-08 Thread I. Savant
On Oct 8, 2009, at 7:01 PM, David M. Cotter wrote: Read the documentation i have extensively read the documentation tell us what you tried (preferably by posting your code), and we might be able to help. i told you: i set the cursor in response to the user pressing enter after editing a

Re: Hide an Item on Desktop

2009-10-08 Thread I. Savant
On Oct 8, 2009, at 7:24 PM, Maggie Zhang wrote: Does anyone know if it's possible to programmatically hide an single item (e.g. a file or a mounted disk or a directory) from the Desktop? Rename it so that it starts with a period. Dot-files are hidden. -- I.S.

Re: Hide an Item on Desktop

2009-10-08 Thread I. Savant
On Thursday, October 8, 2009, Ken Thomases k...@codeweavers.com Well, there's also the hidden bit in the file's metadata.  It's accessible a number of ways: I thought I read somewhere that this isn't always honored. At the least it's not supported on all file systems, I don't believe. Cant

Re: whether to use core data...

2009-10-03 Thread I. Savant
On 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. [ big, massive, much-needed snip ] FOCUS!!! I get that you're trying to be witty, but I was forced to skim

Re: reading (parsing) CSV (or Excel) data

2009-10-02 Thread I. Savant
On Oct 2, 2009, at 6:34 AM, Mike Abdullah wrote: inefficient due to its use of NSMutableCharacterSet. Could you expand on this? Once created and manipulated, what makes it slow for string scanning compared to NSCharacterSet? I hadn't heard this. -- I.S.

Re: reading (parsing) CSV (or Excel) data

2009-10-02 Thread I. Savant
On Oct 2, 2009, at 7:42 AM, Mike Abdullah wrote: While using this code in an experimental project I found the app was routinely using 500+ MB of RAM. When measured with Instruments I realised that every time you use a character set for string scanning, Foundation internally copies it,

Re: reading (parsing) CSV (or Excel) data

2009-10-02 Thread I. Savant
On Oct 2, 2009, at 4:03 PM, Colin Howarth wrote: CSV isn't *that* hard to parse, once you know about quotes and NLs inside cells. ... and encodings and line endings. Don't forget how much goodness Cocoa gives you automagically. :-) -- I.S.

Re: reading (parsing) CSV (or Excel) data

2009-10-02 Thread I. Savant
On Oct 2, 2009, at 4:15 PM, Alex Kac wrote: Here is something I use that has worked for me fairly well. I found it either on this list or somewhere on the web, so sharing back to the list. http://pastie.org/639863 This appears to be the code listing from the article I mentioned on

Re: reading (parsing) CSV (or Excel) data

2009-10-02 Thread I. Savant
On Oct 2, 2009, at 4:19 PM, Alex Kac wrote: Yes! In any case, I'm sure libcsv is more powerful and correct, but the category there worked for my purposes working with several cloud services. You need only address quoted fields, line breaks within fields, respect character encodings,

Re: NSValueTransformer problem with NSTextField update

2009-10-01 Thread I. Savant
Paul: On Oct 1, 2009, at 8:49 AM, Paul Bruneau wrote: But when I use the transformer on a regular NSTextField, I don't get that benefit. It properly transforms the value and the correct value gets stored in my model, but the reverse transformation doesn't fire like it does when used in

Re: NSValueTransformer problem with NSTextField update

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 10:58 AM, Paul Bruneau wrote: Thanks for the suggestion, IS. I had in fact tried those and I tried them again just now (in all combinations), no change. Hmmm ... This (figure 2):

Re: NSValueTransformer problem with NSTextField update

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 1:02 PM, Paul Bruneau wrote: Well if you look at Figure 2, step #23, it says Updated value now stored in model object. Key-value observing notifications are sent to observers of this model property. So due to the binding, the text field would get updated by this

Re: NSValueTransformer problem with NSTextField update

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:26 PM, Paul Bruneau wrote: I just thought of something IS said earlier: Thing is, aside from transformed values, the value that makes it to the model layer is usually a direct reflection of what was just set in the view. :-) In 99% of cases, this would seem a waste of

Re: Bad stardardUserDeafaults

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:32 PM, Jacob Schwartz wrote: So I have a code segment that turns an NSString that is a file path on my computer into an NSURL, archives the NSURL into NSData, and then puts that into a NSMutableDictionary to be saved in the standardUserDefaults. I can archive and

Re: Provisioning Question

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:38 PM, Bob Barnes wrote: I've generated the appropriate certificates and created a provisioning profile (development) that is generic, i.e., uses the wild-card character This has nothing to do with Cocoa, specifically. I think you might have better luck using the

Re: Bad stardardUserDeafaults

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:49 PM, Jacob Schwartz wrote: I didn't post it right away in case this was a common mistake That's the problem. If you think about it, how can we know what kind of mistake it was without seeing what you actually did? :-) -- I.S.

Re: Weird NSToolbar glitch

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:40 PM, Bryan Matteson wrote: OK, it's solved now. Turns out NSToolbar does not like being on two windows at the same, Hah. No, definitely not. :-D Window - Toolbar ... always. You'll never have Window - Toolbar or Window - Toolbar. I thought

Re: Provisioning Question

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 3:59 PM, Bob Barnes wrote: Yes, I realize it's off-topic and I did try to post on the iPhone development forum, but I keep getting an error trying to create an account. I mean no disrespect, but if you know it's off-topic, why post? In any case, if you're having

Re: Weird NSToolbar glitch

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 4:01 PM, Bryan Matteson wrote: I couldn't find it anywhere in the documentation. But the thing is, it doesn't seem like you can even move a toolbar from one window to another, even properly making sure that it never belongs to more than one at a time, without getting

Re: NSValueTransformer problem with NSTextField update

2009-10-01 Thread I. Savant
On Oct 1, 2009, at 4:38 PM, Paul Bruneau wrote: I do have 20ish edit fields to contend with on my main window. I could set up a preference to let the user select his preferred entry method (there are just 2), but I still think I would still have the trouble with the inconsistent updating

Re: Does Core Data have reserved Entity names?

2009-09-30 Thread I. Savant
On Sep 30, 2009, at 3:53 AM, Alex Reynolds wrote: After I added an Entity called Object, I get the following message when executing my application on the iPhone: objc[4219]: Class Object is implemented in both /usr/lib/ libobjc.A.dylib and /var/mobile/Applications/BFDFC14C-DB60-44BB-8118-

Re: Does Core Data have reserved Entity names?

2009-09-30 Thread I. Savant
On Sep 30, 2009, at 1:11 PM, Alex Reynolds wrote: Unfortunately, that simple solution means parting ways with the naming scheme of the source I'm pulling data from and changing the naming scheme for all my other entities/classes, too, which I was hoping to avoid. But thanks to all for the

Re: Efficient searching of an NSArray of NSDictionary

2009-09-29 Thread I. Savant
On Sep 29, 2009, at 10:38 AM, Pascal Harris wrote: My current method is to iterate through the array, searching for a match for a particular key. I suspect that there may be a faster way - but I cannot find a tutorial (especially since all the example code seems to have gone AWOL in Snow

Re: Efficient searching of an NSArray of NSDictionary

2009-09-29 Thread I. Savant
On Sep 29, 2009, at 12:53 PM, Oftenwrong Soong wrote: IIUC, what you're saying is that NSPredicate is used as a filter. Is that correct? Well, it's more of a (unit of a) query. You can create compound predicates, etc. to build a more complex query. If so, is Predicate Editor (in IB)

Re: Efficient searching of an NSArray of NSDictionary

2009-09-29 Thread I. Savant
On Sep 29, 2009, at 12:53 PM, Oftenwrong Soong wrote: is Predicate Editor (in IB) related in some way? And if so, what is it supposed to do? By the way, a quick google search of, nspredicateeditor example yields a very helpful first result ... -- I.S.

Re: Best way to implement drag and drop for multiple types of nstableview

2009-09-25 Thread I. Savant
On Sep 25, 2009, at 9:25 AM, Paul Bruneau wrote: I have used mmalc's DNDArrayController class from his Bookmarks example code to implement drag and drop for one of my NSTableViews. Of course it works great. But now I would like to set up a couple other table views with other types of

Re: CoreData Mysterious Conditional Data Loss

2009-09-24 Thread I. Savant
On Sep 24, 2009, at 8:38 AM, Milen Dzhumerov wrote: Hi all, I'm experiencing the weirdest conditional data loss that I've seen in a long time. One of my managed objects has an NSImage property (stored as Transformable). Now here's the bug in summary: If the app bundle which initially

Re: CoreData Mysterious Conditional Data Loss

2009-09-24 Thread I. Savant
On Sep 24, 2009, at 9:59 AM, Milen Dzhumerov wrote: You got it right first time, many thanks. The images were created using NSImage's initByReferencingFile: which I presume only references the image file. That's what I thought at first (that CoreData stored the path to the image within the

Re: Subview drawn with reverted order

2009-09-24 Thread I. Savant
On Sep 24, 2009, at 8:36 PM, Jens Alfke wrote: Overlapping sibling views aren't really supported in AppKit. No longer true as of Leopard. -- I.S. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or

Re: Populating TableView Via Button.

2009-09-18 Thread I. Savant
On Sep 18, 2009, at 9:34 AM, Philip Juel Borges wrote: Does anyone know how you'd populate a tableview when clicking a button? Nope. That kind of high-tech stuff is beyond any Cocoa developer. ;-) I tried this: -(void)populateTableView:(id)sender { [super init]; ...

Re: Reliable way to find out if CoreData finished loading

2009-09-18 Thread I. Savant
On Sep 17, 2009, at 6:46 PM, Mantas Masalskis wrote: I'm loading Core Data object via Managed Object Context in IB. It looks like it hasn't finished loading when applicationDidFinishLoading is fired. Perhaps thinking about this a different way would clarify things. You don't load a

Re: Upgrading NSDocument format, best practice

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 9:52 AM, Markus Spoettl wrote: I have an NSDocument that reads old-format files which it does no longer write. When loading such an old format file, the app warns the user about the format-change and the fact the file can't be read by older versions once saved with

Re: Upgrading NSDocument format, best practice

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 10:15 AM, I. Savant wrote: In my opinion, you're on the right track. I think the simplest solution is to create a new file extension. Forget renaming the file - a different extension implies a different format. Doing this gives you all the mechanisms and warnings

Re: Upgrading NSDocument format, best practice

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 10:28 AM, Markus Spoettl wrote: Better, yes, though I haven't had many problems understanding the first version either. You mustn't be too hard on yourself. Hard on myself? Nah. I was laughing at myself. :-) It was particularly funny when an angry person who shall go

Re: Upgrading NSDocument format, best practice

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 10:48 AM, Graham Cox wrote: So far I haven't experienced any problems and it prompts for save just like any untitled document would. Hmmm ... it just seems wrong to me, though. :-) Perhaps it's not a short-circuiting in the sense I so dramatically described, but a

Re: Binding a model's ivar array to the contents of an NSArrayController

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 11:29 AM, A B wrote: So in short, my need is pretty simple: Bind an array to an NSArrayController. That being said, it seems that no combination of exposeBindings:, bind:toObject:withKeypath:options:, observeValueForKey:ofObject:change:context:, etc. is working as I

Re: debugging strategy

2009-09-16 Thread I. Savant
On Sep 16, 2009, at 1:05 PM, Michael Cinkosky wrote: Here is the situation. We have a large application that has been in the field for several years now. We are adding new feature for our next release, and we are testing the new builds against Snow Leopard as well as earlier versions of

Re: NSFireTimer Crash

2009-09-15 Thread I. Savant
On Sep 15, 2009, at 12:51 AM, Anurag Khare wrote: At least tell me the reason for this crash report.Please At least post your code, please. -- I.S. ___ Cocoa-dev mailing list (Cocoa-dev@lists.apple.com) Please do not post admin requests or

Re: File Conversion Using Cocoa

2009-09-15 Thread I. Savant
On Sep 15, 2009, at 9:53 AM, Ramesh P wrote: I would like to convert pdf, doc files to html files using Cocoa? Please help me in this. If you want more specific information, break your problem down into steps. How do I write this application? is an unreasonably-broad question. In

Re: Finding nearby places

2009-09-07 Thread I. Savant
On Sep 7, 2009, at 5:48 AM, Mahaboob wrote: I get the latitude and longitude from the iPhone using coreLocation framework. Now I need to show the nearby hotels, restaurants etc. Which api I need to use for this? I'm using iPhone OS 2.2 This has to be the fourth or fifth time you've asked

Re: document-based application

2009-09-07 Thread I. Savant
On Sep 7, 2009, at 1:24 AM, Oftenwrong Soong wrote: In my doc-based app, I need to initially display a startup window instead of a new empty document. Its function would be somewhat akin to that of the Template Chooser that comes up when you launch Pages. This might help (it's a little

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 9:47 AM, Clayton Leitch wrote: Here is the code in MyDocument: -(IBAction)calculateStat:(id)sender{ fetchedObjects = nil; context = [self managedObjectContext]; fetchRequest = [[NSFetchRequest alloc] init]; entity = [NSEntityDescription

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
Taking this back on-list where it belongs. On Sep 4, 2009, at 9:53 AM, Clayton Leitch wrote: Yes, there is a Measurement instance in the the data model. Debugger shows that everything is set properly until the array gets no objects in answer to the query. Are you sure? How have

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 10:24 AM, Clayton Leitch wrote: Yes, I saved it as XML and opened the file. Below is what I found: Okay, so since there're definitely some instances in the store, and nothing is nil in the debugger, the only thing remaining is your message delivery. ... have you

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 9:47 AM, Clayton Leitch wrote: fetchedObjects = nil; ... fetchRequest = [[NSFetchRequest alloc] init]; ... fetchedObjects = [context executeFetchRequest:fetchRequest error:error]; ... [fetchRequest release]; One other thing

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 10:38 AM, Clayton Leitch wrote: The debugger shows 0 objects in the array. Interestingly, this same code works perfectly in a non-NSDocument version of this application. Wait, when you say it works in a non-NSDocument-based version, it makes me wonder: did you copy

Re: Having problem with fetch request in NSDocument based application

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 10:48 AM, Clayton Leitch wrote: I re-typed everything in a freshly produced document based application. So you created a new Core Data Document based application and put your code and data model into it, and it's still not working correctly? I'm utterly mystified.

Re: (no subject)

2009-09-04 Thread I. Savant
On Sep 4, 2009, at 6:16 PM, David Blanton wrote: I want to develop a CocoaTouch app that talks to a web server without doing 'web pages'. I.e. the app does http gets and posts driving php (or other) scripts on the server to access some sql database. ... Make sense or shoveling against

Re: Fonts that are always there

2009-09-03 Thread I. Savant
On Sep 3, 2009, at 6:57 AM, Gabriel Zachmann wrote: Does anyone know which fonts are always there on every Mac OS X 10.5 system? (besides the base 14 fonts from Adobe) Or is there somewhere a list? Do you really want a list of fonts or do you mean to find a safe, system-provided font?

Re: [iphone] ebook

2009-09-03 Thread I. Savant
On Sep 3, 2009, at 9:05 AM, Dragos Ionel wrote: - should I use a UITextView or UIWebView? A text view adds a lot of editing perks but limited styling perks. A web view allows attaching stylesheets so that the actual content is pure HTML (an established markup language). Since you're

Re: Fonts that are always there

2009-09-03 Thread I. Savant
On Sep 3, 2009, at 12:26 PM, Jens Alfke wrote: No, you should fall back on the system as mentioned above. Always. Why? It's perfectly reasonable to look for, say, Tahoma but fall back to Helvetica, then use the system font as a last resor The term fall back on means exactly what you

  1   2   3   4   5   6   7   8   9   >