![](https://secure.gravatar.com/avatar/d0e94fb08d4620cfbd2f8f59a7868637.jpg?s=120&d=mm&r=g)
I'm playing with (and happy about) linenotes; I'm just running into one small (?) problem. Here's a testfile: \starttext % \setuplinenumbering[location=intext,step=2] \startlinenumbering Long and boring text that has \linenote{note one} no other sense than demonstrating a problem with the linenote command in ConTeXt. \stoplinenumbering \stoptext Run it, then comment out the \setuplinenumbering command. Is there a way of having linenotes displayed correctly even when the numbers are not displayed because of the step= setting? Thanks Thomas
![](https://secure.gravatar.com/avatar/49e63acb01f2ca80efce7eed08310ce8.jpg?s=120&d=mm&r=g)
Thomas A. Schmitz wrote:
I'm playing with (and happy about) linenotes; I'm just running into one small (?) problem. Here's a testfile:
\starttext
% \setuplinenumbering[location=intext,step=2]
\startlinenumbering Long and boring text that has \linenote{note one} no other sense than demonstrating a problem with the linenote command in ConTeXt. \stoplinenumbering
\stoptext
Run it, then comment out the \setuplinenumbering command. Is there a way of having linenotes displayed correctly even when the numbers are not displayed because of the step= setting?
\unprotect \def\donoplacelinenumber {\the\everylinenumber} \def\doplacelinenumber {\ifnum\linenumber<\@@rnstart\relax \donoplacelinenumber \else \ifnum\numexpr(\linenumber/\@@rnstep)*\@@rnstep\relax=\linenumber \doattributes\??rn\c!style\c!color\dodoplacelinenumber \else \donoplacelinenumber \fi \fi} ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
![](https://secure.gravatar.com/avatar/d0e94fb08d4620cfbd2f8f59a7868637.jpg?s=120&d=mm&r=g)
On Nov 5, 2006, at 6:35 PM, Hans Hagen wrote:
\unprotect
\def\donoplacelinenumber {\the\everylinenumber}
\def\doplacelinenumber {\ifnum\linenumber<\@@rnstart\relax \donoplacelinenumber \else \ifnum\numexpr(\linenumber/\@@rnstep)*\@@rnstep\relax=\linenumber \doattributes\??rn\c!style\c!color\dodoplacelinenumber \else \donoplacelinenumber \fi \fi}
Wonderful, that works! Thanks a lot! Best Thomas
participants (2)
-
Hans Hagen
-
Thomas A. Schmitz