Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Shifted \sidecites overlap #239

Open
AlexanderZeilmann opened this issue Jun 3, 2022 · 2 comments
Open

Shifted \sidecites overlap #239

AlexanderZeilmann opened this issue Jun 3, 2022 · 2 comments

Comments

@AlexanderZeilmann
Copy link
Contributor

Description

When shifting two subsequent \sidecites they will overlap although the nonshifted sidecites did not.

Minimal Working Example

\documentclass{kaobook}
\usepackage[english]{babel}
\usepackage{blindtext}
\usepackage{kaobiblio}
\usepackage{kaotheorems}
\usepackage{kaorefs}

\addbibresource{test.bib}

\begin{document}

\title{Bug Report}
\author{Author}
\date{\today}

\frontmatter
\maketitle
\mainmatter
\setchapterstyle{kao}

\chapter{First Chapter}
\blindtext

\sidecite{Book}
\sidecite{Article}

\blindtext

\sidecite[3cm]{Book}
\sidecite[3cm]{Article}

\blindtext

\end{document}

And the test.bib file

@article{Article,
	author = {LastName, FirstName},
	title  = {{{Article Title}}},
	date   = {2022}
}

@book{Book,
	author = {LastName, FirstName},
	title  = {{{Book Title}}},
	date   = {2022}
}

Expected behavior:
Each of the citations should be shifted down by 3cm and not overlap.

Actual behavior:
The citations overlap, see bottom right of the screenshot.
Bildschirmfoto 2022-06-03 um 10 21 52

@yordiak
Copy link

yordiak commented Sep 5, 2022

I don't think that this is an actual bug. Specifying the distance between the citation and the citeside does not set automatically the distance between sidecites. In other words, '\sidecite[3cm]{key}' forces the sidecite to be 3cm lower than the in-text citation, regardless whether other sidecites exist or not.

I think that the best you can do is to leave some space, something like '\sidecite[3cm]{key1]', '\sidecite[3.05cm]{key2}' (I haven't tested, though)

@fmarotta
Copy link
Owner

Interesting. I agree with @yordiak .. to be more explicit, my guess is that non-floating margin stuff (such as sidecites when you specify an offset) has an 'anchor' in the main text, and in this case, because there is no actual content between the two \sidecites, they both have the same anchor, so when you shift them, they both shift 3 cm with respect to the same point. I think it would be different if you added a \par or some other vertical space in between the two.

But at any rate, I think the best way to solve the problem would be to put both keys in the same sidecite, e.g. \sidecite[3cm]{Book,Article}, no?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants