From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.help Subject: RE: Read file into *Help* buffer Date: Fri, 23 Sep 2016 19:03:58 -0700 (PDT) Message-ID: <068a523a-bb08-440d-9b2f-38beb3f7cb92@default> References: <20160924002918.GA3442@mail.akwebsoft.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1474682698 29589 195.159.176.226 (24 Sep 2016 02:04:58 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sat, 24 Sep 2016 02:04:58 +0000 (UTC) To: Tim Johnson , Emacs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Sat Sep 24 04:04:54 2016 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bncKY-0005lo-0m for geh-help-gnu-emacs@m.gmane.org; Sat, 24 Sep 2016 04:04:42 +0200 Original-Received: from localhost ([::1]:54552 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bncKW-0006zK-0o for geh-help-gnu-emacs@m.gmane.org; Fri, 23 Sep 2016 22:04:40 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33790) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bncK5-0006yB-9i for Help-gnu-emacs@gnu.org; Fri, 23 Sep 2016 22:04:14 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bncK0-0006CK-Rb for Help-gnu-emacs@gnu.org; Fri, 23 Sep 2016 22:04:12 -0400 Original-Received: from aserp1040.oracle.com ([141.146.126.69]:25616) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bncK0-0006BT-KO for Help-gnu-emacs@gnu.org; Fri, 23 Sep 2016 22:04:08 -0400 Original-Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id u8O241lm018622 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Sat, 24 Sep 2016 02:04:02 GMT Original-Received: from userv0121.oracle.com (userv0121.oracle.com [156.151.31.72]) by userv0022.oracle.com (8.14.4/8.13.8) with ESMTP id u8O241B7016451 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Sat, 24 Sep 2016 02:04:01 GMT Original-Received: from abhmp0006.oracle.com (abhmp0006.oracle.com [141.146.116.12]) by userv0121.oracle.com (8.13.8/8.13.8) with ESMTP id u8O23xap016791; Sat, 24 Sep 2016 02:04:01 GMT In-Reply-To: <20160924002918.GA3442@mail.akwebsoft.com> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9 (901082) [OL 12.0.6753.5000 (x86)] X-Source-IP: userv0022.oracle.com [156.151.31.74] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 141.146.126.69 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.help:111378 Archived-At: > Is there a way to read a specific text file into a buffer > (defaulting as *Help*) with help-mode activated? >=20 > I.E. I'd like to use some text files to be loaded in the same manner > that would take effect if I invoked help-command or any other > "help-oriented" command. Functions `help-buffer' and `with-help-window' can help. Something like this: (defun file-to-help (file) "..." (with-current-buffer (help-buffer) (with-help-window (help-buffer) (insert-file-contents (expand-file-name file) nil nil nil :REPLACE))))