Re: Knowing when a NSArrayController is ready

2009-01-24 Thread Matt Neuburg
ta is ready. I just now tried adding addObserver: to the mix, just as an experiment, and logging reveals that I get two corresponding calls to observeValueForKeyPath:, *before* fetchWithRequest: has returned. The two calls are quite far apart (half a second or so). Well, I sure wouldn't want to run my

Re: Long load time of managed object context

2009-01-24 Thread Matt Neuburg
s that 10.000 objects are not much for core > data, but in my app it makes a big difference, so I'm wondering where > I am wrong. You don't say what format you're using, but if you're using XML, the entire XML file has to be loaded and parsed, even before you fetch any objec

Re: Knowing when a NSArrayController is ready

2009-01-24 Thread Matt Neuburg
ling addPersistentStoreWithType:). So the delay there is nothing but the XML file being loaded and parsed. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript:

Re: Knowing when a NSArrayController is ready

2009-01-25 Thread Matt Neuburg
On or about 1/25/09 8:08 AM, thus spake "jonat...@mugginsoft.com" : > I also made use of -setUsesLazyFetching. Not an option for me, alas, as my app must run on Tiger. m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai

Re: Animation, NSProgressIndicator and Bindings

2009-01-27 Thread Matt Neuburg
appear uneven or jerky." So that is what I would expect. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of the 2007 MacTech Top 25: <http://tinyurl.com/2rh4pf> AppleScript: the Definitive Guide - Second

Re: Modal Sheet without Spaghetti?

2009-01-28 Thread Matt Neuburg
ut contextInfo. The contextInfo that you hand in to the call to beginSheet: comes back out in your didEnd method, so it can tell that method where to go next. It might be some sort of carrier of state and/or even an invocation. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.c

animation keys

2009-01-30 Thread Matt Neuburg
"subviews". My question is: how would I find this out? I mean, I can guess that setFrameRotation: might trigger the @"frameRotation" animation, but I would never have guessed this one. So where can I find a list of what actions trigger what animation keys? Thx - m. -- matt ne

Re: Determining Previous Front Process

2009-01-30 Thread Matt Neuburg
the archives.) Since you will be notified every time a different app comes to the front, you can just keep track - when your app comes to the front, the one you *previously* recorded as being in front is the one you're after. (It may, of course, have now terminated.) m. -- matt n

elementary CAAnimationGroup question

2009-01-31 Thread Matt Neuburg
h the checkbox in the nib), it stops working - the rotation never happens and the duration is ignored. Why? Is it because I'm doing this wrong, and it was just dumb luck that it ever worked in the first place? Why would the existence of the layer make a difference? And what's the righ

Re: NSTextField with an date formatting

2009-02-01 Thread Matt Neuburg
t text field 1 correctly updating to the new >date, and vice versa. I suspect this may be a bug, has anyone else >experience anything similar and what is the process of reporting to >Apple if it is a bug? Can you reduce the problem to a little tiny project and show it? m. -- matt neuburg,

Re: Read lines from very large text file

2009-02-06 Thread Matt Neuburg
On Tue, 03 Feb 2009 00:42:07 +1100, Jacob Rhoden said: >I am wondering what the best way to read a text file, line by line, when >the file size is much larger than available memory. Would there be a way to do this with dataWithContentsOfMappedFile? I've long wondered about that... m

where's my exception?

2009-02-06 Thread Matt Neuburg
ecret exception that doesn't get revealed to me? m. -- matt neuburg, phd = m...@tidbits.com, http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2rh4pf AppleScript: the Definitive Guide, 2nd edition http://www.tidbit

Re: One Shot Windows: WARNING

2009-02-07 Thread Matt Neuburg
ndow is properly CLOSED, it's gone; it doesn't matter what the oneShot settings are. If there's a wrong setting in your story, it sounds more like it might be releasedWhenClosed. But it sounds if the problem is in the relationship between your window and your window controller.

Re: One Shot Windows: WARNING

2009-02-09 Thread Matt Neuburg
On Sat, 7 Feb 2009 21:06:20 -0800, Seth Willits said: >On Feb 7, 2009, at 8:45 PM, Matt Neuburg wrote: > >>> In my case, I have a document window with a table view in it, where >>> data source and delegate are the window controller. If the window is >>> oneShot

Re: One Shot Windows: WARNING

