eddelbuettel / pinp

Pinp Is Not PNAS -- Two-Column PDF Template
147 stars 25 forks source link

reference list indent – change from first line to hanging #83

Closed ikashnitsky closed 4 years ago

ikashnitsky commented 4 years ago

Is there a way to re-format the reference list so that the indentation is hanging, ie

Author YEAR ...
    DOI
Another ...
    URL

Instead of

    Author YEAR
DOI
    Another ...
URL

? It just looks cleaner and reads easier

eddelbuettel commented 4 years ago

What are you using? I always use real bibliographies with natbib, and that (as I recall) works here too. As it does eg in every vignette I make with it:

image

That is from package anytime which I happen to be debugging something in right now.

ikashnitsky commented 4 years ago

I found somewhere a hacky way to use custom csl styles with pinp

output: 
  bookdown::pdf_book:
    toc: false
    latex_engine: xelatex
    base_format: pinp::pinp
    citation_package: none
    pandoc_args: [ "--csl", "psp.csl" ]

The reference list looks like this

ikashnitsky commented 4 years ago

I realise this must be LaTeX behaviour outside pinp. Now found a couple of bare LaTeX lines that fix it, from here

# Bibliography
\setlength{\parindent}{-0.2in}
\setlength{\leftskip}{0.2in}
\noindent

Sorry for extra bothering

eddelbuettel commented 4 years ago

It's a rite of passage. The last time I "putzed" with reference section formatting (by editing a .bst file, in the pre-csl days) was as a grad student.

Just don't fall for it. Use natbib and a standard style and move on. My advice which you're free to ignore...

ikashnitsky commented 4 years ago

Yeah, the universe of citation styles is the best proof that [despite conspiracy theories] the world government is an absolutely impossible thing. The only other example that may be as convincing is

coatless commented 4 years ago

@ikashnitsky hah!

My favorite though is:

Plugging in different adapters into a wall socket