From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/60665 Path: news.gmane.org!not-for-mail From: Stefan =?iso-8859-1?q?M=FCller?= Newsgroups: gmane.comp.tex.context Subject: Verbatim line numbering: location intext/text, empty lines, wrapped lines Date: Tue, 3 Aug 2010 14:50:22 +0200 Message-ID: <201008031450.22594.warrence.stm@gmx.de> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1280839834 5711 80.91.229.12 (3 Aug 2010 12:50:34 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 3 Aug 2010 12:50:34 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Tue Aug 03 14:50:31 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1OgGwu-0006CT-9V for gctc-ntg-context-518@m.gmane.org; Tue, 03 Aug 2010 14:50:28 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 900A3C9EEC; Tue, 3 Aug 2010 14:50:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id eYIu6PhDXCqE; Tue, 3 Aug 2010 14:50:27 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id B1117C9EE2; Tue, 3 Aug 2010 14:50:24 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 72108C9ECB for ; Tue, 3 Aug 2010 14:50:23 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id VWHI5kqVNUnB for ; Tue, 3 Aug 2010 14:50:21 +0200 (CEST) Original-Received: from mail.gmx.net (mailout-de.gmx.net [213.165.64.22]) by balder.ntg.nl (Postfix) with SMTP id 1BD10C9EDF for ; Tue, 3 Aug 2010 14:50:20 +0200 (CEST) Original-Received: (qmail invoked by alias); 03 Aug 2010 12:50:20 -0000 Original-Received: from 77-64-134-24.dynamic.primacom.net (EHLO bragi.localnet) [77.64.134.24] by mail.gmx.net (mp070) with SMTP; 03 Aug 2010 14:50:20 +0200 X-Authenticated: #11064435 X-Provags-ID: V01U2FsdGVkX1/KHRpt26rKYRaKlo4804MLDhpBhU0N1wMALFFFK+ 6RXNgsrDIZ/dKu User-Agent: KMail/1.13.5 (Linux/2.6.32.16-141.fc12.i686; KDE/4.4.5; i686; ; ) In-Reply-To: X-Y-GMX-Trusted: 0 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:60665 Archived-At: Hi, I found some issues with verbatim line numbering in MkIV. The appended examples is basically taken from the wiki. http://wiki.contextgarden.net/Verbatim_text#Line_numbering (The wiki uses MkII?) When I want the line numbers to be displayed "intext", I have to use \setuplinenumbering[location=text], although http://wiki.contextgarden.net/Verbatim_text#Line_numbering and http://wiki.contextgarden.net/Reference/en/setuplinenumbering tell me to use "location=intext". Should this be changed in the wiki? In case of "location=text" the lines are typeset over the right margin of the box. I think this is because the space used by the numbers is not subtracted from the available space considered by the word-wrapping algorithm. In the example, line 2 is wrapped over three lines and gets 3 line numbers, while IMHO it only should get one (the wiki says the same). Line 4 gets a number, which is what I would expect, but it is a different behavior as in the wiki (there, the empty line in the example gets no number). Is there an option to choose whether a blank line should be (a) numbered, (b) skipped or (c) get no number but the internal counter is still increased? Example: \starttext \defineframedtext[framedcode][strut=yes, offset=2mm, width=7cm, align=right] \definetyping[code][numbering=line, before={\startframedcode}, after={\stopframedcode}] \setuplinenumbering[location=text] \startcode This is the first line % line 1 This is a rather long line that is wrapped, so look how the line numbering is done % line 2 Another line % line 3 % line 4 Last line after an empty line % line 5 \stopcode \stoptext Thank you in advance for any hints, Stefan. ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________