1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00
Commit graph

32 commits

Author SHA1 Message Date
Ludovic Courtès
a43aa1bc79 texinfo: Add basic support for @w{...}.
* module/texinfo.scm (texi-command-specs): Add 'w'.
(space-significant?): Add it.
* module/texinfo/html.scm (tag-replacements): Add 'w'.
* test-suite/tests/texinfo.test ("test-texinfo->stexinfo"): Add test.
2020-06-18 00:30:30 +02:00
Ludovic Courtès
ff14b77ff5 texinfo: Properly render @acronym in plain text.
Fixes <https://bugs.gnu.org/37846>.
Reported by Christopher Baines <mail@cbaines.net>.

* module/texinfo/plain-text.scm (acronym): New procedure.
(tag-handlers): Change 'acro' handle to ACRONYM, and add 'acronym'
handler.
* test-suite/tests/texinfo.plain-text.test ("stexi->plain-text")
["acronym", "recursive acronym"]: New tests.
2020-01-29 15:19:37 +01:00
Ludovic Courtès
c4b2bd3781 texinfo: Add '*line-width*' fluid to control line wrapping.
* module/texinfo/plain-text.scm (*line-width*): New variable.
(wrap*): Honor it.
* doc/ref/texinfo.texi (texinfo plain-text): Document it.
* test-suite/tests/texinfo.plain-text.test: New file.
* test-suite/Makefile.am (SCM_TESTS): Add it.
2020-01-29 15:19:37 +01:00
Andy Wingo
4e327a2e21 Merge from stable-2.2 2019-08-02 15:21:59 +02:00
Christopher Baines
4c1901b90f stexi->shtml: Add support for @i, @math, @tie and @dots.
* module/texinfo/html.scm (tag-replacements): Add support for @i
and @math.  The tags used come from the texinfo documentation.
(rules): Convert @tie and @dots to the appropriate HTML entities.
2019-06-18 10:05:55 -04:00
Andy Wingo
c248ea10be Remove all deprecated code
* module/ice-9/debug.scm:
* module/ice-9/mapping.scm:
* module/ice-9/syncase.scm: Delete these deprecated files.
* module/Makefile.am: Remove deleted files.
* libguile/deprecated.c:
* libguile/deprecated.h:
* libguile/backtrace.c:
* libguile/goops.c:
* libguile/numbers.c:
* libguile/socket.c:
* libguile/srfi-13.c:
* module/ice-9/deprecated.scm:
* module/ice-9/format.scm:
* module/oop/goops.scm:
* module/statprof.scm:
* module/texinfo/reflection.scm:
* module/web/client.scm:
* module/web/uri.scm: Remove deprecated code.
2017-05-22 13:36:42 +02:00
Ludovic Courtès
7a32add5dc texinfo: Remove unnecessary (oop goops) dependency.
* module/texinfo/string-utils.scm: Remove #:use-module (oop goops).
2017-03-01 19:28:04 +01:00
Andy Wingo
06e4091c9c Texinfo serialization: add braces when needed
* module/texinfo/serialize.scm (include, empty-command, inline-text):
  (inline-args, inline-text-args, eol-text-args, eol-text, eol-args)
  (environ, table-environ, paragraph, item, entry, fragment, serialize)
  (stexi->texi): Pass extra rest? parameter around to indicate arguments
  that can take any number of subforms without being surrounded by
  braces.
  (embrace, serialize-text-args): Surround non-rest arguments with
  braces.
* test-suite/tests/texinfo.serialize.test: Add tests.
2016-10-11 22:08:03 +02:00
Andy Wingo
bd65845497 Fix texinfo->html for @acronym, @itemize
* module/texinfo/html.scm (itemize, acronym, tag-replacements, rules):
  Fix HTML serialization of @itemize and @acronym.  Fixes #21772.
* test-suite/tests/texinfo.html.test: New file.
* test-suite/Makefile.am: Add new file.
2016-06-24 17:09:39 +02:00
Mark H Weaver
f6ddf827f8 Improve correctness and consistency of 'eval-when' usage.
* module/ice-9/boot-9.scm:
* module/ice-9/i18n.scm:
* module/ice-9/poll.scm:
* module/ice-9/popen.scm:
* module/ice-9/r6rs-libraries.scm:
* module/oop/goops.scm:
* module/oop/goops/compile.scm:
* module/oop/goops/dispatch.scm:
* module/srfi/srfi-88.scm:
* module/system/foreign.scm:
* module/texinfo/serialize.scm: Change most uses of 'compile' to
  'expand', except where we must avoid it during initial bootstrap
  before the module system is loaded.  Remove redundant uses of
  'compile' where 'expand' is also given.  Standardize on the
  "(expand load eval)" order of conditions.
2014-01-23 10:41:22 -05:00
Ludovic Courtès
e8a57fb052 texinfo plain-text: Use match' for stexi->plain-text'.
* module/texinfo/plain-text.scm (def)[list/spaces]: Remove.
  (stexi->plain-text): Use `match' instead of `cond'.
