[Conkeror] flailing about on upgrade
Jeremy Maitin-Shepard
jeremy at jeremyms.com
Sat Mar 22 15:08:44 PDT 2008
"Mark Eichin" <eichin at gmail.com> writes:
> I'd been running an older 0.42 out of git, and as part of a general
> upgrade (ff3, ubuntu 8.04 alpha, etc.) I upgraded to current git as of
> yesterday. This hasn't gone well :-) I had a lot of customizations
> that depended on internals which have (reasonably enough) changed.
> Some of them I've been able to just delete, because the underlying
> functions are sufficient now (yay.) Some things I'm still mystified
> by:
> * conkeror.url_remoting_fn = conkeror.find_url_new_buffer; is now,
> *approximately*,
> url_remoting_fn = load_url_in_new_buffer;
> except that that loads it in a background buffer, not in a
> foreground one like the old way...
> Ah, turns out that I can redefine it:
> function load_url_in_new_buffer_really(url, ctx) {
> create_buffer_in_current_window(buffer_creator(content_buffer,
> $load = url, $configuration = ctx.config),
> OPEN_NEW_BUFFER);
> }
> url_remoting_fn = load_url_in_new_buffer_really;
> Shouldn't load_url_in_new_buffer just obey browser_default_open_target
> though?
browser_default_open_target is actually used just for window open
requests generated by either page JavaScript window.open calls or
target=_blank.
I agree, though, that load_url_in_new_buffer should foreground the new
buffer, and I'll fix that.
> * I guessed correctly that "c 0" replaces C. How do I *paste* into
> the browser now? c-y does something I don't yet get, and m-space is
> unbound...
If you want to paste a URL, you can use C-y while in a URL entry
minibuffer.
> * "ReferenceError: XMLHttpRequest is not defined" anyone know off
> hand how I get at that from the rcfile now?
var req = Cc["@mozilla.org/xmlextras/xmlhttprequest;1"].createInstance();
See:
http://developer.mozilla.org/en/docs/nsIXMLHttpRequest
The RC file no longer loads in the context of a particular window.
Instead it loads when conkeror first starts, before any windows are
open, in a global conkeror context. Due to oddities in JavaScript, a
fair number of names like XMLHttpRequest are actually just bound as
properties of the top-level window object, and thus are not available,
but you can always access them by the normal XPCOM mechanisms.
> * how do I get passthrough so that I can use gmail?
C-M-q switches to pass through mode, escape switches back.
C-q quotes a single key.
> (My apologies if it sounds like I'm complaining - it's just that my
> command bindings are in my fingers, not my head, so when they don't
> work it gets really frustrating, and when I go back to classic
> firefox, basic editting keys like c-n and c-p pop up windows which is
> kind of painful :-)
If you come to #conkeror on irc.freenode.net, I and others will probably
also be there to help, if you have any additional questions. Feedback
is always helpful.
> On a related note - anyone using pyxpcom with conkeror? It was a
> plenary session topic at Pycon (mozilla team apparently considers
> python "the first second-class language" :-) but I don't quite grok
> the level at which it operates...
As far as I understand, with some work it might be possible to produce
XPCOM components in Python, but because Conkeror doesn't actually expose
any XPCOM interfaces related to its internals, you wouldn't be able to
do anything very interesting with Conkeror from Python. Possibly
pyxpcom could allow Conkeror to be rewritten mostly from scratch in
python, but that would be a lot of work and probably provide little
gain. Possibly the only advantage it would provide is speed ---
JavaScript is actually quite a powerful language, but it is quite slow.
I think a lot of the noticeable slowness, though, is due to rendering
rather than JavaScript.
--
Jeremy Maitin-Shepard
More information about the Conkeror
mailing list