From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#65346: 30.0.50; *lisp/net/eww.el: new function 'eww-open-in-new-buffer-background' Date: Sun, 20 Aug 2023 19:44:03 +0300 Organization: LINKOV.NET Message-ID: <861qfyovm8.fsf@mail.linkov.net> References: <1181651021.466162.1581309285621.ref@mail.yahoo.com> <1181651021.466162.1581309285621@mail.yahoo.com> <83350i6rcy.fsf@gnu.org> <83sf8g523j.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3784"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: Eli Zaretskii , 65346@debbugs.gnu.org To: Lin Sun Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sun Aug 20 19:28:25 2023 Return-path: Envelope-to: geb-bug-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 1qXmDx-0000mo-0d for geb-bug-gnu-emacs@m.gmane-mx.org; Sun, 20 Aug 2023 19:28:25 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qXmDc-00060B-10; Sun, 20 Aug 2023 13:28:04 -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 1qXmDZ-0005z1-HW for bug-gnu-emacs@gnu.org; Sun, 20 Aug 2023 13:28:01 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qXmDZ-0002cA-9N for bug-gnu-emacs@gnu.org; Sun, 20 Aug 2023 13:28:01 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qXmDa-0004vj-Um for bug-gnu-emacs@gnu.org; Sun, 20 Aug 2023 13:28:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 20 Aug 2023 17:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 65346 X-GNU-PR-Package: emacs Original-Received: via spool by 65346-submit@debbugs.gnu.org id=B65346.169255247118879 (code B ref 65346); Sun, 20 Aug 2023 17:28:02 +0000 Original-Received: (at 65346) by debbugs.gnu.org; 20 Aug 2023 17:27:51 +0000 Original-Received: from localhost ([127.0.0.1]:54760 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXmDO-0004uR-OQ for submit@debbugs.gnu.org; Sun, 20 Aug 2023 13:27:51 -0400 Original-Received: from relay7-d.mail.gandi.net ([217.70.183.200]:37755) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXmDM-0004tr-B9 for 65346@debbugs.gnu.org; Sun, 20 Aug 2023 13:27:48 -0400 Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id 3402D20002; Sun, 20 Aug 2023 17:27:39 +0000 (UTC) In-Reply-To: (Lin Sun via's message of "Fri, 18 Aug 2023 19:03:08 +0000") X-GND-Sasl: juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:268011 Archived-At: > +(defun eww-open-in-new-buffer (&optional no-select url) > + "Fetch URL in a new EWW buffer. > + > +If the NO-SELECT is not `nil', the forcus will stay on current buffer. > + > +If the URL is `nil', it will try `eww-suggested-uris' under current cursor." > + (interactive "P") > + (if-let ((url (or url (eww-suggested-uris)))) > + (if (or (eq eww-browse-url-new-window-is-tab t) > + (and (eq eww-browse-url-new-window-is-tab 'tab-bar) > + tab-bar-mode)) > + (let ((tab-bar-new-tab-choice t)) > + (tab-new) > + (eww--open-url-in-new-buffer url) > + (when no-select > + (tab-bar-switch-to-prev-tab))) tab-bar-switch-to-prev-tab is a wrong function, please use tab-bar-switch-to-recent-tab instead. Also please add a new command to open a tab in background. Then new command could be bound to the standard RET modifier used in all web browsers to open a tab in background.