Here is another very simple patch. The change file adds a new primitive called \quitvmode. In vertical modes, it is identical to \indent, but in horizontal and math modes it is \noindent. See: http://www.metatex.org/web/quitvmode.html for more information. groeten, Taco
Taco Hoekwater wrote:
Here is another very simple patch.
The change file adds a new primitive called \quitvmode. In vertical modes, it is identical to \indent, but in horizontal and math modes it is \noindent. See:
http://www.metatex.org/web/quitvmode.html
for more information.
(fyi: i asked taco for this primitive - in context i have a work around but that's a kludge- because it prevents much unwanted side effects for instance the famous 'something boxed that starts a paragraph and ends up on a line of its own') Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
On 2004-07-15 11:29:35 +0200, Taco Hoekwater wrote:
The change file adds a new primitive called \quitvmode. In vertical modes, it is identical to \indent, but in horizontal and math modes it is \noindent.
Thanks. Taco, it would be nice if you would submit these via Sarovar. Best regards Martin -- Martin Schröder, ms@artcom-gmbh.de ArtCom GmbH, Lise-Meitner-Str 5, 28359 Bremen, Germany Voice +49 421 20419-44 / Fax +49 421 20419-10 http://www.artcom-gmbh.de
On Thu, 15 Jul 2004 12:21:57 +0200
Heiko Oberdiek
On Thu, Jul 15, 2004 at 11:29:35AM +0200, Taco Hoekwater wrote:
The change file adds a new primitive called \quitvmode. In vertical modes, it is identical to \indent, but in horizontal and math modes it is \noindent.
What's the difference to \leavevmode?
If there would be deep binding of macro meanings and when running in a context-free environment (and if you ignore efficiency considerations), there would not be any real difference between the new primitive and a macro doing precisely what \leavevmode does. But you cannot have a 'context-free' environment in current TeX, and, if I understand correctly, this is where Hans' problems stem from. I'm sure he has examples. Asides, it is also a lot more efficient: \leavevmode is a macro that expands into two tokens (\unhbox\voidb@x). Therefore, the command sequence when starting out in vertical mode is: * read \leavevmode * exec expand() - read \unvbox - unread \unvbox - exec new_graf() - reread \unvbox, now in hmode - exec unpackage() * exec scan_register_num() - read \voidb@x The new sequence is: * read \quitvmode * exec new_graf() (removing a number of subroutine calls and two input_stack entries)
Taco Hoekwater wrote:
Asides, it is also a lot more efficient: \leavevmode is a macro that expands into two tokens (\unhbox\voidb@x). Therefore, the command sequence
it's that unboxed void box that is the interfering pain in the * Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
Heiko Oberdiek wrote:
On Thu, Jul 15, 2004 at 11:29:35AM +0200, Taco Hoekwater wrote:
The change file adds a new primitive called \quitvmode. In vertical modes, it is identical to \indent, but in horizontal and math modes it is \noindent.
What's the difference to \leavevmode?
leavevmode is rather useless since it interferes with vertical spacing (which is one reason why so many tex docs look bad) Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (4)
-
Hans Hagen
-
Heiko Oberdiek
-
Martin Schröder
-
Taco Hoekwater