summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2007-01-12 17:32:10 +0000
committerKarl Berry <karl@freefriends.org>2007-01-12 17:32:10 +0000
commit5f808ed3800d80a9057c944ba3f6a26493399642 (patch)
tree3a2b325175161fae638c8f39b78417096000199c /Master/texmf-dist/tex
parent5b9498e7c4afd9ee9d00349d2d877f1aee917b02 (diff)
verse update (11jan07)
git-svn-id: svn://tug.org/texlive/trunk@3385 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex')
-rw-r--r--Master/texmf-dist/tex/latex/verse/verse.sty25
1 files changed, 20 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/latex/verse/verse.sty b/Master/texmf-dist/tex/latex/verse/verse.sty
index 0f8648c9893..d6248d6a82b 100644
--- a/Master/texmf-dist/tex/latex/verse/verse.sty
+++ b/Master/texmf-dist/tex/latex/verse/verse.sty
@@ -9,7 +9,7 @@
%% -----------------------------------------------------------------
%% Author: Peter Wilson (herries dot press at earthlink dot net)
%% Herries Press
-%% Copyright 2001--2006 Peter R. Wilson
+%% Copyright 2001--2007 Peter R. Wilson
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
@@ -26,10 +26,12 @@
%% -----------------------------------------------------------------
%%
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{verse}[2005/08/22 v2.22 verse typesetting]
+\ProvidesPackage{verse}[2007/01/10 v2.4 verse typesetting]
\newcounter{vslineno}
\newcounter{poemline}
+\newcounter{fvsline}
+ \setcounter{fvsline}{0}
\newcounter{modulo@vs}
\newcounter{verse@envctr}\setcounter{verse@envctr}{0}
\newcommand*{\theHpoemline}{\arabic{verse@envctr}.\arabic{poemline}}
@@ -46,15 +48,28 @@
\newcommand*{\verselinenumfont}[1]{\def\vlnumfont{#1}}
\verselinenumfont{\rmfamily}
+\newcommand*{\setverselinenums}[2]{%
+ \setcounter{poemline}{#1}\addtocounter{poemline}{\m@ne}%
+ \refstepcounter{poemline}%
+ \ifnum\c@modulo@vs>\z@
+ \@tempcnta #2\relax
+ \divide\@tempcnta\c@modulo@vs
+ \multiply\@tempcnta\c@modulo@vs
+ \c@fvsline #2\relax
+ \advance\c@fvsline-\@tempcnta
+ \fi}
+
\newcommand{\getmodulo@vs}{\bgroup
- \@tempcnta\c@poemline
- \ifnum\c@modulo@vs<\@ne % no line numbers
+ \ifnum\c@modulo@vs<\@ne% no line numbers
\else
- \ifnum\c@modulo@vs<\tw@ % number every line
+ \ifnum\c@modulo@vs<\tw@% every line numbered
\vlnumfont\thepoemline
\else
+ \@tempcnta\c@poemline
+ \advance\@tempcnta -\c@fvsline
\divide\@tempcnta\c@modulo@vs
\multiply\@tempcnta\c@modulo@vs
+ \advance\@tempcnta\c@fvsline
\ifnum\@tempcnta=\c@poemline\vlnumfont\thepoemline\fi
\fi
\fi