I am using Markdown to write a document. It's in lots of MD files which are then combined into 1, then sent to Pandoc as follows:
pandoc -s combined.markdown --from markdown+table_captions+auto_identifiers --filter mermaid-filter.cmd --pdf-engine=xelatex -o output.pdf
This works fine, but the table format in the PDF looks like this:
I would very much like to have the table look like this:
Or even better, I'd like to be able to do this:
A simplified combined markdown file is here:
---
author:
- Matthew Petty
affiliation: None
date: \today
title: Title of Document
subtitle: Subtitle of Document
header-includes:
- '\newcommand{\projectNumberCode}{CODE }'
- '\newcommand{\projectName}{Project Name }'
- '\newcommand{\coreSystemName}{Core Name }'
- '\newcommand{\bt}[1]{\fcolorbox{gray}{lightgray}{#1}}'
- '\defaultfontfeatures{Extension = .otf}'
- '\usepackage{fontawesome}'
- '\usepackage{tocloft}'
- '\usepackage{graphicx}'
- '\usepackage{hyperref}'
- '\usepackage{float}'
- '\usepackage{glossaries}'
- '\setglossarystyle{altlistgroup}'
- '\usepackage{xparse}'
- '\usepackage{lscape}'
- '\makenoidxglossaries'
documentclass: article
fontsize: 10pt
secnumdepth: 4
classoptions:
- a4paper
- portrait
mainfont: Arial.ttf
geometry:
- top=2cm
- left=1cm
- right=1cm
- bottom=2cm
linkcolor: Blue
numbersections: true
---
\pagebreak
\tableofcontents
\setcounter{table}{0}
\listoftables
\pagebreak
# Introduction
## Purpose
This document is testing how to format tables in Markdown/Latex
Table: Test Table
| Heading 1 | Heading 2 | Heading 3 |
| :---------------------------------------------------------------------------------------------------------------------- | :----------------- | :------------------------------------------------------------------------------------------------------------------------------------------ |
| This is Contents 1. This is Contents 1. This is Contents 1. This is Contents 1. This is Contents 1. This is Contents 1. | This is Contents 2 | This is Contents 3. This is Contents 3. This is Contents 3. This is Contents 3. This is Contents 3. This is Contents 3. This is Contents 3. |
| This is Contents 1 | This is Contents 2 | This is Contents 3 |
| This is Contents 1 | This is Contents 2 | This is Contents 3 |
| This is Contents 1 | This is Contents 2 | This is Contents 3 |
| This is Contents 1 | This is Contents 2 | This is Contents 3 |
| This is Contents 1 | This is Contents 2 | This is Contents 3 |
\begin{center}END OF DOCUMENT\end{center}
\hrulefill
I also got Pandoc to create a TEX file, which is here: https://pastebin.com/wFArVtuh
I don't know where this would be set - in Pandoc or Latex? Can anyone help?