From kirt.fitzpatrick at gmail.com Tue May 8 05:04:30 2007 From: kirt.fitzpatrick at gmail.com (Kirt Fitzpatrick) Date: Mon, 7 May 2007 22:04:30 -0700 Subject: [TxMt Plugins] caret location Message-ID: Does anyone know how to obtain the caret location either in the line or in the file? selectedRanges is not implemented by OakTextView. Thanks, kirt -------------- next part -------------- An HTML attachment was scrubbed... URL: From throw-away-1 at macromates.com Tue May 8 14:32:23 2007 From: throw-away-1 at macromates.com (Allan Odgaard) Date: Tue, 8 May 2007 16:32:23 +0200 Subject: [TxMt Plugins] caret location In-Reply-To: References: Message-ID: <9BA75DAE-C0D4-4A72-92A5-FBE6B9381DC5@macromates.com> On 8. May 2007, at 07:04, Kirt Fitzpatrick wrote: > Does anyone know how to obtain the caret location either in the > line or in the file? selectedRanges is not implemented by > OakTextView. The class does not expose this via any attributes. It does however have lineNumber and columnNumber as bindable properties. So in practice you can use that to get the line/column position. From kirt.fitzpatrick at gmail.com Tue May 8 19:12:05 2007 From: kirt.fitzpatrick at gmail.com (Kirt Fitzpatrick) Date: Tue, 8 May 2007 12:12:05 -0700 Subject: [TxMt Plugins] caret location In-Reply-To: <9BA75DAE-C0D4-4A72-92A5-FBE6B9381DC5@macromates.com> References: <9BA75DAE-C0D4-4A72-92A5-FBE6B9381DC5@macromates.com> Message-ID: I did not find those properties as exposedBindings for OakTextView. My test code follows: bindings = [responder exposedBindings]; int i; for ( i=0; i < [bindings count]; i++ ) { NSLog( @"binding: %@", [bindings objectAtIndex:i] ); } This produced the following output. 2007-05-08 09:43:51.800 TextMate[915] binding: hidden 2007-05-08 09:43:51.800 TextMate[915] binding: toolTip Also attempting to bind to lineNumber or columnNumber [self bind:@"lineNumber" toObject:responder withKeyPath:@"lineNumber" options:nil]; causes the following error [ valueForUndefinedKey:]: this class is not key value coding-compliant for the key lineNumber However lineNumber and columnNumber appear to be available in OakStatusBar. But I do not know how to grab that object. Any ideas? thanks again, kirt On 5/8/07, Allan Odgaard < throw-away-1 at macromates.com> wrote: > > On 8. May 2007, at 07:04, Kirt Fitzpatrick wrote: > > > Does anyone know how to obtain the caret location either in the > > line or in the file? selectedRanges is not implemented by > > OakTextView. > > The class does not expose this via any attributes. > > It does however have lineNumber and columnNumber as bindable > properties. So in practice you can use that to get the line/column > position. > > _______________________________________________ > textmate-plugins mailing list > textmate-plugins at lists.macromates.com > http://lists.macromates.com/mailman/listinfo/textmate-plugins > -------------- next part -------------- An HTML attachment was scrubbed... URL: From throw-away-1 at macromates.com Wed May 9 07:33:40 2007 From: throw-away-1 at macromates.com (Allan Odgaard) Date: Wed, 9 May 2007 09:33:40 +0200 Subject: [TxMt Plugins] caret location In-Reply-To: References: <9BA75DAE-C0D4-4A72-92A5-FBE6B9381DC5@macromates.com> Message-ID: On 8. May 2007, at 21:12, Kirt Fitzpatrick wrote: > [...] > Also attempting to bind to lineNumber or columnNumber > [self bind:@"lineNumber" toObject:responder > withKeyPath:@"lineNumber" options:nil]; You need to send the bind:? message to the text view. E.g.: NSMutableDictionary* dict = [NSMutableDictionary dictionary]; [textView bind:@"lineNumber" toObject:dict withKeyPath:@"line" options:nil]; [textView bind:@"columnNumber" toObject:dict withKeyPath:@"column" options:nil]; NSLog(@"%@", dict); // cleanup [textView unbind:@"lineNumber"]; [textView unbind:@"columnNumber"]; From kirt.fitzpatrick at gmail.com Wed May 9 18:35:53 2007 From: kirt.fitzpatrick at gmail.com (Kirt Fitzpatrick) Date: Wed, 9 May 2007 11:35:53 -0700 Subject: [TxMt Plugins] Page load optimization. Message-ID: Many of you have already seen this, for those that haven't, here is the linkto a page that describes ways to optimize page load times. http://www.die.net/musings/page_load_time/ kirt -------------- next part -------------- An HTML attachment was scrubbed... URL: From kirt.fitzpatrick at gmail.com Wed May 9 18:42:46 2007 From: kirt.fitzpatrick at gmail.com (Kirt Fitzpatrick) Date: Wed, 9 May 2007 11:42:46 -0700 Subject: [TxMt Plugins] Re: Page load optimization. - My apologies Message-ID: I sent this to the wrong mailing list by mistake. Sorry about that. kirt On 5/9/07, Kirt Fitzpatrick wrote: > > Many of you have already seen this, for those that haven't, here is the > link to a page that describes > ways to optimize page load times. > > http://www.die.net/musings/page_load_time/ > > kirt > > -------------- next part -------------- An HTML attachment was scrubbed... URL: