ToshioCP / Gtk4-tutorial

GTK 4 tutorial for beginners
https://toshiocp.github.io/Gtk4-tutorial/
548 stars 50 forks source link

`! LaTeX Error: Something's wrong--perhaps a missing \item.` on `rake pdf` #16

Closed nmtake closed 2 years ago

nmtake commented 2 years ago

Hi, thanks for the tutorial! I ran rake pdf on HEAD (fbbaa8c) but got this error:

> rake cleanlatex pdf
[...]
(/usr/share/texmf-dist/tex/latex/microtype/mt-msb.cfg) (./abstract.tex

! LaTeX Error: Something's wrong--perhaps a missing \item.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.12   S
      ection 3 to 21 describes basics and the example is a simple editor
?

Generated latex/abstract.tex:

\hypertarget{about-this-tutorial}{%
\paragraph{About this tutorial}\label{about-this-tutorial}}

This tutorial is aimed at beginners who are learning Gobject system. One
[...]

Environments:


It seems that abstract environments can't contain \paragraphs:

> cat foo.tex
\documentclass{article}
\begin{document}
\begin{abstract}
\paragraph{About this tutorial}This tutorial aimed...
\end{abstract}
\end{document}

> lualatex foo.tex
[...]
(./foo.tex
[...]
! LaTeX Error: Something's wrong--perhaps a missing \item.

and here are related discussions and workarounds:

ToshioCP commented 2 years ago

Dear nmtake,

Thank you for posting the issue.

There was a bug. The problem was the conflict between abstract environment and paragraph command, as you mentioned. So I decided to remove abstract environment. Lib/lib_gen_main_tex.rb has been changed for that. I've pushed the change to the github repository. See the commit so that you can see the detail.

Thank you again for your contribution.

Toshio Sekiya

ToshioCP commented 2 years ago

Bug fixed. Commit ced4e0ce696fd4302d7ed61dc07e12fb7b046f09

nmtake commented 2 years ago

Confirmed rake** pdf built PDF successfully on ced4e0c. Thank you!