transpect/docx2tex

Items in {enumerate} environment

rishinair opened this issue ยท 3 comments

In the latest version (1.6), all \item commands in the enumerate hold it's corresponding number as the optional argument which will create problem if one wants to delete one or two items from the top or middle of the list. Instead you may keep the optional argument of {enumerate} environment alone to follow the style of numbering. For example, currently it appear as:

\begin{enumerate}[a.]
\item[a.] With a level 2 sub-point.
\item[b.] With a level 2 sub-point.
\item[c.] With a level 2 sub-point.
\item[d.] With a level 2 sub-point.
\item[e.] With a level 2 sub-point.
\item[f.] With a level 2 sub-point.
\end{enumerate}

Instead it should appear as:

\begin{enumerate}[a.]
\item With a level 2 sub-point.
\item With a level 2 sub-point.
\item With a level 2 sub-point.
\item With a level 2 sub-point.
\item With a level 2 sub-point.
\item With a level 2 sub-point.
\end{enumerate}

There are several issues with ordered lists from MS Word so I decided to hardcopy the list labels for ordered lists. For example, MS Word permits to create lists like 1.1โž2.1โž3.1. However, I kept that behaviour for unorthodox list numbers and removed the list label from simple ordered lists. If list numbers are skipped, then the counter is increased.

\begin{enumerate}[{I.}]

  \item roman one

  \item roman two

  \setcounter{enumi}{3}
  \item roman four

\end{enumerate}

I hope this will ease typesetting and do not break other things.

Thank you so much for fixing it so quickly.

What you have currently done is fine. ie, hardcopy the list labels for custom counters like 1.1โž2.1โž3.1, but avoid it for simple list.

If I download the source via Git, can I get the above issue resolved version?

Have a nice weekend!

When you downloaded the source from GitHub, a simple git pull should do the trick.