From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Karl Fogel Newsgroups: gmane.emacs.bugs,gmane.emacs.devel Subject: bug#59212: On improving Bookmarks Date: Wed, 16 Nov 2022 11:28:30 -0600 Message-ID: <87k03u7qrl.fsf@red-bean.com> References: Reply-To: Karl Fogel Mime-Version: 1.0 Content-Type: text/plain; format=flowed Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="27638"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 59212@debbugs.gnu.org, emacs-devel@gnu.org To: Gabriel Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Nov 16 18:29:18 2022 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 1ovMDt-0006yA-Ql for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 16 Nov 2022 18:29:18 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ovMDj-0006ut-V1; Wed, 16 Nov 2022 12:29:07 -0500 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 1ovMDf-0006rO-Cx for bug-gnu-emacs@gnu.org; Wed, 16 Nov 2022 12:29:03 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ovMDf-0005tN-2F for bug-gnu-emacs@gnu.org; Wed, 16 Nov 2022 12:29:03 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ovMDe-0000NO-ID for bug-gnu-emacs@gnu.org; Wed, 16 Nov 2022 12:29:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Karl Fogel Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 16 Nov 2022 17:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 59212 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 59212-submit@debbugs.gnu.org id=B59212.16686197181413 (code B ref 59212); Wed, 16 Nov 2022 17:29:02 +0000 Original-Received: (at 59212) by debbugs.gnu.org; 16 Nov 2022 17:28:38 +0000 Original-Received: from localhost ([127.0.0.1]:58034 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ovMDF-0000Mj-ME for submit@debbugs.gnu.org; Wed, 16 Nov 2022 12:28:38 -0500 Original-Received: from sanpietro.red-bean.com ([45.79.25.59]:34504) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ovMDC-0000MZ-Ml for 59212@debbugs.gnu.org; Wed, 16 Nov 2022 12:28:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=red-bean.com; s=202005newsp; h=Content-Type:MIME-Version:Message-ID:Date: Reply-To:References:In-Reply-To:Subject:Cc:To:From:Sender: Content-Transfer-Encoding:Content-ID:Content-Description; bh=b4CeVMaMwLL5hkXP8drlLImMQDUTQdiKLsKgvOJw4E4=; t=1668619714; x=1669829314; b=bJWIVpwbDO4Ay36jLWr/cgTXwVlyrDcSmWLe1sD8R42HzM8SQdaaTtxwXBp9m5V2RgxL3oCohmq kKXsQV8eGDk5OAoA2b+QNJCtUl2sYmENf5OgLL1yHRnfCn55Yt0JEW2sVZHhemROSXyUnr2J/8Icm /ZfybGBxHtW/FR1Hm6eCFtTT0+HgENgVAIyGir6N+ZyQuYYktT/obiog4AhCnGFMhr/EGxTaAYiVf FYH0J3U8wKuQXl7c6fuIQjhREjd34fQt07pdvs3YPXJGe7Ia9x45zjZQvEaQBjfKDLJMoRA0Qw2Rm ClDyiCGwNZJcf1CTh0u/iEExXOGuhdI3plug==; Original-Received: from [12.106.183.66] (port=39772 helo=hummy) by sanpietro.red-bean.com with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1ovMD9-008B3a-MP; Wed, 16 Nov 2022 17:28:31 +0000 In-Reply-To: (Gabriel's message of "Wed, 16 Nov 2022 02:25:20 -0300") 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:248031 gmane.emacs.devel:299957 Archived-At: [I'm combining the original bug-59212 thread with an emacs-devel thread here.] On 12 Nov 2022, Eli Zaretskii wrote in Bug #59212: >> From: Gabriel >> Date: Sat, 12 Nov 2022 05:56:22 -0300 >> >> Description: >> Not a bug per se, but a suggestion for improvement in how >> Bookmark >> displays the Type (added by commit >> 7c995264359824cc1aca40ca37201db5ed44e659). >> >> Currently, bookmark-bmenu-list (C-x r l) displays a column >> named Type, >> which has a proper value for all handlers (e.g.: Eshell, VC, >> EWW etc) >> except for regular files, in which an empty string is >> displayed. I >> believe the current behavior could be improved by displaying a >> default >> value ("Files") to make the interface more uniform, explicit >> and to >> avoid confusion. >> >> Steps: >> 1) emacs -Q >> 2) M-x eshell >> 3) C-x r m >> 4) C-x C-f ~/foo.bar >> 5) C-x r m >> 6) C-x r b >> >> These steps will add two bookmarks (eshell and foo.bar) and >> will open >> the Bookmarks list. The Type column will have values "" and >> "Eshell". After the patch below is applied, the Type column >> will have >> values "File" and "Eshell". > >Thanks. > >Karl, any comments? I don't have a strong opinion on this UI suggestion. For users who set mostly file-or-directory bookmarks, and don't set very many bookmarks of other types, then it probably makes sense to treat files/directories as the default and not show a type for them. That way, the unusual bookmarks stand out (which is useful because they might have different response-time characteristics, or other interactive idiosyncracies, than that user's typical bookmark does). On the other hand, for users for whom file/directory bookmarks are not more common than other kinds of bookmarks, showing "File" or "Directory" like any other type would probably be better. Those users are already accustomed to a variety of interactivity characteristics from their bookmarks anyway, so it makes less sense to trade away consistency of display in favor of stand-out visibility of certain cases. But these are really minor differences; they're not terribly persuasive either way. I think I'm still at "no strong opinion". I wouldn't stand in the way of the change. Continuing on to the later conversation on emacs-devel about this: On 16 Nov 2022, Gabriel wrote: >Hi, > >I think there are some opportunities for improvements in >Bookmarks (in >general and in how it support Types) and would like to collect >general >feedback and directions before reporting bugs or proposing >patches, >especially considering if such changes would be useful, the >effort to >implement them and how to handle compatibility. > >Bookmarks has support for Types besides regular "Files" or >"Directories" >(opened with Dired). A quick xref in current Emacs master branch >shows >the following Types: > >- "DocView" >- "Eshell" >- "Gnus" >- "Help" >- "Image-Dired" >- "Info" >- "Man" >- "EWW" >- "VC" >- "WoMan" > >1) The empty "Type" column on C-x r l (bookmark-bmenu-list) > >Bookmarks shows a proper value in the Type column of >bookmark-bmenu-list >for all Types, except for regular "Files" and "Directories", in >which >shows an empty string. I believe that displaying the actual Type >rather >an empty string for these cases would make the interface more >consistent >and easier for navigation. See bug#59212 for the open >discussion. >Besides the question regarding the real value of this change, I >currently don't know how to easily distinguish between "Files" >and >"Directories" without relying on IO calls >(e.g. file-directory-p), which >could degrade performance in case of long Bookmarks lists. We >could >display the string "File" for both "Files" and "Directories", but >it >would be a worse experience for users to not provide such >distinction. Could we just use a combined term like "File/Dir" or "File/Path" or just "Path" or something? Not the perfect user experience, but an 80% solution. Obviously, we'd want to keep the width small. >2) The usage of "File" and "Filename" in docs and interface > >In docs (e.g. (info "(emacs)Bookmarks")) and interface (e.g. the >"File" >column in bookmark-bmenu-list), we can find several occurrences >of the >terms "File" and "Filename" (and related terms), which I think is >inconsistent since Bookmarks supports Types that do not really >have >these concepts (e.g. "Help", "Man", "EWW", "Gnus"). A better >term would >be "Location", which is already used in some places >(e.g. bookmark-location, bookmark-relocate, the 'location >property). >Thus, I propose to make "Location" the official term in docs, >interface >and code, and to obsolete "File", "Filename" and related ones. +1. This makes a lot of sense, independently of whatever we do in the Type column of the Bookmark Menu. The rest of your post on emacs-devel isn't really related to bug #59212, so I'll follow up separately to it in a moment. Best regards, -Karl