Return-Path: Delivered-To: GMX delivery to rainer.schoepf@gmx.net Received: (qmail invoked by alias); 22 Sep 2011 17:19:42 -0000 Received: from relay.uni-heidelberg.de (EHLO relay.uni-heidelberg.de) [129.206.100.212] by mx0.gmx.net (mx077) with SMTP; 22 Sep 2011 19:19:42 +0200 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.100.94]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id p8MHGuSK018188 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Thu, 22 Sep 2011 19:16:56 +0200 Received: from listserv.uni-heidelberg.de (localhost.localdomain [127.0.0.1]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id p8MEdOQI003306; Thu, 22 Sep 2011 19:16:55 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 1650583 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Thu, 22 Sep 2011 19:16:55 +0200 Received: from relay.uni-heidelberg.de (relay.uni-heidelberg.de [129.206.100.212]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id p8MHGtK1015928 for ; Thu, 22 Sep 2011 19:16:55 +0200 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.171]) by relay.uni-heidelberg.de (8.14.1/8.14.1) with ESMTP id p8MHGMem018057 for ; Thu, 22 Sep 2011 19:16:27 +0200 Received: from mittelbach-online.de (p3EE3F193.dip.t-dialin.net [62.227.241.147]) by mrelayeu.kundenserver.de (node=mreu0) with ESMTP (Nemesis) id 0LuHL9-1RFtR43sLH-011R2O; Thu, 22 Sep 2011 19:16:22 +0200 Received: by mittelbach-online.de (Postfix, from userid 783) id C506B172034C; Thu, 22 Sep 2011 19:16:15 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on Marlowe X-Spam-Status: No, score=-1.4 required=5.0 tests=ALL_TRUSTED,AWL autolearn=unavailable version=3.2.5 Received: from [127.0.0.1] (unknown [192.168.123.104]) (Authenticated sender: frank) by mittelbach-online.de (Postfix) with ESMTPSA id 9AFF2172034A for ; Thu, 22 Sep 2011 19:16:13 +0200 (CEST) User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:6.0.2) Gecko/20110902 Thunderbird/6.0.2 MIME-Version: 1.0 References: <4E79D279.2050901@morningstar2.co.uk> <4E79E2B7.6080906@residenset.net> <4E79E8C1.8060107@morningstar2.co.uk> <4E79F0F7.7060400@residenset.net> <4E7A1579.1000009@morningstar2.co.uk> <4E7A2EBF.3070009@latex-project.org> <4E7A414B.2020900@morningstar2.co.uk> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 110922-0, 22.09.2011), Outbound message X-Antivirus-Status: Clean X-Provags-ID: V02:K0:kfyXvSAvQsxsMeF9VfnzKG9n0jCYaUbdybTVjbVcVqN lfWHQ0CAlyxEHtmayebbkX4LfHJ2wbJtj4OZS+wZXojRz8RlCg RYQyTqr9kGgQ9gDI3DA20hL0NijUuwzqtCVTPwBMtotuQAEuOB F13iGp7DH6oiqo7SgF1Ae+TgsDSF9f84Zq0wvRukyP8jiPJ3eF a8XSBaF6qcwmrREruQZ7nILp7NKQybc7dW+x7amKFLhLTUAa2F rZQaiS9HxUFkDFS+iFUJTOFTe160eR79MYokiabX/sR7bpxndt cXiqiT7emhTy6xrlW3bpEY2uXeeHvpfQLUROC9/aISjcxeX8Ov ZNX50Y6jsOy7SYsux21rzzkKVJYagI46b10MOeVg6 Message-ID: <4E7B6D5B.3030707@latex-project.org> Date: Thu, 22 Sep 2011 19:16:11 +0200 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Frank Mittelbach Subject: Re: \interlinepenalties To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE In-Reply-To: <4E7A414B.2020900@morningstar2.co.uk> Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-GMX-Antivirus: 0 (no virus found) X-GMX-Antispam: 0 (eXpurgate); Detail=5D7Q89H36p70EVnmPwpfx3xNeC+yKFx5VZSuk3GNqu8XFVk6I1cfLAkecaAjkmBFiHbMY 0c4yS+sXqnOH8T6i7NyDbenLc6YioLXXQqf+K4gACzWZkTvU/HqkkY3fU9JAjjT500mxEtY3t+xt 1O3hoJWXU8v1OPgwah7Mg7hxfR5BQi5X0RDk9QKE7lvKPrdLqd1IlwpzEA=V1; X-Resent-To: rainer@rainer-schoepf.de Status: R X-Status: X-Keywords: X-UID: 6897 Am 21.09.2011 21:55, schrieb Joseph Wright: > On 21/09/2011 19:36, Frank Mittelbach wrote: >> Am 21.09.2011 18:48, schrieb Joseph Wright: >>> On 21/09/2011 17:34, Bruno Le Floch wrote: >>>> Context uses it in \keeplinestogether, but I don't see why they >>>> couldn't have used \clubpenalties instead. I don't understand the >>>> difference between \interlinepenalties and \clubpenalties as described >>>> in etex_man: >>>> >>>> - the ith interline penalty value is used after line i of the paragraph; >>>> - the ith club penalty value is used after line i of a partial >>>> paragraph; >>> >>> My reading of this was that the variation comes down to whether there is >>> any display math about, but in such a case I'm doubtful you'd want to >>> 'keep together' in any case. As you say, in most realistic circumstances >>> \clubpenalties seems to be quite usable, as you have to start from line >>> 1 with \interlinepenalties too. >> >> I beg to disagree. The two arrays serve different purposes and in fact >> \insertpenalties is the one that is more useful (and was the original >> reason for providing the this additional functionality (the others are >> more an afterthought to make thing orthogonal). >> >> Main use case: >> >> Ensure that after a section x lines are kept together with the section >> >> for this use have to use \insertpenalties as you do *not* want to >> restart counting after a displayed equation, but you just want x-lines >> once. (in that case you need a mechanism to restore the default status >> after the first paragraph, as LaTeX today does (or rather attempts as it >> not always works in TeX) with \clubpenalty for ensuring 2 lines after a >> heading) >> >> Minor use case: >> >> At the beginning of a paragraph (or after a displayed equation as that >> is visually simiar) you want at least 2 lines but preferably 3) then >> something like >> >> \clubpenalties = 2 10000 8000 >> >> That would be a setting you could use for a whole range of paragraphs or >> even for a whole document. >> >> you can think of others also in combination with \insertpenalties > > (I'm assuming you mean '\interlinepenalties' throughout.) I'm sorry, yes of course I meant the latter > > I guess this partly depends on your view on display stuff. don't think so, the display stuff is a bit ugly, granted, but it doesn't change the fact that \interlinepenalties refers within a single paragraph only to a fixed number of lines counted from the beginning while \clubpenalties get restarted after each interrupting display and that is (depending on the use case) not necessarily what you are looking for. > For me, I'm > not sure how it fits into the concept of a 'line'. If I have a paragraph > > text text text text text > text text text text text > display > display > text text text text text > text text text text text > > then how many lines does the display part count? In TeX the display counts as 3 lines (regardless of the number of real lines it would occupy in a grid system). That is just the way it is. It makes sense for single line displayed equations but if you have a set of equations then that counter clearly ends up being off > Do we go with a > grid-typesetting approach and measure its eight, divide by the text lien > height and use the result? Do we ignore it? real grid typesetting needs to do something like the above (which is what I have done in xor for example). But that is not directly related to the \interlinepenalties \clubpenalties question which is about holding certain lines together or allowing breakpoints with a certain penalty > > I guess the other problem I have is that the generalisation > \interlinepenalty => \interlinepenalties seems a bit odd. it is odd in the sense that \interlinepenalty applies to all lines and \interlinepenalties only to the first n lines. While in contrast \clubpenalty and \widowpenalty refer only to single lines > The > \clubpenalty => \clubpenalties is easy to understand, as both are > related to the start of a paragraph. not quite \clubpenalties refer to the beginning of every partial paragraph. However \clubpenalty only refers to the penalty after the first line of a paragraph. So on the whole the generalization is odd in all cases, but that doesn't mean it isn't useful. On the other hand, > \interlinepenalty is a 'floating' idea with no link to the position in a > paragraph, whereas \interlinepenalties does have to start at the beginning. > > I guess my overall concern is that I've not seen \interlinepenalties > used 'in the wild', whereas \clubpenalties and \widowpenalties do seem > to be in use. Perhaps that's because I'm not really involved in > typesetting maths (and so the effects of display environments pass me by). the fact that people use it incorrectly doesn't mean we should continue to do so. Point is when I want to have at least 3 lines after a heading I should set \interlinepenalties = 3 10000 10000 1000 \interlinepenalties = 0 now if that para contains a display I still get only 3 lines fixed to the heading. However if i would have used \clubpenalties instead above it would have gotten the following situation: \clubpenalties = 3 10000 10000 1000 <1 line> %no break <2 line> %no break <3 line> <4 line> <8 line> %no break <--- not desired <9 line> %no break <--- not desired <10 line> <11 line> <12 line> \clubpenalties = 0 you may of course want one or 2 lines after each display, but that is a different use case above you get this only after a heading frank