2009-02-10 Thread Matt Neuburg
On Tue, 10 Feb 2009 11:12:17 -0500, Michael Ash said: >On Tue, Feb 10, 2009 at 1:02 AM, Matt Neuburg wrote: >> Actually, having looked at your example, I reproduced the crash from the >> bottom up by starting with the Document Architecture template. >> >> I create

Re: One Shot Windows: WARNING

2009-02-10 Thread Matt Neuburg
;t make this kind of difference. With this dealloc, it doesn't. That's what I was after. Thanks! m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript:

Re: [Q] What causes an NSArrayController to know that an entity was inserted via a different window?

2009-02-24 Thread Matt Neuburg
he array controller receiving notification of >the newly added records so that I can, hopefully, do the same with my custom >view? Well, it's all about bindings and KVO (key-value-observing), isn't it? I mean, that's what they do and that's what they're for. m. -- ma

Re: simple memory management question

2009-02-24 Thread Matt Neuburg
? And if not, why not? It depends on what setMyParentController is doing, doesn't it? If it doesn't retain it, then no one is retaining it, and when you release it it will vanish in a puff of smoke, closing everything in this copy of the nib. m. -- matt neuburg, phd = m...@tidb

Re: How to center a custom NSView in a NSScrollView

2009-02-26 Thread Matt Neuburg
rollSize.height > imageSize.height) ? scrollSize.height : imageSize.height; [self setFrameSize: mySize]; if (scrollSize.height < imageSize.height) [cv setBoundsOrigin: NSMakePoint([cv bounds].origin.x, curTop - scrollSize.height)]; } m. -- matt neuburg, phd = m...@tidbits.com, <ht

rolling my own drawer-like child window

2008-10-09 Thread Matt Neuburg
2 This prevents the main window from losing its appearance, but the table in the pseudo-drawer is not receiving keypresses. m. -- matt neuburg, phd = [EMAIL PROTECTED], http://www.tidbits.com/matt/ pantes anthropoi tou eidenai oregontai phusei Among the 2007 MacTech Top 25, http://tinyurl.com/2

Re: rolling my own drawer-like child window

2008-10-09 Thread Matt Neuburg
On or about 10/9/08 10:33 AM, thus spake "Kyle Sluder" <[EMAIL PROTECTED]>: > On Thu, Oct 9, 2008 at 1:17 PM, Matt Neuburg <[EMAIL PROTECTED]> wrote: >> I want to make a drawer that the user cannot close or slide. Since you can't >> stop the user from sl

Re: Problems when putting a window between desktop and desktop icons

2008-10-23 Thread Matt Neuburg
subclass of NSWindow): > >[self setLevel:kCGDesktopIconWindowLevel - 1]; I think what you want to say is CGWindowLevelForKey(kCGDesktopWindowLevelKey). This should be more robust than manipulating the level value directly. m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a to

Re: LSUIElement application and coming to the front

2008-10-23 Thread Matt Neuburg
app comes to the front. I use this approach and I and my users find it a lot less confusing than e.g. what Help Viewer does in Leopard (which is simply horrendous IMHO). m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool

Re: External Program Control from within Cocoa App

2008-11-03 Thread Matt Neuburg
and sent them. See Appendix B of my book (and my online article about replacing AppleScript with Ruby) for more info about that. m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of the 2007 MacTech Top 25: &

Re: Cannot change menu state in NSSearchField menu for more than once

2008-11-03 Thread Matt Neuburg
h here is excellent. In your first message, where you say that the menu stopped working after one use, I was going to suggest that the reason was that you were accidentally generating another menu and that mySearchMenu was no longer pointing where you think. But you discovered this very fact

Re: Modal Dialog Issue

2008-11-03 Thread Matt Neuburg
ationWindow]; > >} > >- (void)didEndSheet:(NSWindow *)sheet returnCode:(int)returnCode >contextInfo:(void *)contextInfo{ > [sheet orderOut:self]; > >} > >Cheers, >Carmen > > > -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/&

Re: CALayer contents memory leak

2008-11-04 Thread Matt Neuburg
lysis tools (MallocDebug, Shark, what have you). m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of the 2007 MacTech Top 25: <http://tinyurl.com/2rh4pf> AppleScript: the Definitive Guide - Second Edition! &

Re: NSTableView Informal Protocal

2008-11-04 Thread Matt Neuburg
indow (used to be option-command-shift-question mark), make sure it is set to do an API search, and type tableview:set You can stop typing; you are there. m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of

Re: CALayer contents memory leak

