Commit Graph
15800 Commits
Author SHA1 Message Date
Albert Krewinkel 369058d53d T.P.MIME: Removes more unnecessary overrides.
| Ext.  | Old type                 | New type                        |
|-------|--------------------------|---------------------------------|
| fm    | application/x-maker      | application/vnd.framemaker      |
| frame | application/x-maker      | application/vnd.framemaker      |
| gsf   | application/x-font       | application/x-font-ghostscript  |
| java  | text/x-java              | text/x-java-source              |
| kpr   | application/x-kpresenter | application/vnd.kde.kpresenter  |
| kpt   | application/x-kpresenter | application/vnd.kde.kpresenter  |
| ksp   | application/x-kspread    | application/vnd.kde.kspread     |
| kwd   | application/x-kword      | application/vnd.kde.kword       |
| kwt   | application/x-kword      | application/vnd.kde.kword       |
| lha   | application/x-lha        | application/x-lzh-compressed    |
| lhz   | application/x-lhz        | application/x-lzh-compressed    |
| maker | application/x-maker      | application/vnd.framemaker      |
| mif   | application/x-mif        | application/vnd.mif             |
| pl    | text/x-perl              | application/x-perl              |
| pm    | text/x-perl              | application/x-perl              |
| sisx  | x-epoc/x-sisx-app        | application/vnd.symbian.install |
| sitx  | application/x-stuffit    | application/x-stuffitx          |
| skd   | application/x-koan       | application/vnd.koan            |
| skm   | application/x-koan       | application/vnd.koan            |
| skp   | application/x-koan       | application/vnd.koan            |
| skt   | application/x-koan       | application/vnd.koan            |
| tgz   | application/x-gtar       | application/x-tgz               |
| tk    | text/x-tcl               | application/x-tcl               |
| wpd   | application/wordperfect  | application/vnd.wordperfect     |
2022-09-12 11:39:45 +02:00
John MacFarlane c7915208ab Depend on dev texmath. 2022-09-12 10:20:22 +02:00
Albert Krewinkel d327f2a85b T.P.MIME: Remove deprecated overrides (#8292)
This changes the media type that's used for the file extension listed
below. The new types are either IANA approved, or so similar to the
override that is does not seem sensible to keep a separate entry.
2022-09-11 20:46:05 +02:00
Albert Krewinkel c9f4255c80 Fix stack.yaml 2022-09-11 19:09:14 +02:00
Albert Krewinkel 62f5701fb1 Require mime-types 0.1.1
This version has an updated list of media types, which renders some
overrides redundant.
2022-09-11 18:05:41 +02:00
John MacFarlane 415ad3df7b More tweaks to issue template. 2022-09-10 10:09:42 -07:00
John MacFarlane 3f8c736fa6 Revise issue template. 2022-09-10 10:07:54 -07:00
John MacFarlane 35a3fb7e83 Citeproc: Require a digit for an implicit "page" locator...
inside explicit locator syntax `{...}`.

Previously a locator specified as `{}` would be rendered
as `p.` with nothing after it.

Closes #8288.
2022-09-09 10:30:01 -07:00
John MacFarlane 47dcb5720e Docx writer: adjust correct attribute on lang element.
For East Asian languages, we need to adjust `w:eastAsia`
rather than `w:val`.  This allows normal fonts to be used
for any Latin-font text. Similarly, for bidi languages, we need
to adjust `w:bidi` rather than `w:val`.

We treat `he` and `ar` as bidi languages, `zh`, `ja`, `ko`
as East Asian languages.

Closes #7022.
2022-09-05 23:10:48 -07:00
John MacFarlane 86a3467ece HTML writer: only treat . . . as a slide pause in slides...
...and not in regular HTML output.
Closes #8281.
2022-09-05 09:51:59 -07:00
Albert Krewinkel b9a7de32f6 T.P.Mime: Base module on package mime-types. (#8277)
The *mime-types* module is a dependency of *http-client* and therefore
already a transitive dependency of pandoc.
2022-09-04 14:30:57 -07:00
Mathias Walter d5baace0f5 fix a link to an issue (#8271) 2022-09-02 13:36:38 -07:00
John MacFarlane a312faffa8 JATS reader: handle uri element in references.
Closes #8270.
2022-09-01 13:21:27 -07:00
Albert Krewinkel 553416a20d Require hslua-module-version 1.0.3
This fixes the behavior of Lua "Version" objects under equality
comparisons.

Fixes: #8267
2022-09-01 19:28:05 +02:00
Albert Krewinkel ff856e5f94 MANUAL.txt: document syntax of table foots in grid tables 2022-09-01 17:42:34 +02:00
Albert Krewinkel de920cfc30 MANUAL.txt: remove outdated paragraph on grid table limitations 2022-09-01 17:35:41 +02:00
Albert Krewinkel fbffff4f78 Fix stack.yaml 2022-09-01 10:33:31 +02:00
Albert Krewinkel 635b6e3953 Use dev version of gridtables
This allows to specify a table foot by enclosing it with part separator
lines, i.e., row separator lines consisting only of `+` and `=`
characters. E.g.:

    +------+-------+
    | Item | Price |
    +======+=======+
    | Eggs | 5£    |
    +------+-------+
    | Spam | 3£    |
    +======+=======+
    | Sum  | 8£    |
    +======+=======+

The last row, containing "Sum" and "8£", is the table foot.

Closes: #8257
2022-09-01 09:06:42 +02:00
John MacFarlane 751383f333 T.P.Citeproc.CslJson: allow an object with items property...
...in addition to an array of references. This is what is
returned by e.g.
`https://api.zotero.org/groups/904125/items?v=3&q=صحافة&format=csljson`

See comment in #7151.
2022-08-31 10:30:49 -07:00
John MacFarlane 1c4e9d6b05 Citeproc: check both extension and mime type to determine...
...bibliography type when the bibliography is fetched remotely.
This will help with cases where the URL ends in a parameter
or otherwise does not end with a file extension.

Closes #7151.
2022-08-31 09:53:53 -07:00
John MacFarlane b133a8be77 RTF writer: add space after unicode escape commands.
Otherwise the `?` character that is there as a fallback
for systems that can't process the unicode will be interpreted
as the paramater's delimiter, and the NEXT character will be
gobbled instead of `?`.

Closes #8264 (fixes a problem with disappearing characters
after unicode escapes).
2022-08-31 09:44:34 -07:00
John MacFarlane 381ac82222 Add more useful things to shell.nix. 2022-08-31 09:17:12 -07:00
John MacFarlane 3aea194f92 stack.yaml: use lts-19.21 2022-08-30 09:05:40 -07:00
John MacFarlane 6f52c77a7e Markdown: Allow table caption labels to start with lowercase t.
Closes #8259.
2022-08-30 09:05:40 -07:00
John MacFarlane 2d86b8dea9 Require aeson >= 2.0. 2022-08-30 09:05:40 -07:00
PratandPrat T 06c3928986 Produce error if --csl is used more than once (#8252)
Closes #8195.

Co-authored-by: Prat T <pt2121@users.noreply.github.com>
2022-08-30 08:36:08 -07:00
Albert Krewinkel 9b6220c8ed Docx reader: mark unnumbered headings with class 'unnumbered'
If a document uses numbered headings, then headings without numbers are
marked with class `unnumbered`, the default class used by pandoc to
convey this kind of information. The classes are not added if none of
the headings in a document are. This change ensures good conversion
results when converting with `--number-sections`.

Closes: #8148
2022-08-30 10:05:49 +02:00
Albert Krewinkel 7a2e8e51a0 MediaWiki writer: shorten code 2022-08-30 09:59:22 +02:00
Ruqi 8b5fb50198 Mediawiki reader: Parse table cell with attribs, to support rowspan, colspan (#8231) 2022-08-30 09:51:09 +02:00
John MacFarlane fecd3366d8 stack.yaml: add servant-0.19. 2022-08-29 19:21:34 -07:00
John MacFarlane a0df13c9e8 Fix revision to stack.yaml. 2022-08-29 15:21:55 -07:00
John MacFarlane 9bf0b4a0ca shell.nix updates. 2022-08-29 15:21:34 -07:00
John MacFarlane 9b2caa671a stack.yaml - update commonmark-extensions, servant-server deps. 2022-08-29 10:35:27 -07:00
John MacFarlane b682249ada PandocServer: return error in JSON object if response is JSON. 2022-08-29 09:52:32 -07:00
John MacFarlane 37612b22ab PandocServer: set translations in the writer based on lang metadata. 2022-08-28 20:59:09 -07:00
John MacFarlane 603944ac47 Text.Pandoc.Server: return object if JSON is accepted.
Previously we just returned a JSON-encoded string.

Now we return something like:

```
{
    "output": "<p>hello</p>"
    "base64": false,
    "messages": [
        {
            "message": "Not rendering RawInline (Format \"tex\") \"\\\\noe\"",
            "verbosity": "INFO"
        }
    ],
}
```

This is a change in the pandoc-server JSON API.
2022-08-28 20:31:47 -07:00
John MacFarlane 1d92024bcb HTML, Markdown writers: filter out empty class attributes.
These should not be generated by any pandoc readers, but they
might be produced programatically. Technically that's a misuse
of the AST, but since the expectation that the classes are
nonempty strigs is not encoded in the types, it can happen. This patch
limits the damage if it does, preventing invalid markdown attributes
like `{.}` from being written.

Cloess #8251.
2022-08-27 17:30:17 -07:00
John MacFarlane eadcb4f97e Avoid thunk in markdown reader. 2022-08-27 12:13:51 -07:00
John MacFarlane d11f24331e Fix a small space leak in HTML writer. 2022-08-27 11:19:28 -07:00
John MacFarlane 742613fe3c Fix stack.yaml 2022-08-26 21:33:30 -07:00
John MacFarlane e3978247cc HTML writer: avoid aria-hidden in code blocks for HTML4.
Closes #8241.

This requires depending on a new (still unreleased)
version of skylighting-format-blaze-html.
2022-08-26 20:01:01 -07:00
John MacFarlane 6a7ab9bb4e pandoc-server.md: fix documentation for highlight-style. 2022-08-26 16:36:51 -07:00
John MacFarlane e17c6832b1 Docx writer: Indent tables in list items.
Closes #5947.
2022-08-26 15:15:38 -07:00
John MacFarlane a5840d4f3b Move trypandoc to a separate repository.
jgm/trypandoc
2022-08-26 13:16:59 -07:00
John MacFarlane edca1eb738 trypandoc: remove min-width on command pane. 2022-08-26 10:33:13 -07:00
John MacFarlane e012286d7f trypandoc: further polish. 2022-08-26 10:31:23 -07:00
John MacFarlane 8ce32dafab trypandoc: Show binary files as download links rather than base64 blobs. 2022-08-26 10:07:59 -07:00
John MacFarlane 812ef0484d Docx writer: better handling of tables in lists (#5947).
Previously the content of each list cell was indented when
the table belonged to a list item. This is obviously unwanted.
With this patch, a table inside a list item will be formatted
just like a table outside the list.

One desirable improvement would be to add some left indentation
to the entire table, so it visually appears to belong to the
list item. But I'm not sure how to do that.
2022-08-26 08:41:05 -07:00
John MacFarlane 73211ee02b trypandoc: ipynb to rtf example. 2022-08-25 21:55:39 -07:00
John MacFarlane 3bf0802078 trypandoc: further refinements. 2022-08-25 19:57:06 -07:00