[emacs-w3m:13667] [emacs-w3m/emacs-w3m] Find/use 'next'/'prev' links not identified within HTML tags (#81)

Boruch Baum <[email protected]> Mon, 07 Sep 2020 18:20:27 +0000 (UTC)
Newsgroups gmane.emacs.w3m
Message-ID <emacs-w3m/emacs-w3m/pull/[email protected]>
+ w3m parses HTML tags to try to intelligently guess the &#39;next&#39; and
  &#39;previous&#39; pages for a URL so it proceed there when a page beginning
  or end is reached. However, some/many website software don&#39;t embed
  that information within HTML tags, and they rely solely on the
  plain-text between the opening and closing HTML &#39;A&#39; tag. An example
  of this is the sofwtare for the emacs mailing list archive! This
  commit adds logic to find and use that information.

+ This commit does introduce new behavior in the patched functions
  that change the meaning of the prefix-arg!

  + The most convenient way to give the user flexibility to change
    his/her mind about which text labels to use for navigation was to
    use the prefix-arg for two of the scroll commands. However, those
    functions were already using the prefix-arg for an option to
    scroll n lines instead of a screen-full. After giving the matter
    thought, it seemed to me that someone wanting finely-tuned
    scrolling could/should/was probably using two other functions
    anyway (w3m-scroll-up and w3m-scroll-down) which default to one
    line and have the optional prefix-arg for n lines.

+ Minimizing the effect of the behavior change

  + The commit adds a defcustom for number of default lines to scroll
    when not performing fine-tune scrolling (ie. when not using
    functions w3m-scroll-up and w3m-scroll-down). When that variable
    is NON-NIL, functions w3m-scroll-up-or-next-url and
    w3m-scroll-down-or-previous-url use that number instead of a
    screen-full.

  + The commit adds a function w3m-set-scroll-interval to conveniently
    change the default scroll amount of the defcustom, but only for
    the current session.

+ The result is that scrolling is more convenient because if you want
  someone who wants to scroll n lines instead of a screen-full will
  probably want to do that repeatedly. Without the patch, that user
  would need to use the prefix-arg and numeric entry for each scroll.
  With this commit, the user only needs to set the value once, and can
  do so as a command, without having to manually evaluate a variable.
  The use does need to remember or guess that in order to &quot;set the w3m
  scroll interval&quot; you perform M-x w3m-set-scroll-interval.

+ Benefit of logic at point-of-use. The logic is not performed during
  page parsing (all pages), only when the feature is needed (very
  rarely).
You can view, comment on, or merge this pull request online at:

  https://github.com/emacs-w3m/emacs-w3m/pull/81

-- Commit Summary --

  * Find/use &#39;next&#39;/&#39;prev&#39; links not identified within HTML tags

-- File Changes --

    M ChangeLog (9)
    M w3m.el (153)

-- Patch Links --

https://github.com/emacs-w3m/emacs-w3m/pull/81.patch
https://github.com/emacs-w3m/emacs-w3m/pull/81.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/emacs-w3m/emacs-w3m/pull/81