From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Drew Adams Newsgroups: gmane.emacs.devel Subject: RE: [PATCH] open bookmark in other frame Date: Thu, 11 Oct 2018 22:04:07 +0000 (UTC) Message-ID: <357cd187-ad96-4cc6-9c01-cca87282f165@default> References: <9d4a9ab3-d802-447e-3c74-81373b7e6101@luyten.fr> <9f2ed5a8-96c0-aa6c-b9c8-3b0f73f20aa6@luyten.fr> 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 1539295350 17618 195.159.176.226 (11 Oct 2018 22:02:30 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 11 Oct 2018 22:02:30 +0000 (UTC) To: Pierre-Yves Luyten , emacs-devel@gnu.org, Karl Fogel Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 12 00:02:25 2018 Return-path: Envelope-to: ged-emacs-devel@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 1gAj2G-0004Rn-Uo for ged-emacs-devel@m.gmane.org; Fri, 12 Oct 2018 00:02:25 +0200 Original-Received: from localhost ([::1]:37338 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gAj4N-0005qJ-E1 for ged-emacs-devel@m.gmane.org; Thu, 11 Oct 2018 18:04:35 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:35478) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gAj4C-0005q9-IS for emacs-devel@gnu.org; Thu, 11 Oct 2018 18:04:25 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gAj47-0001cA-1R for emacs-devel@gnu.org; Thu, 11 Oct 2018 18:04:23 -0400 Original-Received: from userp2130.oracle.com ([156.151.31.86]:47430) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1gAj45-0001Wh-2u for emacs-devel@gnu.org; Thu, 11 Oct 2018 18:04:17 -0400 Original-Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w9BM3vHt026845; Thu, 11 Oct 2018 22:04:15 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=mime-version : message-id : date : from : sender : to : subject : references : in-reply-to : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=Azz1+NM1QHypBbgL7dMLeQ7WI0nDQeYbLYkBEuc6mpA=; b=nTlt/aiKHyc/olhpBtQrdHgVtmm2gzS6pBuFTPhpKCSltd79SftczsFB/E+jnzqj2D89 jRwqpnq6MyHmQvRZcbLAjJfqWTTJsVmtTd8Mx4gNexGLuzXGqYfSQN/KsclyVQa4+Uv+ 0LmLUhFbdg6/RxWcyQI58xkwJ7BJGW6xc42fNflaC23oTnCYWeOC0vCkvK5WdcX7YKcz ZWhsc8fjEK/Uat9Sq2uEFVuuxzRnC4CepxOuKa1nQ9IzAF/jgyJd25anc7M8iQG7i4cb QSqQV3VrZrZXB+6oCAwwfUA7OnrsE4ubEq4l7h5iNTfhBPuHhRxz50lTZy36x+YUQULo 9Q== Original-Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2130.oracle.com with ESMTP id 2mxmfu79w5-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 11 Oct 2018 22:04:15 +0000 Original-Received: from userv0122.oracle.com (userv0122.oracle.com [156.151.31.75]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id w9BM4AcC006480 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Thu, 11 Oct 2018 22:04:10 GMT Original-Received: from abhmp0020.oracle.com (abhmp0020.oracle.com [141.146.116.26]) by userv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w9BM49IZ028959; Thu, 11 Oct 2018 22:04:09 GMT In-Reply-To: <9f2ed5a8-96c0-aa6c-b9c8-3b0f73f20aa6@luyten.fr> X-Priority: 3 X-Mailer: Oracle Beehive Extensions for Outlook 2.0.1.9.1 (1003210) [OL 16.0.4735.0 (x86)] X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9043 signatures=668706 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1807170000 definitions=main-1810110206 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x [generic] X-Received-From: 156.151.31.86 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.org gmane.emacs.devel:230341 Archived-At: > > My suggestions in this regard, FWIW: > > > > 1. Don't use `view-buffer-other-frame'. > > Select the buffer, and not just read-only. Jumping to a bookmark > > typically puts you at its location (hence select), and the buffer = is > > typically not put in a read-only mode. IOW, do the equivalent of > > this, or similar: > > > > (let ((pop-up-frames t)) (bookmark-jump-other-window bookmark) > > > > 2. Don't use `F' as the key binding in the bookmark-list buffer. > > `F' is more often used for files than for frames. Maybe use `5'. > > > > (I use `J 5' in Bookmark+. `J' is a prefix for the jump commands > > in the bookmark-list buffer. The `5' is from `C-x 5' bindings for > > other-frame. I bind the command to `C-x 5 B' and `C-x j 5' globall= y. > > `C-x j' is a global prefix key for bookmark jump commands.) >=20 > So here is the new version of the patch > 1. Use pop-up-frames variable to avoid a read-only mode on new frame. > I also had to use (other-frame 1) to ensure new frame is raised. 1. `pop-up-frames' has nothing to do with read-only. It just makes an "othe= r-window" function use another frame instead of another window. If you use = `bookmark-jump-other-window' instead of `bookmark-jump' then you don't need= to also use `(other-frame 1)'. See the code I sent. 2. I don't think you need to include this in the doc string: , so the bookmark menu bookmark remains visible in its window. That text is present for the other-window case, to emphasize that the same = window is not reused. (It's not really needed there either, but it can help= .) If we say that the bookmark is selected in another frame then it's prett= y clear that we don't reuse the original window. HTH.