From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/81919 Path: news.gmane.org!not-for-mail From: =?ISO-8859-15?Q?=22H=2E_=D6zoguz=22?= Newsgroups: gmane.comp.tex.context Subject: Command only if \testpage is active Date: Thu, 18 Apr 2013 17:44:38 +0200 Message-ID: <517014E6.40200@mmnetz.de> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: ger.gmane.org 1366299949 14379 80.91.229.3 (18 Apr 2013 15:45:49 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 18 Apr 2013 15:45:49 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Thu Apr 18 17:45:52 2013 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1USr1w-0002FA-Mr for gctc-ntg-context-518@m.gmane.org; Thu, 18 Apr 2013 17:45:48 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 23889101F0; Thu, 18 Apr 2013 17:45:48 +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 xLifzp5L3-1J; Thu, 18 Apr 2013 17:45:45 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 1D276101E6; Thu, 18 Apr 2013 17:45:45 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 029A0101E6 for ; Thu, 18 Apr 2013 17:45:44 +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 SBjlE-9-lG1x for ; Thu, 18 Apr 2013 17:45:39 +0200 (CEST) Original-Received: from filter2-til.mf.surf.net (filter2-til.mf.surf.net [194.171.167.218]) by balder.ntg.nl (Postfix) with ESMTP id E6237101E4 for ; Thu, 18 Apr 2013 17:45:38 +0200 (CEST) Original-Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.8]) by filter2-til.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id r3IFjajn027688 for ; Thu, 18 Apr 2013 17:45:36 +0200 Original-Received: from [192.168.1.68] (brmn-4d0ace4d.pool.mediaWays.net [77.10.206.77]) by mrelayeu.kundenserver.de (node=mreu4) with ESMTP (Nemesis) id 0LthqL-1UdGTi1e5N-01162T; Thu, 18 Apr 2013 17:45:35 +0200 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/20130328 Thunderbird/17.0.5 X-Provags-ID: V02:K0:kwu3iLocs0oIIg7qvDJ1IzCMnCetxT2tykofuYFccRV Z1UjWbtr2TVrSKcwzz6kife+0A+E6CgZMMZvBdZkJoFaqjm5Z8 +lHvC0FrTdz+XCQjDmrHwiJm5aOyOFmDNtInB1KZmnpU9h0bAI TAo0Obiix/TKLYmKvh2e0H+2z/TUJETYew4baHcNPulazldHKj 8JD5dWzXmvQb2eMnrlwD+xvtkCY2czYKi8yCTmqk/aAqX3u2wf h87vb0kEjd8ZJVn//oAZDt2waXjYa0mZJxodEXSr887r/qh4N7 7U5tyu4kOci6F5v5J3bG7pwp56nThOnmAyZZbYNXja72VH6lDC AZ9syIOTchrlXcwksaGQ= X-Bayes-Prob: 0.847 (Score 2, tokens from: @@RPTN) X-CanIt-Geo: ip=212.227.17.8; country=DE; latitude=51.0000; longitude=9.0000; http://maps.google.com/maps?q=51.0000,9.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0TJprJAlC - 51b16f6bdd7d - 20130418 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.218 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:81919 Archived-At: Hi, for subsections I use \setuphead[subsection] [after=\vskip-1.6mm, before={\testpage[5]\vskip1.6mm}] The reason is perfect distances between text-subsection-text with activated gridding. If the subsection is not set by \testpage on the next page, then everything workes fine! But if, then I want to not use the \vskips in "after" and "before". I want (in pseudo-pseudocode) something like this: if(less then 5 lines, thas is, testpage sets the subsection on the next page) then: \setuphead[subsection] [after=, before=] I hope I could make clear, what I intend to achieve. For testing: +++++++++++++++++++++++++++++++++++++ \setuplayout[grid=yes] \showgrid \setuphead[subsection] [after=\vskip-1.6mm, before={\testpage[5]\vskip1.6mm}]] \starttext \dorecurse{13}{Linefill\\} \input tufte \subsection{Hallo} \input tufte \subsection{Hallo} \input tufte \input tufte \stoptext +++++++++++++++++++++++++++++++++++++ You see on the second page the problem: gridding is lost. Huseyin ___________________________________________________________________________________ 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 ___________________________________________________________________________________