From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Heime Newsgroups: gmane.emacs.help Subject: Re: Printing documentation string of another function Date: Wed, 10 Apr 2024 20:09:44 +0000 Message-ID: References: <86wmp5e4j4.fsf@p200300d6270a69e321a604e6fd40b4e6.dip0.t-ipconnect.de> <87wmp5huwy.fsf@gmx.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="576"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Joost Kremers , Zhengyi Fu , Heime via Users list for the GNU Emacs text editor To: Stephen Berman Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Wed Apr 10 22:10:35 2024 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1rueHB-000ASm-5x for geh-help-gnu-emacs@m.gmane-mx.org; Wed, 10 Apr 2024 22:10:33 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rueGe-0006wi-SY; Wed, 10 Apr 2024 16:10:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rueGa-0006wT-7W for help-gnu-emacs@gnu.org; Wed, 10 Apr 2024 16:09:56 -0400 Original-Received: from mail-40138.protonmail.ch ([185.70.40.138]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rueGY-0000RL-7i for help-gnu-emacs@gnu.org; Wed, 10 Apr 2024 16:09:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1712779791; x=1713038991; bh=A0+LoUv2QkXE8paf5YuWSTK3m+QgqBBt0xZfY9SZwLY=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=IyV1u/vE3hWxNyn8BnaVf6vpQAU3RsuBlRoooq8N0bsaOPTNL3dQrSWJqqjbBIyIP UB6B1GTwFISHUu90SZBPuOzVPKh6cAoanDpt9KyDHvSsTZ7tmpP8iY3kkv+axAmZqP 0mRP7O1hoh15U4w1czmrpVxja2+4sAgdD3ltug7ZTuD6lNI9z9K/A4DUNFd1LxVMh0 C2yKOTyMMFpFDiX4zIq3lLQHhcUoM6tdq5c4Jjt5bu4raU7HxaYqViy9ghJV8Vl+PL t8x0OlVXMf8qqmgHvBPQEfWNhGFAi9HKJSPy1pPwQA/EaeF1svUPIR3FAKMMZlyMkr zG/2UYXABdY/Q== In-Reply-To: <87wmp5huwy.fsf@gmx.net> Feedback-ID: 57735886:user:proton Received-SPF: pass client-ip=185.70.40.138; envelope-from=heimeborgia@protonmail.com; helo=mail-40138.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_MSPIKE_H4=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 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-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:146298 Archived-At: On Thursday, April 11th, 2024 at 7:36 AM, Stephen Berman wrote: > On Wed, 10 Apr 2024 17:17:00 +0000 Heime heimeborgia@protonmail.com wrote= : >=20 > > With the following implementation, I cannot get the documentation strin= g > > of the appropriate function to display. > >=20 > > (defun avus-doc (seltr) > > "Print the documentation string of a particular function." > >=20 > > (interactive > > (list > > (let ( (cseq '("Greek" "Flokki")) ) > > (completing-read "Doc: " cseq nil t "Greek")))) > >=20 > > (pcase seltr > > ("Greek" (documentation 'avus-greek)) > > ("Flokki" (documentation 'avus-flokki))) ) >=20 >=20 > `(documentation 'avus-greek)' just returns the doc string, it does not > display it. You have to add code to do that, e.g.: >=20 > (defun avus-doc (seltr) > "Print the documentation string of a particular function." > (interactive > (list > (let ((cseq '("Greek" "Flokki"))) > (completing-read "Doc: " cseq nil t "Greek")))) > (let ((doc (pcase seltr > ("Greek" (documentation 'avus-greek)) > ("Flokki" (documentation 'avus-flokki))))) > (tooltip-show doc))) >=20 > Steve Berman I want to print in the usual documentation buffer as doing=20 C-h f avus-greek or C-h f avus-flokki