[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: EWW improvements: open in new buffer, tags, quickmarks, search engin

From: Lars Ingebrigtsen
Subject: Re: EWW improvements: open in new buffer, tags, quickmarks, search engines, ...
Date: Mon, 16 Apr 2018 12:54:49 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Pierre Neidhardt <address@hidden> writes:

> I've recently hacked around EWW and since it's coming into good shape
> I'm thinking of committing this upstream.
> Before sending a patch, here is the current state of my hacks:

Please send separate patches for each feature.  :-)

> - Add `eww-copy-page-title' that mirrors `eww-copy-page-url', it's
>   useful enough.


> - Enhances eww-next-url / eww-previous-url so that when there is no next /
>   previous links, it tries to increment / decrement the last number in
>   the last element of the URL.  ("do what you mean" style.)

Hm...  Are there many web sites where that is meaningful?

> - Add a `eww-reload-all' command to reload all *eww* buffers, it's
>   useful when using desktop-mode but when `eww-restore-desktop' is nil.


> - Make `eww' so that the default value is in the prompt, ready to be
>   edited by the user.  Very convenient in my opinion.

No, that's against Emacs' convention for prompting.  The default is
always stashed in `M-n'.

> - Change `eww-open-in-new-buffer' so that it queries for a URL instead
>   of cloning the current buffer (which is not very useful in my
>   opinion).

That's not what it's supposed to do -- it opens the link under point in
a new buffer.

> - Make eww-update-header-line-format also update the buffer name so that
>   it contains the page title.  _Very useful_ to browse / search *eww*
>   buffers (think Ivy/Helm).

Sounds nice, but also sounds like something not everybody would want, so
it should have a configuration option to switch on/off (but can default
to on).

> - Ask for tags when saving a bookmark.  Tags are stored under the key
>   :tags as a list of strings.

Good idea.

> - Make `eww-add-bookmark' run a customizable function to decide when.
>   to error out.  For instance, error out when a duplicate is detected
>   with protocol stripped out (https://foo.bar is seen as a duplicate of
>   http://foo.bar).

Hm...  Doesn't really sound all that useful?  But having that command
give feedback (and perhaps query the user about what to do) in that
situation would be handy.

> - Make `eww-write-bookmarks' run a customizable function before saving
>   the file.  That function can be used, for instance, to detect
>   duplicates or to sort the bookmarks.  This would make the eww-bookmarks
>   file more friendly to versioning.


> - Bookmarks can have a mark which is a string saved under the key :mark.
>   The mark should be unique.  It could be used like the "quickmark"
>   function found in some browsers: use it to quickly load a
>   bookmark. (Work in progress.)

A mark in addition to a tag?  Sounds like a bit more than most users
would want to invest in a bookmarking system, but I don't object.

> - Bookmarks can have a search engine which is either appended to the
>   bookmark' URL if it does not start with "https?://", or used as-is
>   otherwise.
>   The search engine is stored as a string under the key :search.
>   A "%s" must be present in the search engine string as a place-holder
>   for the query.

Hm.  Sounds more complicated than users will want to do to me.

> - Make `eww-bookmark-prepare' only load  bookmarks from file if not
>   already set.  This makes it possible to display a custom / narrowed
>   list of bookmarks in the bookmark buffer.

I don't quite follow...  What about just adding narrowing and sorting to
that mode?

> - Make `eww-bookmark-prepare' display the mark, the tags and the search
>   engine, if available.  Work in progress.  I'm thinking of using a
>   different face for the mark if a search engine is present.


> - Add a `eww-bookmarks-by-tags' command which queries the user for a
>   completing list of tags and then displays a bookmark buffers of all
>   the bookmarks which match the tags.  The matching can be either
>   inclusive or exclusive (bookmarks which match at least one tag vs. all
>   of them).

Sounds nice.

> - Make `eww--dwim-expand-url' follow a different logic to bind it all 
> together:
>   - With a multi-word query, if first word is a mark of a bookmark with a 
> search engine,
>   then use the said search engine over the rest of the query.
>   - With a single word query, if first word is a mark then open the
>     corresponding bookmark.
>   - Else query the default search engine.

Sounds confusing.  :-)  But also quite DWIM, which I like.

> - Fix `eww-forward-url' as it seems to corrupt the history.  (Work in 
> progress.)
> Of course in its present state my hacks are what they are, very hacky.
> It needs to be made more customizable and interfaceable.
> What do you think?

Sounds great to me.  :-)  Make each thing into a patch (with
documentation) and let the apply-to-Emacs-fest commence.  That is, if
you've been through the assign-copyright-to-the-FSF-process.  I don't
see you in the copyright.list file, but that's apparently out of date
these days...

(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no

reply via email to

[Prev in Thread] Current Thread [Next in Thread]