From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Tak Kunihiro Newsgroups: gmane.emacs.help Subject: Re: Launch application with region as a parameter Date: Tue, 07 Oct 2014 08:35:26 +0900 (JST) Message-ID: <20141007.083526.135925861.tak.kunihiro@gmail.com> References: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1412638569 4157 80.91.229.3 (6 Oct 2014 23:36:09 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 6 Oct 2014 23:36:09 +0000 (UTC) Cc: tak.kunihiro@gmail.com To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Oct 07 01:36:03 2014 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1XbHow-0000tV-45 for geh-help-gnu-emacs@m.gmane.org; Tue, 07 Oct 2014 01:36:02 +0200 Original-Received: from localhost ([::1]:55250 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbHov-00086q-MX for geh-help-gnu-emacs@m.gmane.org; Mon, 06 Oct 2014 19:36:01 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:50504) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbHod-00086k-4n for help-gnu-emacs@gnu.org; Mon, 06 Oct 2014 19:35:52 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XbHoU-0005FJ-33 for help-gnu-emacs@gnu.org; Mon, 06 Oct 2014 19:35:43 -0400 Original-Received: from mail-pd0-x233.google.com ([2607:f8b0:400e:c02::233]:65066) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XbHoT-0005FD-Qz for help-gnu-emacs@gnu.org; Mon, 06 Oct 2014 19:35:34 -0400 Original-Received: by mail-pd0-f179.google.com with SMTP id r10so4058164pdi.38 for ; Mon, 06 Oct 2014 16:35:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:message-id:to:cc:subject:from:in-reply-to:mime-version :content-type:content-transfer-encoding; bh=9rvYt60YzCIoo2fNZjI6KwrEWKM82OmgkgIo3r8O5zc=; b=CJucJINe43LR9WyNCVw5J4kUfh2mQUBpxmKjwUy7zb4TlMGufAZV4kUy/SUwu8eTrQ ZBBmbK5gSg2aAUcKLzPoY65FxWL1N7czY4HxRkJ66FOZu3mUK/PHcUU3vkez6ZMifjvZ UVep3eNh6smFYKuPTnCcuwwwAhuURoP/qs8Na8HfDIzTo8XSBK0QUtqJO2VaSV/jyKiE Tk8SbdO7fgPT4j9JHOAXReVtDyGoeen4K2MeTaFAr/dyXG9nPKrYjAIh0BWa3EAeUhwH c0mIKbjgcxhBlHjTenTH2SvKxIuQFSLUlraNUwL4k4KSOjVZK7bXzhsJODP/NVBi/3fx chrg== X-Received: by 10.70.35.232 with SMTP id l8mr347043pdj.48.1412638532135; Mon, 06 Oct 2014 16:35:32 -0700 (PDT) Original-Received: from localhost (susanoh.misasa.okayama-u.ac.jp. [150.46.48.98]) by mx.google.com with ESMTPSA id ip3sm14231652pbc.58.2014.10.06.16.35.29 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Mon, 06 Oct 2014 16:35:31 -0700 (PDT) In-Reply-To: X-Mailer: Mew version 6.6 on Emacs 24.3 / Mule 6.0 (HANACHIRUSATO) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2607:f8b0:400e:c02::233 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:100318 Archived-At: I suppose you want to have something like below. (defun open-file-at-point () "Open a file at point by Explorer." (interactive) (let ((file (thing-at-point 'filename)) w32file) (when (file-exists-p file) (setq w32file (subst-char-in-string ?/ ?\\ (expand-file-name file))) (w32-shell-execute "open" "explorer" w32file)))) (global-set-key (kbd "C-c o") 'open-thing-at-point)