0

I want to add an endash to the year field of an online resource

@Online{Galebach:2002,
  author        = {Brian Galebach},
  title         = {Collection of n-uniform tilings},
  year          = {2002--2018},
  url           = {http://probabilitysports.com/tilings.html},
  urldate       = {2018-05-06},
}

However, -- is not typeset as an endash but just two regular hyphens: enter image description here

Also the command \endash does not work.

I use biblatex with biber.

4
  • This might depend on your font set-up. Can you please provide a complete MWE/MWEB. A -- in the year field does work for me, even though I'm tempted to say it is wrong and would urge you to use the ISO format date = {2002/2018}.
    – moewe
    Jun 9, 2018 at 9:15
  • Just for the record: the endash for page ranges is shown correctly. Therefore I was assuming it was not an issue with my font set-up. I now use the ISO format date and an endash indicating the range is displayed.
    – Hotschke
    Jun 10, 2018 at 6:26
  • 1
    If you use an up-to-date version of biblatex the en-dash between page ranges is produced automatically even if you manually input 5--6 what biblatex will print is 5\bibrangedash 6. So the real question is whether or not a bare -- in your document body produces an en-dash as desired.
    – moewe
    Jun 10, 2018 at 10:06
  • Your comments are really helpful: I didn't know that biblatex converts the page range -- to \bibrangedash. And as you probably expected a bare -- does not produce an en-dash in my document. I suspect there is already a question out there which adresses this. Thanks for clarifying this.
    – Hotschke
    Jun 11, 2018 at 1:53

1 Answer 1

2

The command is \textendash, or you directly enter on the keyboard. This being said, the recommended syntax to enter a range of years , as documented in §2.3.8, Date and Time Specifications, is

date={2002/2018}
1
  • I switched to the field date with the recommended syntax for a range date={2002/2018} and it works as wished. Also thanks for mentioning the relevant section in the documentation of biblatex!
    – Hotschke
    Jun 10, 2018 at 6:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .