[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: HTML info
From: |
Juri Linkov |
Subject: |
Re: HTML info |
Date: |
Fri, 24 Dec 2021 10:34:34 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) |
> I’m a bit confused. In order to have variable-pitch info’s. What do we
> need to do and what do makeinfo maintainers need to do?
What we can already do is to at least display Emacs manuals from HTML
generated by `make html`.
> Disregard of where will the HTML info files be, whether they will be
> in a single file, whether distributions will distribute HTML info
> files, what do we need to do in order to at least support reading HTML
> info files like .info files?
>
> Is it a good idea that we start from a major mode Info-html-mode that
> can view manuals in either a single or multiple HTML files, that
> supports various info commands?
Most of the core package info.el deals with handling of the Info format.
Take for example Info-search. What it mostly does is parsing the Info file's
tag table and visiting Info subfiles. All this is not needed for HTML.
Instead of this, the HTML search function will have other problems:
how to skip text in HTML tags, e.g. searching for the word "href"
should not match it as the HTML attribute in ‘<a href="">...</a>’, etc.
OTOH, some of Info-search code should be reused in HTML Info files:
- the key ‘s’ bound in Info-mode-map should still call ‘Info-search’;
- the interactive spec should be used without changes for HTML search;
- such code (signal 'user-search-failed (list regexp "end of manual"))
should be reused, etc. (And most isearch functions in info.el are
already general enough that can be used for both Info and HTML formats,
except the Info-format specific ‘Info-isearch-filter’.)
So we have at least 3 choices:
1. Intersperse the existing Info-search with such conditionals:
(if info-html-minor
(search-forward "<div class="contents">")
(search-forward "\n\^_\nIndirect:"))
2. Add more hooks to every Info top command,
so Info-html-mode could register own handlers:
(add-hook 'Info-search-function 'Info-html-search)
3. Completely duplicate all top Info commands in a new package
info-html.el.
- Re: Variable pitch mode line, (continued)
- Re: Variable pitch mode line, Juri Linkov, 2021/12/23
- Re: Variable pitch mode line, Lars Ingebrigtsen, 2021/12/23
- Re: Variable pitch mode line, Juri Linkov, 2021/12/23
- Re: Variable pitch mode line, Lars Ingebrigtsen, 2021/12/23
- Re: Variable pitch mode line, Juri Linkov, 2021/12/23
- Re: Variable pitch mode line, Stefan Monnier, 2021/12/23
- Re: Variable pitch mode line, Eli Zaretskii, 2021/12/23
- Re: Variable pitch mode line, Stefan Monnier, 2021/12/23
- Re: Variable pitch mode line, Eli Zaretskii, 2021/12/23
- HTML info, Yuan Fu, 2021/12/23
- Re: HTML info,
Juri Linkov <=
- Re: HTML info, Eli Zaretskii, 2021/12/24
- Re: HTML info, Lars Ingebrigtsen, 2021/12/24
- Re: HTML info, Po Lu, 2021/12/24
- RE: [External] : Re: HTML info, Drew Adams, 2021/12/24
- Re: HTML info, Juri Linkov, 2021/12/25
- Re: HTML info, Yuan Fu, 2021/12/26
- Re: HTML info, Eli Zaretskii, 2021/12/26
- Re: HTML info, Juri Linkov, 2021/12/26
- Re: HTML info, Juri Linkov, 2021/12/27
- Re: HTML info, Lars Ingebrigtsen, 2021/12/26