![](https://secure.gravatar.com/avatar/f56368ffbbc5661525cc21a98b618646.jpg?s=120&d=mm&r=g)
On 14 Sep 2012, at 13:26, Wolfgang Schuster
Am 14.09.2012 um 00:08 schrieb Alessandro Perucchi
: Hello,
In my experimentation, I've found that in mkii and mkiv the behavior of \textrule and \setuptextrule are different...
What I did was quite simple:
\textrule{Testing head} blah blah blah \textrule
in mkii the text in well centered between the lines. But in mkiv the bottom line is too near the text, and I need to add something like \blank[halfline] to have a similar behavior as mkii.
There is a vertical skip missing in the MkIV version of the macros.
pack-mrl.mkiv
\def\pack_textrule_following#1% {\doifelsenothing{#1} - {\nointerlineskip + {\vskip\dimexpr\strutdp+.5ex\ifdim\prevdepth>\strutdp\else\ifdim\prevdepth>\zeropoint-\prevdepth\fi\fi\relax + \nointerlineskip \dontleavehmode\vbox {\color[\directtextrulesparameter\c!rulecolor] {\hrule\s!depth\directtextrulesparameter\c!rulethickness\s!height\zeropoint\s!width\availablehsize}}} {\pack_textrule_with_text{#1}}% \ifvmode \prevdepth\zeropoint \fi}
I've tried to patch pack-mrl.mkiv and I still get the error of spacing before the second \textrule. My version of context is mtx-context | ConTeXt Process Management 0.60 mtx-context | mtx-context | main context file: /Users/ptitvert/context/tex/texmf-context/tex/context/base/context.mkiv mtx-context | current version: 2012.09.11 20:36
And apparently the command \starttextrule ... \stoptextrule doesn't work (this was explain in the cont-entp.pdf page 204) in either mkii & mliv.
This does work for me:
\starttext
blah blah blah
\starttextrule{Testing head} blah blah blah \stoptextrule
blah blah blah
\stoptext
But \starttext blah blah blah \starttextrule[top]{Testing head} blah blah blah \stoptextrule blah blah blah \stoptext doesn't, and this possibility is explain in the doc, but apparently it doesn't work. So either the doc is wrong, the command is wrong or I'm doing something wrong :-D Sincerely yours, Alessandro