ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* spurious space in cite
@ 2006-01-15 12:26 Hans van der Meer
  2006-01-15 12:41 ` Taco Hoekwater
  0 siblings, 1 reply; 3+ messages in thread
From: Hans van der Meer @ 2006-01-15 12:26 UTC (permalink / raw)


I was typesetting bibliography references with the command
	\cite[data][ref]
and then found that a spce preceded the author name; surrounding the  
space with X and Y, it gives
	"X Yauthor" instead of "XYauthor

I was able to trace it down to the macro invertedshortauthor in thise  
case, but I suspect the others (invertedauthor,  normalauthor,  
normalshortauthor) will exhibit the same phenomenon.
The macro is:

\def\invertedshortauthor#1#2#3#4#5%
   {\bibdoif{#2}{#2\bibalternative\c!vonsep}%
    #3\bibalternative\c!surnamesep
    \bibdoif{#5}{#5\bibalternative\c!juniorsep}%
    \bibdoif{#4}{#4\unskip}}

tracingmacros shows an empty #2-argument takes the \c!vonsep, in bibl- 
apa.tex defined as a space.

I first wondered if the \bibdoif's shouldn't be replaced by a  
\bibdoifnot.
Anyway, that makes the spurious spaces go away.
But it seems not right, so I investigated the bibdoif's and found the  
following behaviour when calling with empty and nonempty arguments.

			bibdoif:\crlf
			empty = \bibdoif{}{empty}\crlf
			notempty = \bibdoif{x}{notempty}\par
			bibdoifnot:\crlf
			empty = \bibdoifnot{}{empty}\crlf
			notempty = \bibdoifnot{x}{notempty}\par
			bibdoifelse:\crlf
			empty = \bibdoifelse{}{first}{second}\crlf
			notempty = \bibdoifelse{x}{first}{second}\par

Typesetting gives as a result:

bibdoif:
empty = empty
notempty = notempty
bibdoifnot:
empty =
notempty =
bibdoifelse:
empty = first
notempty = first

So I have my doubts about the doif's.


Finally another observation on the typesetting by \cite[data][ref].
When typesetting a reference ending on a period, for example "Publ.  
Co. Inc.", the result has a double period "Publ. Co. Inc.."
That looks somewhat silly.

yours sincerely,
dr. H. van der Meer

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-01-15 18:59 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-01-15 12:26 spurious space in cite Hans van der Meer
2006-01-15 12:41 ` Taco Hoekwater
2006-01-15 18:59   ` Hans van der Meer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).