From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/26348 Path: news.gmane.org!not-for-mail From: nico Newsgroups: gmane.comp.tex.context Subject: typing and linenumbering Date: Wed, 15 Mar 2006 23:02:27 +0100 Message-ID: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1142460005 12890 80.91.229.2 (15 Mar 2006 22:00:05 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 15 Mar 2006 22:00:05 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Wed Mar 15 23:00:03 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1FJe2C-0005NP-4o for gctc-ntg-context-518@m.gmane.org; Wed, 15 Mar 2006 23:00:00 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 9BB1A12783; Wed, 15 Mar 2006 22:59:59 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03184-04; Wed, 15 Mar 2006 22:59:54 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 4C61312784; Wed, 15 Mar 2006 22:59:54 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 87FD312784 for ; Wed, 15 Mar 2006 22:59:53 +0100 (CET) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 03001-10 for ; Wed, 15 Mar 2006 22:59:52 +0100 (CET) Original-Received: from swip.net (mailfe01.tele2.fr [212.247.154.12]) by ronja.ntg.nl (Postfix) with SMTP id 9DA3D12783 for ; Wed, 15 Mar 2006 22:59:52 +0100 (CET) X-T2-Posting-ID: 3brHPWvyEzVNt0QNlxQWsxGJRDYe7rueGgqwO1zxZAg= X-Cloudmark-Score: 0.000000 [] Original-Received: from [80.170.132.71] (HELO localhost) by mailfe01.swip.net (CommuniGate Pro SMTP 5.0.8) with ESMTP id 134601689 for ntg-context@ntg.nl; Wed, 15 Mar 2006 22:59:48 +0100 Original-To: "mailing list for ConTeXt users" User-Agent: Opera M2/7.54 (FreeBSD, build 955) X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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 X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:26348 Archived-At: Hello, I would like to print some listings, with their line numbers. To achieve this I use the following combination on framedtext, typing and linenumbering stuff. The output is pretty as I wish, but unfortunately the line numbers are *not* the numbers of the listing lines, but the numbers of the lines once wrapped in the frame. In the example below the first line is very long (the "blah blah" line), but in the output it is shown as 4 lines (with 4 line numbers). Is there a way to achieve this in a more integrated way with the typing environment? The other side effect of the method used is that it changes the linenumbering behaviour outside the typing environment. I tried the "reset" option, but it doesn't change the intext location. Is there a possibility to come back to default settings? Last but not least, is it possible to customize the wrapping behaviour so that an arbitrary command can be called before the cut, and another command after the cut? What I would like to have is {\space\wrapsign} before the cut and an indentation after the cut to show that the line is wrapped. Thanks for any hints. % listing frame \defineframedtext [framelisting] [background=screen, frame=off, strut=yes, offset=2mm, width=broad, framecolor=black, align=right] \definetyping[prog] \setuptyping[prog] [bodyfont=small, before={\setuplinenumbering[style=small,step=2,start=3,location=intext] \startframelisting\startlinenumbering}, after={\stoplinenumbering\stopframelisting}] % after={\stoplinenumbering\setuplinenumbering[reset]}] \startprog first line: blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah second line third line last line \stopprog Regards, BG