2013-03-22 22:09:05 +01:00
Ludovic Courtès
43c2a48323 texinfo: Add whitespace after periods.
* module/texinfo/string-utils.scm (end-of-sentence?): New procedure.
  (make-text-wrapper): Append an extra space after LINE when it matches
  `end-of-sentence?' and COLLAPSE-WHITESPACE? is false.
* test-suite/tests/texinfo.serialize.test ("test-serialize"): Adjust
  accordingly.
* test-suite/tests/texinfo.string-utils.test ("text wrapping")["two
  spaces after end of sentence"]: New test prefix.
2013-03-22 22:05:23 +01:00
Ludovic Courtès
2bb7a73013 texinfo plain-text: Properly render @dots{}.
* module/texinfo/plain-text.scm (tag-handlers): Add `dot' handler.
2013-03-21 23:24:46 +01:00
Andy Wingo
ff95e10225 (texinfo docbook): informaltable is a block element.
* module/texinfo/docbook.scm (*sdocbook-block-commands*): informaltable
  is a block element.
2013-02-09 18:19:06 +01:00
Andy Wingo
9cdc5cdbe6 (texinfo plain-text): Pass @math{} through as-is.
* module/texinfo/plain-text.scm (tag-handlers): Pass `math' through
  as-is.
2013-02-09 18:18:28 +01:00
Andy Wingo
d4cab459d3 (texinfo serialize): don't break words when wrapping
* module/texinfo/serialize.scm (wrap): Don't break long words by
  default; that could break @-commands.
2013-02-09 18:17:48 +01:00
Andy Wingo
0eba699d12 docbook->texi fix
* module/texinfo/docbook.scm (*sdocbook->stexi-rules*): Only convert
  ulink to uref if there is a URL attribute.
2012-05-08 16:03:54 +02:00
Andy Wingo
520850ad27 (texinfo docbook) support for @acronym
* module/texinfo/docbook.scm (*sdocbook->stexi-rules*): Recognize
  "acronym" as parsing to the @acronym texinfo command.
2012-05-07 20:39:14 +02:00
Andy Wingo
be52f329b6 add support for texinfo parsed arguments, like @acronym
* module/texinfo.scm (texi-command-specs): Add a new kind of texinfo
  command, inline-text-args, a sort of a cross between inline-args,
  which are unparsed, and inline-text, which is.  Perhaps this should
  supersede inline-args at some point.  In any case, add acronym as an
  inline-text-args element.
  (inline-content?, arguments->attlist, complete-start-command)
  (parse-inline-text-args, make-dom-parser): Adapt for
  inline-text-args.

* module/texinfo/serialize.scm (inline-text-args): Add serialization for
  @acronym.

* test-suite/tests/texinfo.test ("test-texinfo->stexinfo"): Add some
  tests.
2012-05-07 20:29:14 +02:00
Bake Timmons
91a214ebd9 Improve the usage of variable names in Scheme docstrings.
* module/ice-9/boot-9.scm:
* module/ice-9/popen.scm:
* module/ice-9/pretty-print.scm:
* module/ice-9/r4rs.scm:
* module/rnrs/io/ports.scm:
* module/texinfo/string-utils.scm:
* module/web/http.scm:
* module/web/request.scm:
* module/web/response.scm:
* test-suite/vm/run-vm-tests.scm: Make the variable names in Scheme docstrings more
  consistent.  Replace a few instances of @var with @code when appropriate.
2012-02-02 12:24:40 +01:00
Andy Wingo
9447207f0c Use default value for make-fluid in Scheme files
* module/ice-9/boot-9.scm (%exception-handler)
  (%running-exception-handlers, read-eval?, *repl-stack*)
  (make-mutable-parameter):
* module/ice-9/getopt-long.scm (%program-name):
* module/language/elisp/runtime.scm (built-in-macro, defspecial):
* module/srfi/srfi-39.scm (make-parameter/helper):
* module/system/base/language.scm (*current-language*):
* module/system/base/message.scm (*current-warning-port*):
  (*current-warning-prefix*):
* module/system/base/target.scm (%target-type, %target-endianness)
  (%target-word-size):
* module/texinfo/plain-text.scm (*indent*, *itemizer*):
* benchmark-suite/lib.scm (prefix-fluid):
* test-suite/lib.scm (prefix-fluid): Give fluids a useful default
  value.
2011-11-23 12:54:09 +01:00
Andy Wingo
35c0f0672e module-stexi-documentation #:docs-resolver keyword arg
* module/texinfo/reflection.scm (module-stexi-documentation): Make
  #:docs-resolver a keyword argument.  Provide back compat with
  docs-resolver as an optional argument, though.
2011-08-23 18:00:02 +02:00
Andy Wingo
38c50a99b6 fix stexi->html double translation
* module/texinfo/html.scm (entry): Fix to avoid double translation:
  arg-req already pulls an stexi->shtml on its arg.
2011-03-26 13:33:40 +01:00
Andy Wingo
362126aa96 fix (texinfo reflection) to handle nested structures like syntax patterns
* module/texinfo/reflection.scm (process-args): Convert any arg to a
  string.  "Fixes" documentation of syntax-rules patterns.
2011-03-26 13:33:40 +01:00
Andy Wingo
c32f0d6b87 stexi->shtml supports itemx
* module/texinfo/html.scm (entry, rules): Allow @itemx,
2011-01-25 17:59:45 +01:00
Ludovic Courtès
ac37b82d5b Fix typos.
* module/system/repl/repl.scm (run-repl): Fix variable name: `k', not
  `key'.

* module/texinfo/docbook.scm: Use `(srfi srfi-1)' for `fold'.
2010-09-02 00:04:39 +02:00
Andy Wingo
07e424b753 scm_i_program_properties is internal; just use procedure-properties
* libguile/programs.h:
* libguile/programs.c (scm_i_program_properties): Make internal.
  (scm_program_name): Use scm_i_program_properties.

