From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nikos Apostolakis Subject: Re: OT: remember'ing from other programs with stumpwm Date: Thu, 05 Jul 2007 08:17:16 -0400 Message-ID: <87odirt583.fsf@Sullivan.bcc.cuny.edu> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1I6QOW-0006kY-Cw for emacs-orgmode@gnu.org; Thu, 05 Jul 2007 08:25:12 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1I6QOU-0006iR-Tc for emacs-orgmode@gnu.org; Thu, 05 Jul 2007 08:25:11 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1I6QOU-0006iI-GD for emacs-orgmode@gnu.org; Thu, 05 Jul 2007 08:25:10 -0400 Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1I6QOT-0007SC-1t for emacs-orgmode@gnu.org; Thu, 05 Jul 2007 08:25:09 -0400 Received: from root by ciao.gmane.org with local (Exim 4.43) id 1I6QOM-0002Bv-52 for emacs-orgmode@gnu.org; Thu, 05 Jul 2007 14:25:02 +0200 Received: from 199.219.160.30 ([199.219.160.30]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 05 Jul 2007 14:25:02 +0200 Received: from nikos.ap by 199.219.160.30 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 05 Jul 2007 14:25:02 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org "Dmitri Minaev" writes: > > Obviously, one thing is missing here -- the URL. Unfortunately, I > couldn't find a way to retrieve it from Firefox programmatically. This may not be what you want but there is Conkeror, an emacs-like keyboard-driven version of firefox. In Conkeror the "copy-current-url" is bund to "c". So, if I understood your code correctly you would have to add a few lines like (window-send-string (current-window) "c") to copy the URL to the x-clipboard and later (window-send-string (current-window) (kbd "C-y")) to copy the clipboard to the relelevant emacs buffer. > > To get all this working, I just had to set up remember-mode > (shamelessly copying the instructions from the org-mode manual) and to > add the following into ~/.stumpwmrc file: > > (define-stumpwm-command "emacs-remember" () > (let ((window-name (if (current-window) (window-title > (current-window)) "No current window"))) > (run-or-raise "emacs" :class "Emacs") > (send-meta-key (current-screen) (kbd "M-x")) > (window-send-string (current-window) "org-remember") > (send-meta-key (current-screen) (kbd "RET")) > (window-send-string (current-window) "f") > (window-send-string (current-window) window-name) > (send-meta-key (current-screen) (kbd "RET")) > (window-send-string (current-window) (get-x-selection)))) > (define-key *top-map* (kbd "F12") "emacs-remember") > For some time I've been considering to switch to stumpwm from ratpoison. The naturality of the above (at least in the eyes of an emacs user) finally did it. I am now determined that in a week that I'll be back home I'll try stumpwm. Thanks for posting this (even though it's OT). HTH, Nikos