From: "Sebastián Monía" <sebastian@sebasmonia.com>
To: Adam Porter <adam@alphapapa.net>
Cc: emacs-devel@gnu.org, jporterbugs@gmail.com
Subject: Re: [PATCH] Use vtable for eww-bookmarks
Date: Sun, 01 Dec 2024 11:17:27 -0500 [thread overview]
Message-ID: <87o71vml7s.fsf@sebasmonia.com> (raw)
In-Reply-To: <cc34b418-a804-43be-be9f-952d61fd3d5d@alphapapa.net> (Adam Porter's message of "Sun, 1 Dec 2024 00:39:33 -0600")
Adam Porter <adam@alphapapa.net> writes:
>> Jim Porter <jporterbugs@gmail.com> writes:
>>> I'm not sure what a better key would be though. Maybe "C" for "clear sort"?
>> Attached a patch that uses "c" ("c", not "C") and renames the
>> function
>> to match.
>> Let me know what you think!
> Given how many similar modes and buffers that are in Emacs (i.e. where
> some kind of objects are displayed in a list with metadata), I think
> it would be best if any new such feature followed existing paradigms
> as closely as possible. To have each vtable-like view (whether
> implemented with vtable or tabulated-list or anything else) have
> slightly different concepts and bindings is not helpful to the user.
There is already some slight differences here and there and it is
sometimes jarring, so, great point.
For example Gnus uses # for marking, instead of m like vc-dir/dired,
sometimes it trips me.
> In this case, the vtable-map already binds
> vtable-sort-by-current-column. So it seems like what we need is a
> column by which to sort entries by default. That would seem to leave
> us with two options:
>
> a) Sort by bookmark name by default
>
> b) Add a column for the bookmarks' place in the list, and sort by
> that by default.
The reason the bookmarks order matters, and this killing and yanking
feature exists, is that EWW binds M-n and M-p to navigate to the
next/prev bookmark. I doubt it is a popular feature (only found out
about it when writing this patch...) but I wouldn't remove it. So
defaulting to sort by name would be off the table, as it breaks the
whole thing.
Adding a column "Navigation order", or "rank" (both terrible names, open
to suggestions) seems like a great idea.
> BTW, instead of doing:
>
> + (while (not (equal (vtable-current-object)
> + bookmark-at-point))
> + (forward-line 1))))
>
> Could you use vtable-goto-object? I realize that it currently uses EQ
> for comparison, but 1) we've talked about changing that, and 2) ISTM
> that EQ should work for this case anyway, because entries in the
> bookmark list are being compared, and they shouldn't be getting
> copied. Am I missing something?
You are not, that code is a 1:1 conversion of the previous code. Next
patch, which may include the new column, will make better use of
vtable-goto-object when applicable. Thank you!
Regards,
Seb
--
Sebastián Monía
https://site.sebasmonia.com/
next prev parent reply other threads:[~2024-12-01 16:17 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-11-05 22:53 [PATCH] Use vtable for eww-bookmarks Sebastián Monía
2024-11-06 12:21 ` Eli Zaretskii
2024-11-06 13:36 ` Sebastián Monía
2024-11-06 14:33 ` Eli Zaretskii
2024-11-06 14:43 ` Visuwesh
2024-11-06 16:52 ` Sebastián Monía
2024-11-06 20:49 ` Sebastián Monía
2024-11-07 2:00 ` Visuwesh
2024-11-07 2:00 ` Visuwesh
2024-11-20 19:27 ` Sebastián Monía
2024-11-11 7:38 ` Jim Porter
2024-11-23 19:12 ` Jim Porter
2024-11-27 20:02 ` Sebastián Monía
2024-11-28 19:49 ` Jim Porter
2024-12-01 5:33 ` Sebastián Monía
2024-12-01 6:39 ` Adam Porter
2024-12-01 16:17 ` Sebastián Monía [this message]
2024-12-01 19:31 ` Jim Porter
2024-12-01 22:12 ` Sebastián Monía
2024-12-09 4:52 ` Jim Porter
2024-12-10 19:16 ` Sebastián Monía
2024-12-12 4:15 ` Sebastián Monía
2024-12-12 15:25 ` Sebastián Monía
2024-12-12 18:08 ` Adam Porter
2024-12-12 19:37 ` Sebastián Monía
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87o71vml7s.fsf@sebasmonia.com \
--to=sebastian@sebasmonia.com \
--cc=adam@alphapapa.net \
--cc=emacs-devel@gnu.org \
--cc=jporterbugs@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.