* libguile/procprop.c (scm_procedure_properties): Use
  scm_i_program_properties, for programs.

* libguile/procs.c (scm_procedure_documentation): Use procedure-property
  to get to 'documentation, not program-property.

* module/system/vm/program.scm (program-properties, program-property):
  Remove from the exports list.
  (program-documentation): Use procedure-property.

* module/texinfo/reflection.scm (macro-arguments)
  (macro-additional-stexi)
  (object-stexi-documentation): Use procedure-property, not
  program-property.
2010-04-17 15:21:08 +02:00
Andy Wingo
4f08d0b50f (texinfo reflection) parses out macro metadata
* module/texinfo/reflection.scm (macro-arguments):
  (macro-additional-stexi, object-stexi-documentation): Parse out the
  metadata in macros, if it is available, so we can show defmacros'
  arguments, syntax-rules' patterns, etc.
2010-03-29 18:12:37 +02:00
Andy Wingo
8470b3f45b fix texinfo reflection for procedures
* module/system/vm/program.scm (program-arguments-alist): Rename from
  program-arguments, a name shadowed by features.c
  (arglist->arguments-alist, arity->arguments-alist)
  (arguments-alist->lambda-list, program-lambda-list, write-program):
  Adapt callers.

* module/system/vm/frame.scm (frame-lookup-binding): Return #f if the
  binding is not found, not an error.
  (frame-binding-set!, frame-binding-ref): Adapt to error appropriately.
  (frame-arguments): Dispatch to frame-call-representation.
  (frame-call-representation): Refactor a bit.

* module/ice-9/session.scm (procedure-arguments): Adapt to
  program-arguments name change.

* module/texinfo/reflection.scm (get-proc-args): Refactor to actually
  work with VM procedures.
2010-01-12 22:50:10 +01:00
Ludovic Courtès
6734191c68 Remove unused top-level variables.
* module/ice-9/runq.scm (fork-strips): Remove.

* module/language/assembly.scm (*block-alignment*): Remove.

* module/language/assembly/disassemble.scm (disassemble-objects,
  simplify): Remove.

* module/srfi/srfi-18.scm (mutex-owners): Remove.

* module/srfi/srfi-19.scm (leap-year?): Remove.

* module/system/base/compile.scm (dsu-sort): Remove.

* module/texinfo.scm (ascii->char): Remove.

* module/texinfo/html.scm (ignored?): Remove.

* module/texinfo/indexing.scm (def-name): Remove.

* module/texinfo/plain-text.scm (ignore): Remove.
2010-01-11 01:21:14 +01:00
Andy Wingo
c55cb58ac1 integrate guile-lib docs 2009-12-21 00:01:49 +01:00
Andy Wingo
47f3ce525e import statprof, sxml, and texinfo from guile-lib
* module/Makefile.am (LIB_SOURCES): Add statprof, sxml, and texinfo to
  the build.
  (NOCOMP_SOURCES): Reindent, and add the upstream SSAX files.

* module/statprof.scm:
* module/sxml/apply-templates.scm:
* module/sxml/fold.scm:
* module/sxml/simple.scm:
* module/sxml/ssax.scm:
* module/sxml/ssax/input-parse.scm:
* module/sxml/transform.scm:
* module/sxml/upstream/COPYING.SSAX:
* module/sxml/upstream/SSAX.scm:
* module/sxml/upstream/SXML-tree-trans.scm:
* module/sxml/upstream/SXPath-old.scm:
* module/sxml/upstream/assert.scm:
* module/sxml/upstream/input-parse.scm:
* module/sxml/xpath.scm:
* module/texinfo.scm:
* module/texinfo/docbook.scm:
* module/texinfo/html.scm:
* module/texinfo/indexing.scm:
* module/texinfo/plain-text.scm:
* module/texinfo/reflection.scm:
* module/texinfo/serialize.scm:
* module/texinfo/string-utils.scm: Add files from guile-lib to Guile.
  It's only Richard, Andreas, Rob, and myself that have copyright on
  these, and we have all assigned to the FSF. SSAX itself is in the
  public domain.
2009-12-21 00:01:13 +01:00