| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
* genman.txr (process-ambiguities): Keep track of
calculated hashes and error out when there is a
duplicate. When the time comes, we will have to
resolve those somehow, and also change the doc
function to do it the same way.
|
|
|
|
|
|
| |
* genman.txr (symhash, tagma, tochash): Define
in @(do ...) block with defvar for consistency
ith other hashes.
|
|
|
|
|
|
|
|
|
| |
* genman.txr: remove the manual insertion of
the mapping of the "lbAB" tag to the new hash for "NAME",
the first section of the man page. This is an outdated
dud that does nothing. The tag is being properly processed
without this hack and the new hash-title function will assign
it to a different hash.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is not an easy change to make because it breaks the
validity of existing URLs in the wild which point to specific
sections of the TXR manual.
Some of my recent changes to capitalization of numerous
headings have already broken many URLs, so we might as well
bite the bullet and do this now.
The problem with the current scheme is that entire section
titles are hashed: all the words of a title, not just the
names of functions. Whenever we add a new function, macro or
variable which is documented together with related functions
in the same paragraph under the same heading, the heading
changes, and the hash changes. For instance, the hash for
the hash-map identifier is actually the hash of the string
"Function <tt>hash-map</tt>".
Under the new scheme, section titles are hashed in a more
complicated way that is robust against most edits. If a
title contains any symbols marked up with <tt>, then the
leftmost such symbol is taken as the title. Otherwise,
the whole title is mapped to lower case.
There is no longer a stdlib/doc-syms.tl file, and the
special disambiguated "D-<HEX>" codes are also gone.
Symbols are no longer associated with section hashes or
disambiguation section codes. The hash of a symbol is
a 32 bit CRC-32 checksum, expressed as S-<HEX> where
<HEX> is 8 hex digits. A section which defines symbols
has not only a <a name="..."> for its own hash but also
additional <a name="...>" elements for each of the symbols
that it defines.
If a section defines an ambiguous symbol (one that is also
defined with a different meaning in a different section),
then that symbol is not linked to either section; it is
mapped to the generated disambiguating section.
* genman.txr (dupes): Renamed to dupe-hashes for clarity.
(tagnum): Hash removed.
(direct): New hash. Tracks the assocation between sections
hashes and hashes of symbols that are defined only in
those symbols (no ambiguity) and thus the symbol hashes
can navigate directly to the sections. Serves as a
complement to the disamb hash.
(colli): There are no collisions now, so
initialize this to empty.
(hash-str): Function removed.
(hash-title): This function becomes more complicated.
If a title has at least one <tt>..</tt> item, then
that is taken in its place. Either way, the title
is transformed and enumerated against duplication and
hashed with crc32 instead of the original custom hashing
function.
(enumerate): Function removed: enumeration of titles is
done inside hash-title.
All manipulations of symhash using material from HTML now
use html-decode, so that we hash the original symbol
name like "str<" and not "str<".
When filtering the BODY, we have a new case: whenever
we see a <a name="...">, we now check the new direct
hash to see if there is a list of symbol hashes for
the given section. If so, we generate additional
<a name="..."> definitions for all the symbol hashes.
At the end of the file, the "missing from image"
processing is condensed, and the generation of the
stdlib/doc-syms.tl file is removed.
* stdlib/doc-syms.tl: Removed.
* stdlib/doc-lookup.tl: Don't load doc-syms. Use crc32
plus formatting to conver a symbol to the hash that is
used in the document and try the lookup with that.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hash-map converts a function mapping over a sequence
into a hash table.
* hash.[ch] (hash_map): New function.
* tests/010/hash.tl: Test case.
* genman.txr: The hash-map identifier introduces
a hash collision. We have to deal with that somehow now.
(colli): We put the conflicting entries into a new hash called
colli which maps them to an increment value.
(hash-title): Increment the hash code h by the amount
indicated in colli, if the title is found there.
* txr.1: Documented.
* stdlib/doc-syms.tl: Updated.
|
|
|
|
|
|
|
| |
* genman.txr: Remove from the name list those names that are not
TXR symbols, so that they don't appear in doc-syms.
* stdlib/doc-syms.tl: Updated.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* genman.txr (dupes, tagnum): Replace defvar with defvarl.
* stdlib/doc-lookup.tl (os-symbol): Same.
* tests/011/macros-3.tl (x): Same.
* tests/011/mandel.txr (x-centre, y-centre, width, i-max, j-max, n)
(r-max, pixel-size, x-offset, y-offset): Same.
(file, colour-max): Delete (unused) variables.
* tests/012/circ.tl (x): Replace defvar with defvarl.
* tests/012/stack.tl (stack-limited): Same.
* tests/012/struct.tl (s): Same.
* tests/013/maze.tl (vi, pa, sc): Delete variables. Use
function arguments instead.
(usage): Fix typo.
* tests/014/dgram-stream.tl (family): Rename to...
(*family*): ...this.
* tests/014/socket-basic.tl (socktype): Rename to...
(*socktype*): ...this.
(%iters%): Replace defvar with defvarl.
|
|
|
|
|
|
|
| |
* genman.txr: Before generating stdlib/doc-syms.tl, check that the
symbols going into that file (i.e., into the doc-syms variable) are
actually contained in the TXR image (allowing for some exceptions).
Also, reindent some lines.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This affects run-time also. Txr installations where the
executable is not in directory ending in ${bindir}
will look for stdlib rather than share/txr/stdlib,
relative to the determined installation directory.
* txr.c (sysroot_init): If we detect relative to the short
name, or fall back on the program directory, use stdlib
rather than share/txr/stdlib as the stdlib_path.
* INSTALL: Update some installation notes not to refer to
share/txr/stdlib but stdlib.
* Makefile (STDLIB_SRCS): Refer to stdlib, not
share/txr/stdlib.
(clean): In unconfigured mode, remove the old share/txr/stdlib
entirely. Remove .tlo files from stdlib.
(install): Install lib materials from stdlib.
* txr.1: Updated documentation under Deployment Directory Structure.
* share/txr/stdlib/{asm,awk,build,cadr}.tl:
Renamed to stdlib/{asm,awk,build,cadr}.tl.
* share/txr/stdlib/{compiler,conv,copy-file,debugger}.tl:
Renamed to stdlib/{compiler,conv,copy-file,debugger}.tl.
* share/txr/stdlib/{defset,doc-lookup,doc-syms,doloop}.tl:
Renamed to stdlib/{defset,doc-lookup,doc-syms,doloop}.tl.
* share/txr/stdlib/{each-prod,error,except,ffi}.tl:
Renamed to stdlib/{each-prod,error,except,ffi}.tl.
* share/txr/stdlib/{getopts,getput,hash,ifa}.tl:
Renamed to stdlib/{getopts,getput,hash,ifa}.tl.
* share/txr/stdlib/{keyparams,match,op,optimize}.tl:
Renamed to stdlib/{keyparams,match,op,optimize}.tl.
* share/txr/stdlib/{package,param,path-test,pic}.tl:
Renamed to stdlib/{package,param,path-test,pic}.tl.
* share/txr/stdlib/{place,pmac,quips,save-exe}.tl:
Renamed to stdlib/{place,pmac,quips,save-exe}.tl.
* share/txr/stdlib/{socket,stream-wrap,struct,tagbody}.tl:
Renamed to stdlib/{socket,stream-wrap,struct,tagbody}.tl.
* share/txr/stdlib/{termios,trace,txr-case,type}.tl:
Renamed to stdlib/{termios,trace,txr-case,type}.tl.
* share/txr/stdlib/{ver,vm-param,with-resources,with-stream}.tl:
Renamed to stdlib/{ver,vm-param,with-resources,with-stream}.tl.
* share/txr/stdlib/yield.tl: Renamed to stdlib/yield.tl.
* share/txr/stdlib/{txr-case,ver}.txr:
Renamed to stdlib/{txr-case,ver}.txr.
* gencadr.txr: Update to stdlib/place.tl.
* genman.txr: Update to stdlib/cadr.tl.
|
|
|
|
|
|
|
|
|
|
|
| |
* genman.txr: generate doc-syms as a sorted list fed to
hash-from-pairs. Now the symbols won't jump around so much
whenever we update it. Also, the names must be HTML-decoded.
For instance "str<" was being stored as "str<" causing
(doc 'str<) to fail. We use TXR @(output) to adjust the
formatting as if it were maintained by hand.
* share/txr/stdlib/doc-syms.tl: Regenerated.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit relies on parallel improvements
in man2html, up through commit
ac186529b6b5f80906c3215a67c98505db7bb156
"Implement .M2HT request for HTML passthrough."
* genman.txr: Add CSS block targetting the kbd element,
providing 3D styling for keyboard input.
* txr.1: Define two new macros, .key and .keyn.
These are defined in three different ways: in man page
output, we put square brackets around keystrokes.
In typeset groff output, we put a square border around
them using a box macro cribbed from groff documentation.
In HTML, we use .M2HT to wrap a <kbd> tag around the
keystrokes. Documentatio is updated to use these macros
for all keystrokes. We no longer separate keystroke
sequence elements with commas.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* genman.txr: dump contents of symhash into a doc-syms.tl
library file, as a defvarl form.
* lisplib.c (doc_instantiate, doc_set_entries): New static
functions.
(lisplib_init): Register autoload for doc-lookup module
to symbols doc and *doc-url*.
* share/txr/stdlib/doc-lookup.tl: New file.
* share/txr/stdlib/doc-syms.tl: Likewise.
* txr.1: Documented.
|
|
|
|
|
|
| |
* genman.txr: Use an alternative solution for dl.items
elemens which places short items to the left of their
definining text, while allowing long items to overhang.
|
|
|
|
|
| |
* genman.txr: add CSS rules targeting <dl class="items">,
which are now supported in man2html.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* genman.txr: show the toggle as "expand all" initially.
Assign the sections of the TOC to the "tocsec" class,
and then select the elements by class rather than by the
dl element type. This avoids selecting the dl that wraps
the entire TOC.
(xpanded): New boolean variable.
(toggleall): Base toggle on boolean variable rather than
the state of the first section dl element.
Toggle the xpanded variable.
|
|
|
|
|
|
|
|
|
|
|
| |
Planning to support seeded hashing, so the behavior of the
hashing function will change. But we need a stable hash for
the section URL's in the HTML doc; so let's preserve the
existing function as Lisp code.
* genman.txr (hash-str): New string hashing function. This
behaves like the existing hash-equal behaves on 32 bits.
(hash-title): Use hash-str instead of hash-equal.
|
|
|
|
|
|
|
| |
* genman.txr (closedtxt, opentxt): Add leading space.
In TOC filtering code, insert the toggle elements
just before the closing </dt> rather than before
opening <a>.
|
|
|
|
|
| |
* genman.txr: Recognize the form of the table-of-contents
line with the extra blank line generated by the .coSS macro.
|
|
|
|
|
|
|
|
| |
* genman.txr: Hack: put <dd> before nested <dl> element
in table of contents. Without this, the nested lists
are rendered flush left by Google Chrome. With this, they
are indented. Chrome adds ugly whitespace around the embedded
definition lists, but it's better than no identation.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Dropping the document feature that hyperlinks
in the TXR section resolve to TXR topics,
and TXR Lisp hyperlinks go to TXR Lisp topics.
All multiple uses of symbols are handled through
the new mechanism of disambiguating topic navigators.
* genman.txr (txrhash, txlhash, tgthash): Variables
removed.
(symhash): One variable, replacing those three.
BODY collecting loop no longer collects LOOKUP
variable, since body lines are not associated
with a particular hash.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The purpose of this change is to handle situations where a
symbol has multiple meanings, resulting in different topic
areas of the document where we might want to navigate. For
instance, there is an equal function in the TXR Lisp library,
and an equal method that users can define.
* genman.txr (tochash, disamb, dist-counter): New variables.
(process-ambiguities): New Lisp function.
When collecting symbol/jump-tag associations, collect
the lists of jump tags rather than just the first jump tag.
Then process the hash using process-ambiguities to
handle the cases with multiple entries, which are prepared
in the disamb hash. The contents of the disamb hash turn
into HTML material at the end of the page.
An in-line style sheet is now added; it adds vertical space
between the navigation menus so they appear as if they
were separate web pages.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* genman.txr: Call set-hash-str-limit to set a generous
limit for string hashing, which restores the old hash
values in the HTML document, preserving the validity of
existing URLs.
* hash.c (hash_str_limit, hash_rec_limit): New
static variables.
(HASH_STR_LIMIT, HASH_REC_LIMIT): Preprocessor
symbols removed.
(hash_c_str, equal_hash): Use hash_str_limit.
(gethash_c, gethash, gethash_f, gethash_n, remhash,
hash_equal): Use hash_rec_limit.
(set_hash_str_limit, set_hash_rec_limit): New static
functions.
(hash_init): Register sys:set-hash-str-limit and
sys:set-hash-rec-limit intrinsics.
|
|
|
|
|
|
|
|
| |
Requires updated man2html which puts out lower case.
* genman.txr: All matched and generated HTML is lower case.
* txr.1 (NP*): Use lower case h4 tag in M2SS macro.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Issue: wrong [+] changes to [-], leading to
inconsistent state.
* genman.txr: In TOC extraction and transformation,
we fix the stupid broken <DT>....<DD> that man2html puts
out and turn it into <DT>...</DT>. This way a DL
now has a DT element as its previous sibling.
(tocjump): When we see a DL now, we get the correct
element which has the expand/collapse: the previous
sibling which is a DT containing the anchor.
|
|
|
|
|
| |
* genvim.txr: Below Contents, place a note for users who
have disabled Javascript.
|
|
|
|
|
| |
* genvim.txr: For some reason, we were generating a second
<title> tag, with different contents.
|
|
|
|
|
|
|
|
|
|
|
|
| |
When a section number is clicked, if the table of contents
section which contains it is collapsed, open it, and its
parents.
* genman.txr: (tocjump): New JS function. add onclick action
to jump-back links, which calls tocjump JS function which does
the expansion. The name anchor entries in the TOC are tagged
with a "tocanchor: class so they can be more specifically
selected by the tocjump function.
|
|
|
|
|
|
|
|
|
| |
Section numbers are now hyperlinks which jump back to their
respective table of contents entry.
* genman.txr (toc-tag): New function.
Generate link anchors into section titles.
Generate name anchors in TOC.
|
| |
|
|
|
|
|
|
| |
* genman.txr: TOC extraction code renames Index
to Contents, and adds expand/collapse links.
Javascript added to handle expand/collapse.
|
|
|
|
|
|
|
|
|
|
| |
For instance, both entries in the TOC titled "Overview"
navigate to the the same section when we click on them.
* genman.txr (tagnum): New hash for counting duplicate
occurrences of section title.
(enumerate): New function for adding numeric suffix
to titles which are the same as previously seen titles.
|
| |
|
|
|
|
|
|
|
| |
* genvim.txr (txr_escat): New match category containing \@.
Colorized a String.
(txr_quasilit): Contains txr_escat. Thus, \@ looks like any
other escape inside a quasilit.
|
|
|
|
| |
before a function link.
|
|
|
|
| |
more places such as examples and summary lists.
|
| |
|
| |
|
|
|
|
|
|
| |
values derived from the title text, so that when sections are inserted
or deleted, the URL's remain stable. The PREAMBLE is gone, and
VERSION is collected when processsing the body.
|
|
|
|
| |
Page date is converted to a time value, and later formatted.
|
|
|
|
|
| |
* txr.1: Avoid escapes at the end of a line; man2html doesn't
handle this properly.
|
|
|
|
| |
* txr.1: More formatting and wording fixes.
|
|
|
|
|
|
|
| |
and restructured in some places.
* genman.txr: No longer generate the whole document in
monospaced font. Add hyperlinks.
|
| |
|
|
|
|
|
|
| |
* txr.vim: Fixed mistakes in a few regex character classes,
causing upper case letters not to be recognized as part
of a variable name, and character hex constant.
|
| |
|
| |
|
|
|
|
| |
Added comment about where to find the right man2html.
|
| |
|
| |
|
| |
|