table breaks pdf
Closed, ResolvedPublic

Ok, the problem is the math inside the table.

Such a table is rendered to a \begin{table} \begin{tabular} [...] environment.

<math>...<\math> is rendered by OCG to $...$, <math display="block">...<\math> is rendered by OCG to $$...$$.

Using $$ in LaTeX is not the best option (for example here it badly breaks the tables), \[ ... ]\ should be used instead, but we have to deal with with what we have got.

A temporary solution is using <math> instead of <math display="block">, a long term solution would be rendering <math display="block"> with \[.

Note: how the analysis has been done: Change the call to the latexer in pdf-building.sh to

echo $PAGENAME
{
 docker run -v $(pwd)"/test/zip/":/test/zip/ -v $(pwd)"/test/pdf/":/test/pdf/ --rm -ti wikitolearn/ocg:$(cat new_docker_version) \
  /var/lib/ocg/mw-ocg-latexer/bin/mw-ocg-latexer /test/zip/$PAGENAME.zip -T /test/pdf -l -D -o /test/pdf/$PAGENAME.tex
} &> $LOG_FILE

and then change the owner of the folders inside test/pdf to you user, so that you can browse them. Inside you should find all the latex files you need. It may be necessary to manually adjust some paths, since they are thought to work correctly inside the docker, not directly on the host OS.

mapellidario closed this task as Resolved.Jun 28 2017, 1:56 PM