Skip to content

Conversion of table from RTF to Markdown or Commonmark does not work properly #8767

@jamesemoody

Description

@jamesemoody

Explain the problem:
I have attached TableTest.rtf, which contains some regular text, plus a table. It was produced by exporting from MacOS Pages to RTF.

I execute this command line:
pandoc --to commonmark ./TableTest.rtf -o ./TableTest.md

Expected result:

The .md file should contain some lines of regular text, and then a Markdown-formatted table.

Actual result:

The .md file contains an HTML table, where all of the text preceding the table in the RTF ends up in the first td. The content after the table looks correct, and is formatted properly in Markdown.

I get a similar result if I use --to markdown, so I'm suspecting this is a problem parsing/processing the RTF input, as opposed to a problem in the Commonmark/MD generators.

Pandoc version


$ pandoc --version
pandoc 3.1.2
Features: +server +lua
Scripting engine: Lua 5.4

Running on Ubuntu 22.04.2 LTS.
TableTest.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions