From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/84082 Path: news.gmane.org!not-for-mail From: Michael Scholtz Newsgroups: gmane.comp.tex.context Subject: Re: Setting `before` option of chapter breaks header text Date: Tue, 3 Sep 2013 20:22:32 +0200 Message-ID: <6CC4FF1A-CC53-4BD0-AD60-6A339AAB68B1@gmail.com> References: <89A80267-412F-4F53-9EF3-7EC771A1C6A8@gmail.com> <8371E36D-D606-4F44-9AE1-D6874200D384@gmail.com> <9BF1100A-6230-425F-9FF6-EC236A53BD7F@gmail.com> <5526BCEC-7BD7-43AD-B39E-8225D3E73983@gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\)) Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1378232556 24466 80.91.229.3 (3 Sep 2013 18:22:36 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 3 Sep 2013 18:22:36 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Tue Sep 03 20:22:40 2013 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VGvFQ-0001Te-Gr for gctc-ntg-context-518@m.gmane.org; Tue, 03 Sep 2013 20:22:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id DD00D10249; Tue, 3 Sep 2013 20:21:09 +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 0VQjw6zUDZcg; Tue, 3 Sep 2013 20:21:08 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 755631020E; Tue, 3 Sep 2013 20:21:08 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id B82EC1020E for ; Tue, 3 Sep 2013 20:21:06 +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 Pmv+LFI0xUKH for ; Tue, 3 Sep 2013 20:21:05 +0200 (CEST) Original-Received: from filter3-ams.mf.surf.net (filter3-ams.mf.surf.net [192.87.102.71]) by balder.ntg.nl (Postfix) with ESMTP id B52F2101E0 for ; Tue, 3 Sep 2013 20:21:05 +0200 (CEST) Original-Received: from mail-bk0-x231.google.com (mail-bk0-x231.google.com [IPv6:2a00:1450:4008:c01::231]) by filter3-ams.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id r83IMYTL019118 for ; Tue, 3 Sep 2013 20:22:34 +0200 Original-Received: by mail-bk0-f49.google.com with SMTP id r7so2246898bkg.8 for ; Tue, 03 Sep 2013 11:22:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date :content-transfer-encoding:message-id:references:to; bh=CIAb+f1+x5MXDoxxwJ/BIo1NXYlOGtfi6R/GiZ0cW60=; b=kQI9cYKDrA5L9184rZZVTT6uGWWwWJSTXE4EJ8gelLDhtrq/lNbYBmK3uhUnxMPaar s2Xsqg6KWwjFtzVZgZHG/YSqLpECY7qVcFJSE6bHt88OQ/79KmsK8C09WLKm5zLZh0Eh jg4jQdGulShjaJOBfq7DIRFGUkUj+tDhGN7nn78ViQ9+z7pZgCzjhIj+fQEXHWKgYwlL +6G3iGqkMKd+a4SsKIACFSt28yZ1erG4nbrhXyCmc0pcrRoWIsPnvDO+vPt1q1FXIg+o DwTVKrsjgo29F9OKIkipBiKghtn8MAKkJUnVZUiwn3bViT6YIlivKGUBcP3fVt7x06P1 a8fQ== X-Received: by 10.205.68.134 with SMTP id xy6mr64536bkb.37.1378232554068; Tue, 03 Sep 2013 11:22:34 -0700 (PDT) Original-Received: from camo146-230.hrz.tu-chemnitz.de (camo146-230.hrz.tu-chemnitz.de. [134.109.146.230]) by mx.google.com with ESMTPSA id pw1sm4052074bkb.8.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 03 Sep 2013 11:22:33 -0700 (PDT) In-Reply-To: <5526BCEC-7BD7-43AD-B39E-8225D3E73983@gmail.com> X-Mailer: Apple Mail (2.1508) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=2a00:1450:4008:c01::231; country=IE X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 03KkGmylh - 047c4e08f2f5 - 20130903 X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.14 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:84082 Archived-At: On 03.09.2013, at 17:54, Wolfgang Schuster wr= ote: > = > Am 03.09.2013 um 16:32 schrieb Michael Scholtz : > = >> On 03.09.2013, at 16:13, Wolfgang Schuster = wrote: >> = >>> = >>> Am 03.09.2013 um 16:02 schrieb Michael Scholtz : >>> = >>>> If chapter titles are styled using the `before` option, the header tex= ts on each first page of the documents (body|back|appendix)part are incorre= ct, because chapter name and number are empty. = >>>> (Tested with ConTeXt version 2013.05.28 00:36 and 2013.09.03 10:22) >>>> = >>>> Is this a bug? (If not, is there any other way to set `before` without= breaking the headers?) >>> = >>> It=92s the wrong method to add rules at the begin/end of a heading. >>> = >>> A better way to add rules is to put a frame around the text. >>> = >>> \defineframedtext >>> [ChapterFrame] >>> [frame=3Doff, >>> width=3D\textwidth, >>> topframe=3Don, >>> bottomframe=3Don, >>> offset=3D0pt, >>> toffset=3D1ex, >>> boffset=3D1ex] >>> = >>> \setuphead >>> [chapter] >>> [before=3D\startChapterFrame, >>> after=3D\stopChapterFrame] >>> = >>> Wolfgang >> = >> = >> Thanks, I got this from the wiki page: http://wiki.contextgarden.net/Tit= les#Your_Own_Titling_Levels >> ...but it seems to be wrong there. > = > It=92s a solution which works but also with side effects because allow Te= X to break > the page between the rule and the heading which isn=92t the case with fra= medtext > where the whole block is unbreakable. > = >> I used `before` (probably in the wrong way ;-) ) to add more space above= each chapter title. = >> How to do this without `before`? > = > Controlling the space before and after the heading is the default way in = which the before/after > keys are used. There has been a few suggestions to add a spacebefore key = to \setuphead which > will replace "before=3D\blank" for this but this hasn=92t happened so far. > = > In the example above you can now set the spaces before and after the head= ing in the framedtext > setup with "before=3D{\blank[2cm]}" and "after=3D\blank". > = > Wolfgang Thanks for the hints. = I tried `\blank` commands in `before`, but it seems to have to effect. A sp= ace before `\blank` (like `before=3D{\ \blank[5em]}`) makes it work, but is= not so nice. But using `toffset` and `boffset` does the job, even without `\blank`s: \defineframedtext[ChapterFrame][ frame=3Doff, width=3D\textwidth, offset=3D0pt, toffset=3D5em, boffset=3D2em, ] \setuphead[chapter][ before=3D\startChapterFrame, after=3D\stopChapterFrame, ] Regards, Michael ___________________________________________________________________________= ________ 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 ___________________________________________________________________________= ________