From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/71267 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: Verbatim in framed text Date: Thu, 22 Sep 2011 18:10:43 +0200 Message-ID: <17A295B4-0FCA-4905-9113-18F2B6A6F4B8@googlemail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1244.3) Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1316707868 17271 80.91.229.12 (22 Sep 2011 16:11:08 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 22 Sep 2011 16:11:08 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Thu Sep 22 18:11:03 2011 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 1R6lrb-0000gb-QF for gctc-ntg-context-518@m.gmane.org; Thu, 22 Sep 2011 18:11:03 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 4EB31CAFB9; Thu, 22 Sep 2011 18:11:03 +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 7uqFYgtwzSAR; Thu, 22 Sep 2011 18:10:57 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 4185DCAFB0; Thu, 22 Sep 2011 18:10:57 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id EF07CCAFB0 for ; Thu, 22 Sep 2011 18:10:55 +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 FgsPO9nwf4Aq for ; Thu, 22 Sep 2011 18:10:54 +0200 (CEST) Original-Received: from filter4-ams.mf.surf.net (filter4-ams.mf.surf.net [192.87.102.72]) by balder.ntg.nl (Postfix) with ESMTP id E3841CAF37 for ; Thu, 22 Sep 2011 18:10:53 +0200 (CEST) Original-Received: from mail-ew0-f41.google.com (mail-ew0-f41.google.com [209.85.215.41]) by filter4-ams.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p8MGArbQ007279 for ; Thu, 22 Sep 2011 18:10:53 +0200 Original-Received: by ewy23 with SMTP id 23so1392304ewy.14 for ; Thu, 22 Sep 2011 09:10:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to:x-mailer; bh=KU1kCcox/VUHnGjIjL+8ChPtPBoAoi7f/sZU92BnPx4=; b=gi6qd+GhG/CT682J0k3/BXd8LuA7DVtr06Kbthxe6Y31TiaLgs1cRspIWYWThMKR5B qmP9wSWK5QYkW9oMyZhxQgoHRlZ8YHTNik2KSHhdzXCsw6mBxUgIMEF0AvRPX67sFDWA HgP615sXr5dDinyFK5s4AOu6SIG9pj1F5n9AY= Original-Received: by 10.14.19.20 with SMTP id m20mr878267eem.168.1316707852944; Thu, 22 Sep 2011 09:10:52 -0700 (PDT) Original-Received: from [192.168.11.105] (cust-236-50-111-94.dyn.as47377.net. [94.111.50.236]) by mx.google.com with ESMTPS id f56sm25951182eea.0.2011.09.22.09.10.48 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 22 Sep 2011 09:10:51 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1244.3) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=209.85.215.41; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 03FzQaRQB - c3f4df1fc149 - 20110922 X-Scanned-By: CanIt (www . roaringpenguin . com) on 192.87.102.72 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:71267 Archived-At: Am 22.09.2011 um 12:54 schrieb Felix Ingram: >> ---------- Forwarded message ---------- >> From: Wolfgang Schuster >> To: mailing list for ConTeXt users >> Date: Wed, 21 Sep 2011 13:09:42 +0200 >> Subject: Re: [NTG-context] Verbatim in framed text >> = >> Am 20.09.2011 um 17:50 schrieb Felix Ingram: >> = >>> Some of my verbatim lines are overflowing the framed text box I'm >>> putting them in. I see that I could define a pretty printer to handle >>> this but I came up with the following: >>> = >>> = >>> \starttext >>> \startframedtext[middle][width=3D.8\textwidth] >>> \startframedtext[left][frame=3Doff, width=3D.6\textwidth] >>> \starttyping >>> import x >>> from x import y >>> for z in b: >>> print dfdg >>> Some text >>> Some text >>> Some text >>> Some text >>> Some really long text Some really long text Some really long text Some >>> really long text Some really longtextSomereallylong text Some really >>> long text Some really long text Some really long text Some really long >>> text Some really long text >>> \stoptyping >>> \stopframedtext >>> \stopframedtext >>> \stoptext >>> = >>> = >>> This works but seems like cheating. >>> = >>> Is there a better third way I could try, or could someone point to a >>> mkiv pretty printer example I could study? >> = >> Change the alignment of the verbatim text with =93\setuptyping[align=3Df= lushleft]=94. > = > This has helped unless I have some particularly long words towards the > right of the frame. I will use a combination of flushleft plus some > pre-processing. You can use =93align=3D{flushleft,broad}=94 which get sometimes better resu= lt with ragged text. Wolfgang ___________________________________________________________________________= ________ If your question is of interest to others as well, please add an entry to t= he Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-cont= ext webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________= ________