2008-11-04 Thread Matt Neuburg
On Tue, 04 Nov 2008 08:58:24 -0700, Adam Fedor <[EMAIL PROTECTED]> said: > >On Nov 4, 2008, at 8:23 AM, Matt Neuburg wrote: > >> On Sun, 02 Nov 2008 22:08:04 -0700, Adam Fedor <[EMAIL PROTECTED]> said: >>> I have a simple program with a memory leak that is dr

Re: Enumerating outlets automatically?

2008-11-06 Thread Matt Neuburg
s a tag identifier, which was matched up with the desired control within the window using a recursive form of viewWithTag:. m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of the 2007 MacTech Top 25: <htt

Re: Any sample code to record in aiff format

2009-03-05 Thread Matt Neuburg
On Thu, 5 Mar 2009 20:45:13 +0530, Anshul jain said: > >hi > Is there any sample code to record in aiff format Did you try a search on "recording audio" at the apple developer site? m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool

Re: Newbie query re notifications

2009-03-06 Thread Matt Neuburg
llback. As the docs say, "The method the selector specifies must have one and only one argument." m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! h

Re: NSObjectController selection - now you see it, now you don't

2009-03-08 Thread Matt Neuburg
jectController. So you might need to explain why that isn't the case. Or, putting it more broadly, it might be helpful if you described what are these objects, what is meant by selection, and what is it you're *really* trying to accomplish. m. -- matt neuburg, phd = m...@tidbits.com,

Re: Handling WebView DOM events in Cocoa

2009-03-12 Thread Matt Neuburg
fari/library/documentation/AppleApplications/C onceptual/SafariJSProgTopics/Tasks/ObjCFromJavaScript.html> Can you explain further why that isn't what you're after? m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool!

Re: Develop and OSAX

2009-03-12 Thread Matt Neuburg
As you can see, it looks like Carbon entry points all the way. On the other hand, as an AppleScript user, I'm pleading with you - no, no, not another OSAX! Just make a scriptable executable (faceless background if need be). And then you could use Cocoa Scripting and be all Objective-C, all th

Re: Calling Script Objects in Applescript

2009-03-14 Thread Matt Neuburg
#x27;ascr/psbr' Apple event on p. 479 of my book, and Ken Ferry has a wonderful set of convenience methods (http://homepage.mac.com/kenferry/software.html). m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript

Re: NSTableView behavior changes

2009-03-18 Thread Matt Neuburg
NSResponder* r = [[sourceTableView enclosingScrollView] nextResponder]; [[sourceTableView enclosingScrollView] setNextResponder: self]; [self setNextResponder: r]; Finally, make sure everything is getting hooked up and instantiated correctly. m. -- matt neuburg, phd = m...@tidbits.c

Re: NSAppleScript - what is going on here?

