From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alex Newsgroups: gmane.emacs.bugs Subject: bug#27890: 26.0.50; describe-font does not use Help buffer history Date: Sat, 05 Aug 2017 20:01:33 -0600 Message-ID: <873795wj2a.fsf@lylat> References: <87ini8b8oz.fsf@lylat> <877eyhwr7q.fsf@lylat> <8760e15ywe.fsf@users.sourceforge.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1501984938 28629 195.159.176.226 (6 Aug 2017 02:02:18 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 6 Aug 2017 02:02:18 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: 27890@debbugs.gnu.org To: npostavs@users.sourceforge.net Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Aug 06 04:02:14 2017 Return-path: Envelope-to: geb-bug-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 1deAtO-0006oR-QN for geb-bug-gnu-emacs@m.gmane.org; Sun, 06 Aug 2017 04:02:10 +0200 Original-Received: from localhost ([::1]:59433 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deAtP-0007Hf-Uc for geb-bug-gnu-emacs@m.gmane.org; Sat, 05 Aug 2017 22:02:11 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54663) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1deAtK-0007HL-5n for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2017 22:02:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1deAtH-0005yt-1h for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2017 22:02:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:41255) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1deAtG-0005xg-TB for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2017 22:02:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1deAtF-0004z3-UZ for bug-gnu-emacs@gnu.org; Sat, 05 Aug 2017 22:02:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Alex Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 06 Aug 2017 02:02:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 27890 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 27890-submit@debbugs.gnu.org id=B27890.150198491219143 (code B ref 27890); Sun, 06 Aug 2017 02:02:01 +0000 Original-Received: (at 27890) by debbugs.gnu.org; 6 Aug 2017 02:01:52 +0000 Original-Received: from localhost ([127.0.0.1]:43932 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deAt6-0004yh-FM for submit@debbugs.gnu.org; Sat, 05 Aug 2017 22:01:52 -0400 Original-Received: from mail-io0-f176.google.com ([209.85.223.176]:34257) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1deAt4-0004yR-6Q for 27890@debbugs.gnu.org; Sat, 05 Aug 2017 22:01:50 -0400 Original-Received: by mail-io0-f176.google.com with SMTP id o9so16610889iod.1 for <27890@debbugs.gnu.org>; Sat, 05 Aug 2017 19:01:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=kRvqZMCsDE4S4I8C7Ogo7kIDftEJI04XOGS3v8d1TV8=; b=mKpKk0tFCJe3eXsqk01rnzW0DJ/6xXQGcFT3GxjeXhtjIRJsdmTUEKwnrGZGmA9ANQ qkCnZ/Io69T7g5S5FYMhiLy4WlE87mNaNtaUL+q0rcSPRe/Ff2MLkZBQFmXc8VvHx4pA Cqbleclb3hMSTetIpSfC7EJb7yF5QbCAB10EkPxIn2ErSWYP11hQefQUfX1YfGHW8R4y 2B8Ngu9R3ckgQRJQVOWUxV59wileZMzeDjrxkUmZJlSzSmiaQvXftBABkQgRj5Fpg1AB 8tuphrWDOtGVwU6NoS6xoIvo/Fy0neDM0fhQsQSJlBrAaKELFndqwBA1PLKmKW9XRI6B kEtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=kRvqZMCsDE4S4I8C7Ogo7kIDftEJI04XOGS3v8d1TV8=; b=kwXJw3jiLIynQog9jjr+GWq2mRWVCgSd+J/E1Px4PASsDGE/uasA4MvfkGd/17nlKt /JLaMy72NYgHuuM0xzSCMoD+Fksa+uqKCAwDMeXI4mkKByX5uAhaVH4E+wcxJQs+3Tgm 6/X2ObwmKthwvuVG3LY30nxwZLpMqn50ktd7DZYwEU06LWyEZAT+dfNqMpDWqWl0H+I9 evk+hvOIZ1hR5uHNnOh2WCQfjHtw9KigTxf5PN+OogsACEWx13xml1tSyoKymcaJJOAs D9+gH/pQu9ZhzUf5VPTrRwowN9W1siPgK8Z/gnGqeZ7u3SPBNCz3AlabBZsXznYjQkm+ qM4g== X-Gm-Message-State: AHYfb5hD2TzxipCYdy0ZiV+v2tijz5dHAAtOkgH288USsVQWR2JslASg zK/EJ7tETwWfoQer X-Received: by 10.107.179.135 with SMTP id c129mr7591455iof.106.1501984904316; Sat, 05 Aug 2017 19:01:44 -0700 (PDT) Original-Received: from lylat (S010664777d9cebe3.ss.shawcable.net. [70.64.85.59]) by smtp.gmail.com with ESMTPSA id q192sm2360244itc.20.2017.08.05.19.01.42 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sat, 05 Aug 2017 19:01:42 -0700 (PDT) In-Reply-To: <8760e15ywe.fsf@users.sourceforge.net> (npostavs's message of "Sat, 05 Aug 2017 20:21:37 -0400") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:135466 Archived-At: npostavs@users.sourceforge.net writes: > tags 27890 + patch > quit > > Alex writes: > >> Alex writes: >> >>> describe-font does not add to the *Help* buffer's history. The [Back] >>> button does appear when there is a non-empty history, but going back and >>> then forward does not restore the font description. >> >> Here's a patch for it. >> >> + (let ((xref-item (list #'describe-font fontname)) > [...] >> + (help-setup-xref xref-item (called-interactively-p 'interactive)) > > Looks fine, personally I wouldn't bother introducing that local > variable. I introduced that variable because the procedure conditionally sets fontname if it's an empty sequence. As it stands, the procedure would error without capturing that variable ahead of time due to `length' being called on a font object. I figured this was the simplest way around that problem. Do you have an easier way in mind? I could perhaps change the setq line to instead set fontname to (face-attribute 'default :family), which would allow for removing the local variable safely.