- From: Andrew Cooper <address@hidden>
- To: address@hidden
- Subject: Re: [TeXmacs] Second-line indentation in text of bibliography entries
- Date: Mon, 08 May 2006 10:27:08 +0100
Henri Lesourd wrote:
I performed the change as you indicated (and many other ways besides).
Anyway, still no progress.
Yes, but how did you performed it ? Because if you just changed
the .ts file of the TeXmacs stylesheet (e.g., using emacs), then
it can have no effect before you start TeXmacs anew (and even in
this latter case, it probably has no effect until you erase the
cache).
I use Tools->Update->Styles after altering the .ts file. Anyway, it's
all academic because, thanks to your suggestion, the problem is solved.
Specifically, you said:
> This is why in my previous mail, I suggested to
> redefine <bibitem*|...> _itself_.
>
> This way you shunt completely the old code and start completely
> from scratch, instead of having to reason in detail about how
> a slight change to this old code operates.
Which finally made me realise what you were saying: just forget about
the submacros <render-bibitem> and <transform-bibitem>, and make my own
bibitem*! Explicitly:
<assign|bibitem*|<macro|text|<compound|margin-first-other|0mm|5mm|>>>
This is so obvious, you have my apologies for not seeing the light
sooner. In your original reply you suggested:
<assign|bibitem*|<macro|x|<margin-first-other|0mm|5mm|{old code for
bibitem*}>>
But, as you said in your last mail, the key is to start from SCRATCH,
that is, don't bother with {old code for bibitem*}. Incidentally, this
made me think twice (as I should have done to begin with) about what the
'old code' actually DOES. And then I noticed that render-bibitem (called
from bibitem*) is defined as:
<assign|render-bibitem|<macro|text|<compact-item|<transform-bibitem|<arg|text>>>>>
I had been missing that crafty compact-item! According to the manual:
"This inline macro is used to render {the argument} in a left-aligned
way. As a consequence, text after such items may be indented by the
width of {the argument}."
I think that, by retaining render-bibitem in the chain, this
compact-item was what was ultimately causing some or all of the
confusion. I think you were suggesting something along these lines in
your last message by saying that there was another expansion of MFO
under bibitem*?
However, just dispensing with all the old code in bibitem is a little
drastic - for starters, it messes up the citation texmacs-labels
(obvious enough, as this is the only other thing that bibitem* does
apart from render the bibtex-label in text, cf. std-automatic.ts).
Because I'm happy with the first solution that works, this is what I've
finally settled on.
Step 1: Change the above definition for render-bibitem to:
<assign|render-bibitem|<macro|text|<transform-bibitem|<arg|text>>>>
Step 2: Change transform-bibitem to:
<assign|transform-bibitem|<macro|x|<margin-first-other|0mm|5mm|>>>
Then, coming full circle in our discussion, bibitem* can stay unmodified!
Perhaps this isn't the best way to go about it, and I'm sure there's
more to be said on the subject. Anyway, I'm happy. Many thanks for your
patient assistance, Henri.
--
Andrew
Archive powered by MHonArc 2.6.19.