0

I'm having a small alignment problem with Biblatex. I have my citations in a separate file and am referencing them as normal. However, I want them horizontally shifted to the right to align with the rest of my text, namely, the numbers should be aligned with the green vertical line (apologies for the bad image):

enter image description here

Here is my code:

\documentclass[11pt]{moderncv}

\moderncvstyle{classic} \moderncvcolor{red}

%%%% adjust the page margins \usepackage[scale=0.78, top=0.5in, bottom=0.5in, footskip=0.2cm]{geometry} \usepackage{eurosym} \usepackage[T1]{fontenc} \usepackage[sc,osf]{mathpazo} \usepackage[maxnames=99, sorting=none]{biblatex} \usepackage[utf8]{inputenc}

\renewcommand*{\namefont}{\fontsize{20}{20}\mdseries\upshape} \addbibresource{publications.bib}

% personal data \name{Name}{Name} \phone[mobile]{111-111-1111}

\begin{document}

\makecvtitle{\vspace{-1.0cm}}

\section{Education} \cventry{2021 -- 2022}{Master of Science in Computer Science}{XXX}{XXX}{}{GPA: 4.0/4.0} \cventry{2018 -- 2021}{Bachelor of Science in Computer Science}{XXX}{XXX}{GPA: 3.99/4.0}{Summa Cum Laude\endgraf Accepted to Accelerated Bachelor's to Master's Program\endgraf Accepted to Disciplinary Honors Program} \cventry{2017 -- 2018}{Transfer Degree}{XXX}{XXX}{GPA: 4.0/4.0}{}

\section{Experience}

\nocite{*} \printbibliography[title={Research}]

\section{Interests}

\end{document}

I feel like this is a very silly and simple problem to fix, but I just can't figure it out. Any help would be greatly appreciated!

Mensch
  • 65,388
TheProgrammer
  • 404
  • 2
  • 11

2 Answers2

1

Total hack.

Taking one of the bibliography environment code examples in the manual (p106), and adding 73pt to the left margin produced this:

shifted bib

This implies that there must be a proper solution.

MWE

\documentclass[11pt]{moderncv}

\moderncvstyle{classic} \moderncvcolor{red}

%%%% adjust the page margins \usepackage[scale=0.78, top=0.5in, bottom=0.5in, footskip=0.2cm]{geometry} \usepackage{eurosym} \usepackage[T1]{fontenc} \usepackage[sc,osf]{mathpazo} \usepackage[maxnames=99, sorting=none]{biblatex} \usepackage[utf8]{inputenc}

\renewcommand*{\namefont}{\fontsize{20}{20}\mdseries\upshape} %\addbibresource{publications.bib} \addbibresource{biblatex-examples.bib}

\defbibenvironment{bibliography} {\list {\printfield[labelnumberwidth]{labelnumber}} {\setlength{\labelwidth}{\labelnumberwidth}% \setlength{\leftmargin}{\labelwidth + 73pt}% \setlength{\labelsep}{\biblabelsep}% \addtolength{\leftmargin}{\labelsep}% \setlength{\itemsep}{\bibitemsep}% \setlength{\parsep}{\bibparsep}}% \renewcommand*{\makelabel}[1]{\hss##1}} {\endlist} {\item}

% personal data \name{Name}{Name} \phone[mobile]{111-111-1111}

\begin{document}

\makecvtitle{\vspace{-1.0cm}}

\section{Education} \cventry{2021 -- 2022}{Master of Science in Computer Science}{XXX}{XXX}{}{GPA: 4.0/4.0} \cventry{2018 -- 2021}{Bachelor of Science in Computer Science}{XXX}{XXX}{GPA: 3.99/4.0}{Summa Cum Laude\endgraf Accepted to Accelerated Bachelor's to Master's Program\endgraf Accepted to Disciplinary Honors Program} \cventry{2017 -- 2018}{Transfer Degree}{XXX}{XXX}{GPA: 4.0/4.0}{} Lorem \autocite{worman} ipsum \autocite{sigfridsson} dolor \autocite{nussbaum} sit \autocite{aksin}

\section{Experience}

%\nocite{*} \printbibliography[title={Research}]

\section{Interests}

\end{document}

Cicada
  • 10,129
0

Different approach, enough to be logically separate.

How about:

Making the bibliography a \cventry, moving it up a bit with a suitable negative \vspace and moving its heading into the CV and redefining its own heading as {}?

cventrybib

MWE

\documentclass[11pt]{moderncv}

\moderncvstyle{classic} \moderncvcolor{red}

%%%% adjust the page margins \usepackage[scale=0.78, top=0.5in, bottom=0.5in, footskip=0.2cm]{geometry} \usepackage{eurosym} \usepackage[T1]{fontenc} \usepackage[sc,osf]{mathpazo} \usepackage[maxnames=99, sorting=none]{biblatex} \usepackage[utf8]{inputenc}

\renewcommand*{\namefont}{\fontsize{20}{20}\mdseries\upshape} %\addbibresource{publications.bib} \addbibresource{biblatex-examples.bib}

\defbibheading{bibliography}[\bibname]{}

% personal data \name{Name}{Name} \phone[mobile]{111-111-1111}

\begin{document}

\makecvtitle{\vspace{-1.0cm}}

\section{Education} \cventry{2021 -- 2022}{Master of Science in Computer Science}{XXX}{XXX}{}{GPA: 4.0/4.0} \cventry{2018 -- 2021}{Bachelor of Science in Computer Science}{XXX}{XXX}{GPA: 3.99/4.0}{Summa Cum Laude\endgraf Accepted to Accelerated Bachelor's to Master's Program\endgraf Accepted to Disciplinary Honors Program} \cventry{2017 -- 2018}{Transfer Degree}{XXX}{XXX}{GPA: 4.0/4.0}{} Lorem \autocite{worman} ipsum \autocite{sigfridsson} dolor \autocite{nussbaum} sit \autocite{aksin}

\section{Experience} With cventry %\nocite{*} \section{Research}

\cventry{}{\vspace*{-1.2\baselineskip}\printbibliography}{}{}{}{}

\section{Interests}

\end{document}

Cicada
  • 10,129