paddymcall / SARIT-pdf-conversions

XML to PDF for SARIT texts
https://github.com/sarit/SARIT-corpus
2 stars 1 forks source link

Ledmac numbering off? #44

Closed ppasedach closed 8 years ago

ppasedach commented 8 years ago

selection_106

Shouldn't be line 20 the one starting with "cittato"?

(pramanavarttikavrtti p.3)

ppasedach commented 8 years ago

selection_107

Here I would think line 5 should be the one starting with "nanu"?

This happens all over the place.

ppasedach commented 8 years ago

Here the corresponding sections with numbering turned on on every line:

selection_109

selection_108

I suspect that this is a problem of mixing prose with verse, or normal paragraphs with stanzas:

I don't fully understand yet what's happening, but maybe we should consider dropping the use of \stanza for these short quotes? According to my understanding the verse features of ledmac are mostly of interest when wants to be able to address individual lines or paadas in metric text, such as 1a, 1b, 1c, 1d, 2a, 2b, 2c, 2d, which is not what we need here.

pramanavarttikavrtti.pdf

paddymcall commented 8 years ago

Here I would think line 5 should be the one starting with "nanu"?

Thanks for spotting this, it happens because of the quote environment around the stanzas, e.g.:

%% require snapshot package to record versions to log files
\RequirePackage[log]{snapshot}
\documentclass[article,12pt,a4paper]{memoir}%

%% useful for debugging
%% \usepackage{syntonly}%
%% \syntaxonly%

\usepackage{reledmac}
\setstanzaindents{3,2,2}
\firstlinenum{1}
\linenumincrement{1}

\begin{document}

\begingroup
\beginnumbering

\stanza[\smallbreak]
stanza standard: abc / & def // \&[\smallbreak]

\begin{quote}
  \stanza[\smallbreak]
  stanza in quote: abc / & def // \&[\smallbreak]
\end{quote}

\stanza[\smallbreak]
stanza: abc / & def // \&[\smallbreak]

\endnumbering
\endgroup

\end{document}

See Reledmac docs section 16, Quotations: not sure what the expected behaviour is around/in stanzas. If you can fix the example above, I can apply it to the stylesheets.

ppasedach commented 8 years ago

So for the moment you've just removed the quote environment around the stanza?

paddymcall commented 8 years ago

On Wed, Jun 01 2016, ppasedach wrote:

So for the moment you've just removed the quote environment around the stanza?

there are now quote marks (`` and "). alternatives would be to change font/background, or to have some other indication. if you have any ideas, please let me know.

Patrick McAllister

long-term mail: pma@rdorte.org

ppasedach commented 8 years ago

I just looked at the adjustwidth environment. It doesn't have the line numbering problem, but the indentation doesn't work properly. I'm still looking into it.

ppasedach commented 8 years ago

I discovered something curious: The file built on my notebook (development version of xetex and a few packages) seems to be doing the numbering correctly:

selection_113

(File created Mon 30 May 2016 01:01:44 PM CEST)

ppasedach commented 8 years ago

selection_114

The second example from the same version of the file, but note that the line numbers are not reset to zero on the new page. Strange.

ppasedach commented 8 years ago

O.k., let's forget about that ghost. I wasn't able to reproduce it this morning. Meanwhile I got confirmation from Maïeul (maintainer of reledmac) that it's currently not possible to use \stanza within a quote environment. He asked me to open a github issue, which I did, however he mentioned that "I won't have time before a lot of time. "

So your approach was to get rid of the quote environment for now, whereas I think I would prefer to get rid of both quote environment and \stanza here and format the passage in a similar fashion as in the following example:

\documentclass[article]{memoir}
\usepackage{reledmac}
\usepackage{lipsum}
\setstanzaindents{3,2,2}
\firstlinenum{1}
\linenumincrement{1}
\begin{document}
\beginnumbering

\pstart
\lipsum[1]
\pend

\pstart
\bigskip
{\large
\noindent\-\hspace{2.5em}verse first line\\ 
\-\hspace{2.5em}verse second line 
}
\pend
\bigskip

\pstart
\lipsum[1]
\pend

\endnumbering

\end{document}

selection_115

paddymcall commented 8 years ago

Seems like a good idea. Could we do this in a single command? I.e., put a newenvironment definition in the preamble and then just call \begin{quoted-verse} xyz \end{quoted-verse}?

ppasedach commented 8 years ago

It will not be so easy, as we have to deal with the lines individually, closing all but the last one with \\, and prefixing the first one with \noindent. Also it assumes the same indent for all lines, which might be fine, but we could also think of verses in longer meter which you might want to break into four quarters, and then indenting pādas b and d more than a and b. Let me think about it.

paddymcall commented 8 years ago

Please reopen issue when we have working environment definition for verses in quotes.