Commit Graph

141 Commits

Author SHA1 Message Date
Leif Andersen
67bfe3af4a
Parameterize figure captions by language. (#173)
* Acmart font requirements
* Parameterize for different languages.
* Update acmart to v1.53
* Added three new document types to match acmart 1.53
2018-05-11 17:25:24 -04:00
Ben Greenman
86cfc8b7f9 doc: typo, 'it if it' 2018-05-07 19:18:36 -04:00
Ben Greenman
e07fac631c typo: 'line-number-sep' => 'line-number-sep-expr' 2018-02-11 20:24:04 -05:00
Ben Greenman
ed0e87d54d doc: example include-section for scribble/lp2 2018-02-11 20:24:04 -05:00
Matthew Flatt
00739632cf tabular: add #:sep-properties
Also, correct the documentation about the interaction of
`#:sep` and property lists, and make the previous column's
properties used consistently for a separator column.
2018-01-04 11:03:36 -07:00
Matthew Flatt
9c5a45985b html-properties: add xexpr-property
For injecting literal HTML (or, using `cdata`, literal anything) into
the rendered HTML of a document. If you must.
2017-12-28 16:22:07 -06:00
Matthew Flatt
5f29095f02 scribble/book-index: more book-like index style for Latex/PDF
Merge index entries that have the same key and use cleveref to
render the page-number sequence.
2017-12-18 11:07:02 -07:00
Leif Andersen
564f441d99 Add authorsaddresses field to acmart
This was added in a recent version of the acmart style and is
required to set (or remove) the addresses field at the bottom of
the first page in some styles.
2017-10-18 20:38:03 -04:00
Matthew Flatt
7278568040 section links plus scriblib/{autobib,figure}: better match acmart
Add a `link-render-style` syntax property to control the rendering of
section links --- so that HTML output can say "section <number>", and
so that Latex/PDF output can have just the section number hperlinked
(as in acmart).

It seems unfortunate that the link rendering is so hardwired into each
rendering back-end, but maybe this can be made even more configurable
in the future. Meanwhile, Latex macros already provide an additional
layer of rendering control (but not enough, it turns out, to easily
perform the same adjustments as the 'number mode that matches acmart).

For `scriblib/figure` make `figure-ref` and `Figure-ref` similarly
sensitive to the link-rendering style.

For `scriblib/autobib`, change the hyperlinking of references
so that the color can be overridden, and make `scribble/acmart`
override it.
2017-10-11 11:19:44 -06:00
Matthew Flatt
1e81f0005a scribble/decode: add 'no-index to avoid part titles in index
Using 'no-index makes sense for a book, for example.
2017-10-09 08:34:23 -07:00
Matthew Flatt
dd92ebd2d9 acmart: fix contract on nested-flow forms, like acks
A nested flow's argument to be decoded a pre-flow instead of a
pre-content.
2017-09-08 16:37:24 -06:00
Asumu Takikawa
77a46f46c7 Add doc examples for @author and @author+email 2017-09-08 12:35:18 -07:00
Ben Greenman
9fc96fc56e doc: require 'scribble/example' in 'examples' example
Also increase the memory limit in the example.
(On my machine, this example fails if the memory limit is 37MB or less.)
2017-08-31 00:29:40 -04:00
Matthew Flatt
9f5fe0859d change base handling of convertible values as content
If a value is convertible to 'text, then use that conversion.

Otherwise, convert using `write` instead of always using "???".

Also, correct documentation to include convertible values among
the valid forms of content, and document the new conversion rules
there.
2017-08-21 08:41:09 -06:00
Matthew Flatt
6587e4f5ea index style-property symbols 2017-07-27 08:20:59 -06:00
Ben Greenman
c4b4e4c929 acmart: a little better for empty documents
1. Change `add-acmart-styles` to add an element WITHOUT the `pretitle` style
   for the collects phase. With this, an empty `#lang scribble/acmart` document
   builds an empty PDF.
2. Add documentation for a "minimal" `scribble/acmart` document.
2017-06-22 20:11:37 -04:00
Ben Greenman
800d08fbef doc: fix 'scribble-eval-handler' order of arguments
Change the documented order of arguments to match the implementation / uses
 in `scribble/eval.rkt` and `scriblib/gui-eval.rkt`
2017-06-11 12:21:58 -04:00
Leif Andersen
4c8ac8e021
Fix contract docs for departments in scribble/acmart.
(I placed the wrong contract in the docs. The correct one is the one
defined in the module.)
2017-05-23 14:22:39 -04:00
Ben Greenman
71bd7ddae0 doc: point 'tabular #:style' to 'table' docs 2017-05-20 18:12:42 -04:00
Leif Andersen
ba2e1d6ca7 Top-matter text needs to be 'pretitle.
As per the acmart pdf, top matter matterial needs to appear
before the `\maketitle` command. As such, we need to use the
`pretitle` paragraph style.
2017-05-17 13:51:46 -04:00
Leif Andersen
b62bfe3bdf render -> resolve
The documentation for the `resolve-get` family of functions
incorrectly refers to themselves as `render-get`. This commit
fixes that.
2017-05-16 14:38:17 -04:00
Matthew Flatt
18e467ef9e disable _ prefix handling in racketmodname and other places
In places where module names are typeset, such as `racketmodname`,
there's no way to disable the special treatment of `_` as an
identifier prefix as in `racket`. Even using
`make-element-id-transformer` doesn't work, because the module-name
datum is explcitly disconnected from binding withing `racketmodname`.
2017-04-14 06:52:16 -06:00
Robby Findler
725f2bc9ed adjust for new location of 'blame object' @deftech{} 2017-04-12 21:48:08 -05:00
Leif Andersen
8e22565759 Add optional SHyphen Latex macro to prevent hyphens from appearing in @racket[...] identifiers
* Prevent hyphens from appearing in @racket[...] identifiers when they overflow.

* Add SHyphen command.

A style file can redefine SHyphen to toggle how they want to
hyphen their text

* Add documentation
2017-04-12 17:40:16 -04:00
Matthew Flatt
92d9a0732d improve docs on numberers
Closes #96
2017-03-29 07:12:13 -06:00
Leif Andersen
9da2f4f40f Add a pretitle style property for nested flows. (#94)
* Add a pretitle style property for nested flows.

This allows us to raise nested flows above the title. So that we do
things like raise the abstract above the title:

```
\begin{abstract}
Abstract text
\end{abstract}
\titleCommand{...}
```

This style is required by the acmart style guide.

* Paragraphs and nested flows extracted in the same order

* Fix `scribble/acmart`'s abstract form so that it gets lifted above `maketitle`, where it should be.
2017-03-25 10:08:18 -04:00
Leif Andersen
a26a7322a5 Latex macros _can_ actually have multiple optional args.
While done as a tex hack, macros in latex can have multiple optional
arguments. As such, we should support it with command-optional.

Meaning that the type of command-optional-arguments is now (Listof String)
2017-03-22 19:42:21 -04:00
Leif Andersen
558a8a5c64 Improve the scribble/acmart language
The existing scribble/acmart language in this repo felt more like latex than Scribble. This package brings scribble/acmart more inline with the existing `scribble/acmart` package that was already on the package server. In particular, this commit:

* Remove maketitle from scribble/acmart

* Extends the title form to also have the fields in `scribble/base`'s title.

* Support author information. (Like scribble/sigplans authorinfo)

* Removed unneeded functions now redundant due to the author function. Namely, affiliation based ones.

* Factor out common functions to scribble/acmart and scribble/base into private module.

These functions might make sense to be public, but since they were already private in base
I thought it made sense to leave them that way. Additionally, it might make sense to have the
file be something other than private/tag, as private/tag currently requires tag, which is
different than the normal way where its tag that requires private/tag.

* Add short-title to scribble/latex-properties

* Adds an `command-optional` property which is like `command-extras`, but is a single
optional argument placed before the mandatory ones.

* Create email, affiliation, and institution structs so that authors can have multiple of each.

* Add/improve documentation and history (and bump version number).
2017-03-21 01:06:02 -04:00
Ben Greenman
82860694a2 add font size options to scribble/acmart
Just like the 10pt option in `scribble/sigplan`,
 putting @9pt @10pt @11pt or @12pt on the #lang line of a `scribble/acmart`
 document passes to corresponding string to `\documentclass[....]`

And just like TeX, it's ok to give multiple font sizes. All but the last
 are ignored.
2017-03-17 09:39:20 -04:00
David Van Horn
049bf4b07a Scribble support for new acmart.cls. (#85)
Scribble support for new acmart.cls.
2017-03-10 16:24:27 -07:00
Matthew Flatt
68c4557968 catch up docs on --xelatex
Also, adjust help text for `--doc-binding` to make it
fit in 80 columns, and clean up related documentation text.
2017-03-03 07:47:45 -07:00
Ben Greenman
70586da699 typo: 'a a' -> 'a' 2017-03-03 02:07:57 -05:00
Ben Greenman
4fc7b93f6d typo: Examples -> Example
Because there's only 1 code snip.
2017-03-03 01:26:51 -05:00
Daniel Feltey
e3db079c22 Update the documented contract for xref-binding->definition-tag to reflect its description in text 2017-02-08 16:43:47 -06:00
Robby Findler
574219e1ee remove the style guide 2017-01-05 17:45:12 -06:00
Robby Findler
531ad440b7 add dictat about predicates as nouns 2017-01-04 09:18:00 -06:00
Matthew Flatt
f224034a1f "Mac OS X" -> "Mac OS" 2016-12-23 12:37:32 -07:00
Jay McCarthy
6564d5999c Adding docs for doc-binding 2016-11-30 13:55:52 -05:00
Leif Andersen
6b261eb6f8 Add an example for defstruct* 2016-11-14 15:58:56 -05:00
Ben Greenman
1676671ee0 update HTML tags, add scribble/html/extra
This commit adds:
+ a few tags to `scribble/html` (by extending the list in `scribble/html/html`)
+ even more tags to `scribble/html/extra`,
  these tags are "likely" to cause namespace issues (time, map)
  or are uncommon / esoteric (rb, ruby, svg)
+ a test in `scribble/html.rkt` that the tags from
  - `scribble/html/html`
  - and `scribble/html/extra`
  match a master list from the whatwg specification*

* https://html.spec.whatwg.org/multipage/#toc-semantics
2016-11-07 12:23:19 -05:00
Vincent St-Amour
fc57dd624a Move doc example for raw @ sign.
At Eli's suggestion.
2016-10-24 10:54:35 -05:00
Vincent St-Amour
f9cc826d5b Add example for a raw @ sing in the at-exp docs. 2016-10-13 15:10:34 -05:00
Matthew Flatt
30ae71202d fix references lifted to table of contents
Certain lifted reference forms carried the prefix of the original
section, but in general the section needs to be similarly carried for
rendering elements that may contain references.

Also, fix the contract on `elemref` and `elemtag` to use
`taglet?` instead of `tag?`.

Thanks to Dupéron Georges.
2016-10-01 10:51:18 -06:00
Vincent St-Amour
cce1eff495 Extend special characters using a function rather than a dict.
Based on feedback from David Van Horn.
2016-08-24 16:14:03 -05:00
Vincent St-Amour
525b72ca4c Make the list of special characters user-extensible . 2016-08-24 16:14:03 -05:00
Vincent St-Amour
78a517a34d setup-plt -> raco setup
Survived unnoticed for 6+ years.
2016-08-24 15:27:58 -05:00
Benjamin Greenman
f488ed28f3 typo: "for and" 2016-08-09 13:25:39 -04:00
Asumu Takikawa
f4f3354466 Add doc examples for history form 2016-07-21 13:50:01 -04:00
ben
7836b78809 scribble/jfp: affiliation-mark example 2016-07-11 14:53:30 -04:00
Ben Greenman
2b972d9cc9 doc: add missing index-desc field descriptions 2016-07-08 22:28:53 -04:00
Ben Greenman
5505a5557a Add language-index-desc and reader-index-desc
Subtypes of module-index-desc.
Used to tell if a module implements a #lang or a #reader module.
2016-07-08 17:56:35 -04:00
Leif Andersen
c34a69c623 Update the docs to mention the search-box parameter in the html mixin. 2016-06-15 15:24:36 -04:00
Matthew Flatt
e92229f481 doc: explain indentation and workaround for racketresultblock 2016-03-07 19:21:39 -07:00
Sam Caldwell
f6460dac5e fix typo in how-to 2016-03-04 16:41:35 -05:00
ben
d51825b95e example usage of 'other-doc' 2016-01-25 11:51:31 -05:00
Matthew Flatt
798155c4f9 add make-numberer to generalize section numbering 2016-01-09 20:21:18 -07:00
Spencer Florence
2881ef290d Allow for manipulating scribble.tex imports 2016-01-09 11:48:21 -06:00
Matthew Flatt
0f0d662b14 scribble/lp2: strip code:comment, etc. 2015-12-30 07:22:15 -06:00
Matthew Flatt
bbbd68b3c2 declare-exporting: allow escaped module-path expressions 2015-12-30 06:54:51 -06:00
Matthew Flatt
f09604f097 scribble/lp2: declare doc submodule with module*
Using `module*` allows the documentation submodule to refer to the
implementation module.
2015-12-30 06:24:17 -06:00
Matthew Flatt
d2bf2e49c5 move scribble/examples to scribble/example
Use singular to follow the naming convention of the style guide.
2015-12-18 06:28:27 -07:00
Matthew Flatt
90455e2d6a add tests for examples 2015-12-13 09:09:33 -07:00
Matthew Flatt
ad9a465ab1 Latex: 'inset style renders through a SInsetFlow environment 2015-12-13 07:40:26 -07:00
Matthew Flatt
50f835c4f1 add scribble/examples
The `scribble/examples` library provides a cleaner and more modern
interface for evaluation compared to `scribble/eval`.
2015-12-11 11:54:07 -07:00
Matthew Flatt
f1f47c5f16 scribble/examples: revert logging change, add options
The error-logging change in 81aeab1687 didn't work well for me
in further experiments. Change `interactions`, etc., to have a
`#:no-errors?` argument, instead. Also, add `eval:no-prompt`,
which provides an alternative to `def+int`.

Improve the documentaiton by correcting mistakes and filling
in some missing exports.
2015-12-11 10:03:31 -07:00
Matthew Flatt
81aeab1687 scribble/eval: add eval:error and logging of other exceptions
When an expression in `examples` or `interactions` raises an
exception, the error message is rendered as part of the documentation.
Now, however, unless the expression is wrapped with `eval:error`, an
error is also logged.

Logging an error is a compromise between backward compatibility (for
documents that rely on undeclared but expected errors) and making a
document fail completely (which would be nicer when an error is not
expected).
2015-12-10 08:33:00 -07:00
Matthew Flatt
6b8490b78b scribble/sigplan: add to-appear 2015-11-23 12:22:31 -07:00
Vincent St-Amour
9c26539b71 Add missing history annotations.
Please merge to 6.3.
2015-10-12 14:41:11 -05:00
Matthew Flatt
296e55d0e0 correct docs on code:contract
Unfortunately, `scribble/manual` and `pict/code` differ on how they
color `code:contract` content.
2015-10-02 15:36:12 -06:00
Matthew Flatt
a2f430020a scribble/eval: strip away code:contracts
Make `code:contract` handled like `code:comment` for evaluation.

Relevant to PR 15161
2015-10-02 15:24:08 -06:00
Matthew Flatt
26eff4c03a fix racketblock docs on code:comment and code:contract 2015-10-02 15:24:08 -06:00
William J. Bowman
ea01ae2f68 Added example of @tech with #:doc
I never remember how to use this.
2015-09-17 11:14:09 -05:00
Leif Andersen
94804a1579 Fix types in sigplan documentation 2015-09-09 13:18:07 -04:00
Matthew Flatt
e0a14fa28d tabular: fix insertion of separator before 'cont
Use 'cont before a 'cont cell instead of adding a separator.
2015-08-04 09:44:36 -06:00
Matthew Flatt
0ea9922784 fix doc typo 2015-07-30 14:54:48 -06:00
Vincent St-Amour
ea70707036 Merge unstable/sandbox with scribble/eval. 2015-07-23 15:04:44 -05:00
Matthew Flatt
4e96e99344 docs: clarify (under)specification of nested default style 2015-05-28 16:22:57 -06:00
Eli Barzilay
117218dc3e Two bugfixes.
* Fix contract on `with-writer`.

* The default writer is initially `write-string`, not `display`.
2015-05-11 16:44:44 -06:00
Robby Findler
c84c1cf6cc document typeset-code
also adjust contract on context-expr to admit that #f is allowed
2015-05-11 08:04:40 -05:00
Matthew Flatt
ea6de4535d fix terminilogy: "Scribble" vs. "@-form" 2015-04-28 10:12:11 -06:00
Robby Findler
3ea5bd2e31 add some missing docs and @history annotations from commits e6630f0e9 and 39e0f6aec 2015-04-17 05:47:28 -05:00
Robby Findler
39e0f6aecd add some tag predicates and tag manipulation functions 2015-04-15 03:39:32 -05:00
Robby Findler
9b026739ed refactor blueboxes support code to avoid dependency on racket-index pkg 2015-04-12 16:34:32 -05:00
Matthew Flatt
4a52d3c57c racketblock: add "#i" to an inexact number to match source span
This heuristic could go slightly wrong, for example causing "10.000"
to render as "#i10.0" instead of "10.0", but it won't affect cases
where the output already matched the input.
2015-02-21 14:12:38 -07:00
Matthew Flatt
6556e9f92a add x-source-pkg to HTML output 2015-02-15 10:26:43 -07:00
Matthew Flatt
7d69325ada fix overview documentation for scribble/eval 2014-12-29 16:32:52 -07:00
Matthew Flatt
22b0da4cd5 docs: modernize typesetting of "Getting Started with Documentation"
Use `codeblock` instead of `verbatim`.
2014-12-29 16:23:43 -07:00
Matthew Flatt
c388f23424 fixup for previous commit 2014-12-15 18:11:08 -07:00
Matthew Flatt
f9622dabf3 add scribble/lp2
Unlike `scribble/lp` a programm written with `scribble/lp2` can be used
directly, due to its `doc` submodule.
2014-12-15 18:05:14 -07:00
Asumu Takikawa
6d43de50ef Change link to scribble doc sources
The doc sources now live on Github post-split
rather than on the PLT git server.
2014-12-10 22:53:34 -05:00
Sam Tobin-Hochstadt
a316fc12c0 Remove extra directories. 2014-12-02 00:54:52 -05:00