2009-03-22 Thread Matt Neuburg
]; NSAppleEventDescriptor *eventDescriptor = [appleScriptObject executeAndReturnError: &errorDict]; [appleScriptObject release]; if (([eventDescriptor descriptorType]) && (errorDict==nil)) { NSLog(@"%@", [eventDescriptor stringValue]); } else { NSLog(@"%@"

Re: NIB Init method for window subclasses

2009-03-25 Thread Matt Neuburg
lt Interface Builder library That didn't mention windows. If you are using a window subclass, you'll receive awakeFromNib. Subclassing NSWindow, however, merely to get an early message, would be unnecessary. More typical is to use one of the many fine notifications / delegate messages provide

Re: Reading one line at a time using NSFileHandle

2009-03-26 Thread Matt Neuburg
09/2/2/229302> m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http://www.tidbits.com/matt/default.html#applescriptthings ___

Re: Processing data maintained with Core Data

2009-03-27 Thread Matt Neuburg
27;ve migrated into Core Data in situations where I used to have my own data structure, just because Core Data is such an easy way to handle the general case. And this is for data that is neither complicated nor large. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/>

Re: Spotlight and Leopard

2009-03-29 Thread Matt Neuburg
are SOL. Whereas, if a file is moving around the same hard drive, an alias (once formed) always works. m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Second Edition! http:/

Re: Floating window on top of everything

2009-04-08 Thread Matt Neuburg
mains on top. Search the archives for example code showing how your app can be notified when an app switch occurs... m. -- matt neuburg, phd = m...@tidbits.com, <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! AppleScript: the Definitive Guide - Se

Re: Floating window on top of everything

2009-04-09 Thread Matt Neuburg
On or about 4/8/09 11:25 PM, thus spake "Andrew Farmer" : > On 08 Apr 09, at 08:03, Matt Neuburg wrote: >> On Tue, 7 Apr 2009 12:37:05 -0400, Walker Argendeli >> said: >>> I am making a simple application that consists of a small HUD window >>> that nee

Re: Floating window on top of everything

2009-04-09 Thread Matt Neuburg
On Thu, 9 Apr 2009 17:31:52 +0100, Benjamin Dobson said: > >On 9 Apr 2009, at 16:49:48, Matt Neuburg wrote: > >> On or about 4/8/09 11:25 PM, thus spake "Andrew Farmer" > >: >> >>> On 08 Apr 09, at 08:03, Matt Neuburg wrote: >>>> On T

Re: Apple Help question

2008-02-29 Thread Matt Neuburg
ellow Help Book Blp! Mismatch, did not follow directions, game over, thank you for playing! :) m. -- matt neuburg, phd = [EMAIL PROTECTED], <http://www.tidbits.com/matt/> A fool + a tool + an autorelease pool = cool! One of the 2007 MacTech Top 25: <http://tinyurl.com/2rh4pf> Ap

why isn't id an id?

2013-10-04 Thread Matt Neuburg
ke casting to id. It is as if id is not an id, which makes no sense to me. Is this a Clang bug? Or am I just missing some fundamental truth? m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Programming iOS 7! http://shop

Re: why isn't id an id?

2013-10-04 Thread Matt Neuburg
learned a lot. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ pantes anthropoi tou eidenai oregontai phusei Programming iOS 7! http://shop.oreilly.com/product/0636920031017.do iOS 7 Fundamentals! http://shop.oreilly.com/product/0636920032465.do RubyFrontier! http://www.apeth.co

Re: Mixing UIDocument's NSUndoManager and -updateChangeCount:

2014-01-14 Thread Matt Neuburg
book: - (void) forceSave: (id) n { [self.doc saveToURL:doc.fileURL forSaveOperation:UIDocumentSaveForOverwriting completionHandler:nil]; } m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ Programming iOS 7! http://shop.oreilly.com/product/0636920031017.do i

Re: UIPopoverController and UIToolbar interactions

2014-01-14 Thread Matt Neuburg
all part of the primitive, brainless lack of real popover management. They sucked when they were introduced in iOS 3.2 and they have not been improved or changed in any way since then. I have a long-standing bug in on the whole thing, including this particular issue. m. -- matt neuburg,

Re: UILabel's sizeToFit - only on re-used cells

2014-01-15 Thread Matt Neuburg
h:` is meaningful and correct! That is a _major_ reason for preferring it; you can do layout here. (Of course you can't do that if you are backwards-compatible to before its existence.) m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ Programming iOS 7! http://shop.oreilly.

Re: UIButton over sliding UIImageView disappears until slide complete

2014-01-19 Thread Matt Neuburg
button remain in view at all times? Can you post on github a small project that will allow the issue to be reproduced? Thx - m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ Programming iOS 7! http://shop.oreilly.com/product/0636920031017.do iOS 7 Fundamentals! http:/

Re: System fonts on iOS 7

2014-01-19 Thread Matt Neuburg
cidentally saw. Of course that doesn't solve the problem you're having; I'm just saying what Apple says in the 2013 WWDC videos. I suppose you could say something like System - Caption (or whatever it is) by running thru the various role names and trying to match against the hidde

Re: Delays in awaking iOS app

2014-02-03 Thread Matt Neuburg
be replaced by the real interface, and meanwhile the app is not responsive because you're not _in_ the app: you're tapping on the snapshot. I wonder if that's what you're experiencing. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ Programming iO

Re: Mismatched viewWillAppear/viewDidDisapper calls possible?

2014-02-03 Thread Matt Neuburg
ms impervious to any understanding of the fact that we need coherent reliable order and sequence for these events. m. -- matt neuburg, phd = m...@tidbits.com, http://www.apeth.net/matt/ Programming iOS 7! http://shop.oreilly.com/product/0636920031017.do iOS 7 Fundamentals! http://shop.oreilly.com/p

Re: Animation on gesturing

2014-02-03 Thread Matt Neuburg
o refresh >animation for the stretched little do dad. See the section in my book on interactive custom animations. Here's some source code: https://github.com/mattneub/Programming-iOS-Book-Examples/blob/master/bk2ch06p296customAnimation2/ch19p620customAnimation1/AppDelegate.m m. -- matt

<    4   5   6   7   8   9