From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Shahab Shahsavari Alavidjeh Newsgroups: gmane.emacs.help Subject: Re: How can use the Hyperlinks in org-mode? Date: Thu, 15 Oct 2015 09:22:52 +0330 Message-ID: <87eggwn0ej.fsf@fedora22.zzgraph> References: <20151015041735.GA12835@debian> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1444888488 3164 80.91.229.3 (15 Oct 2015 05:54:48 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 15 Oct 2015 05:54:48 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Oct 15 07:54:36 2015 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 1ZmbUp-0002jJ-SS for geh-help-gnu-emacs@m.gmane.org; Thu, 15 Oct 2015 07:54:36 +0200 Original-Received: from localhost ([::1]:45897 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZmbUp-0001WJ-4W for geh-help-gnu-emacs@m.gmane.org; Thu, 15 Oct 2015 01:54:35 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:58718) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZmbTK-0001Tb-CR for help-gnu-emacs@gnu.org; Thu, 15 Oct 2015 01:53:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ZmbTF-0003Y7-BX for help-gnu-emacs@gnu.org; Thu, 15 Oct 2015 01:53:02 -0400 Original-Received: from mail-wi0-x22f.google.com ([2a00:1450:400c:c05::22f]:33632) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ZmbTF-0003Y3-51 for help-gnu-emacs@gnu.org; Thu, 15 Oct 2015 01:52:57 -0400 Original-Received: by wijp11 with SMTP id p11so12425911wij.0 for ; Wed, 14 Oct 2015 22:52:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:references:date:in-reply-to:message-id:user-agent :mime-version:content-type; bh=REVvgbgMeyxyyhhr5nkjkpWRBVme+q3H4WVX5Uz05sM=; b=gXKXGZYwkPFvr6bVC4Z3CGeWt0ymobx3KSn5yeDMcm+qEtvchn1G61xxXTti6jOMzu YgwNp4betyN9Nx59twKii4RJ1JQ66CcrnC1nQSUtT2arZVX1HdFji0HtT9GA4LCHH557 oYBvu0/6+HpzVFpKHPs3p7ZsRUA9IegxfU4ZsRKIKWqqTj7mln2mjQbIWxW7xm3osz4R LufK8PFyMHatQzdEi3AL7mbGbjLmbj/3POsVQJJ3jh5AaEmok+iuI0TOXQdSX0/GvlHN 7cxDDbxORVeutGV+BVw5eRwvCSIDXQhhcw6OIAmxkTW+em4RHh9mUl4qyUxSf6R0R/Vk ObuA== X-Received: by 10.194.246.102 with SMTP id xv6mr8334574wjc.58.1444888376317; Wed, 14 Oct 2015 22:52:56 -0700 (PDT) Original-Received: from localhost ([188.245.16.254]) by smtp.gmail.com with ESMTPSA id wx10sm14196335wjb.40.2015.10.14.22.52.54 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 14 Oct 2015 22:52:54 -0700 (PDT) In-Reply-To: <20151015041735.GA12835@debian> (Navy Cheng's message of "Thu, 15 Oct 2015 12:17:35 +0800") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:400c:c05::22f 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:107652 Archived-At: Navy Cheng writes: > I use [[file:picture/xxx.jpg]] to link a picture and the .jpg file is opened > by emacs. However I want to open the .jpg with ristretto. How can I specify > the default picture viewer? C-c C-o actually runs (org-open-at-point) command in an org buffer >From Documentation: When point is on a link, follow it. Normally, files will be opened by an appropriate application. If the optional prefix argument ARG is non-nil, Emacs will visit the file. With a double prefix argument, try to open outside of Emacs, in the application the system uses for this file type. In this documentation screen phrase `appropriate application' means "What Emacs thinks is appropriate" not "What O.S. thinks is appropriate". If you want to change the default behavior of C-c C-o you should pass an argument to it (Which Emacs decides where to open it and it tries to open it itself if possible), if you pass a single prefix argument ( C-u C-c C-o ) you'll instruct it to open file inside of Emacs explicitly. If you want it to open file outside of Emacs you should use two prefix arguments, which should be like this `C-u C-u C-c C-o' Emacs by default configured to open many mime-types inside Emacs, (you can see default modes for mime types in `C-h v auto-mode-alist' ) and org-mode follows these associations by default. If you want org-mode to open image files outside Emacs without bothering to use prefix arguments, you can change file type association by manipulating this list, but IMO that's not an good idea, because it change the behavior everywhere. Much better idea is to manipulate `org-file-apps' list. Therefore I can refer you to this stackoverflow answer which explains how to change default C-c C-o behavior inside org-mode buffers: http://stackoverflow.com/questions/3973896/emacs-org-mode-file-viewer-associations#3985552