1

29 Oct 2016 Update: I have provided a complete answer to this question, as well as how to cross-reference specific citations in the maintext in another question How to cross-reference an ERT in LyX?.

I already have a completed hanging-indent reference list in Word version, which I want to reproduce in LyX. I want common hanging indent without [number] in front (this is an example from the APA website): enter image description here

An expert suggested me to use labeling environment, but (i) the first letter of the label is not a capital letter; (ii) the space between label letters are slightly wider than that of the subsequent content.

enter image description here

enter image description here

Then, I tried under standard LyX document class instead of Classicthesis, although both issues (i) (ii) vanish, I noticed a new issue (iii)-- if the surname is shorter (quite common) than label width, there is a GAP between the label and the subsequent contents:

enter image description here

I saw someone suggesting using the "verse" environment on another website, but I cannot find it. (1) Will it work and how it works? (2) If it works, how to load it to the Classicthesis LyX template?

Urgent help is needed as my thesis in due in less than a week (31st). Any other alternative suggestions are much appreciated too!

UPDATE1

Another expert suggested using description environment. I get the following outcome in Classicthesis LyX: enter image description here

The code:\begin{description} \item [{Lorem}] ipsum at nusquam appellantur his, ut eos erant homero concludaturque. Albucius appellantur deterruisset id eam, vivendum partiendo dissentiet ei ius. Vis melius facilisis ea, sea id convenire referrentur, takimata adolescens ex duo. Ei harum argumentum per. Eam vidit exerci appetere ad, ut vel zzril intellegam interpretaris. \marginpar{More dummy text.} \end{description}

and in Standard document class, issue (iii) is much alleviated but issue (ii), that is, the space between label letters, as well as a new issue arise (iv)--I want to remove the boldness in description

enter image description here

The code:

\begin{description}
\item [{Surname,}] Surname, Surname, Surname, A. 2005. This is a bibliography.
This is a bibliography. This is a bibliography. This is a bibliography.
This is a bibliography. This is a bibliography. 
\item [{Sur,}] Sur, Sur, Sur, A. 2005. This is a bibliography. This is
a bibliography. This is a bibliography. This is a bibliography. This
is a bibliography. This is a bibliography. 
\end{description}

I still prefer solution to fix it in Classicthesis template. So any alternative solutions are still welcome.

UPDATE2

By using Ctrl+L and inserting the relevant codes from "Answer 1" (\scshape is removed based on the subsequent comment) into template, I have the following result:

enter image description here

Issue 1: the description label's first letter is not capital; Issue 2: the distance between letters are wider in the description label. How to achieve the same style as in the first picture (APA reference style)?

UPDATE3

Based on Answer 2, I have the following output:

enter image description here

The only issue is how to indent the standard amount of 0.5 inches (1.27cm)? Another personal issue is that when I load "hanging" module, the parent document has unsaved changes due to TEX over-capacity, which has a limit of 5000. Any one can fix this issue?

NOTE: I searched HELP documents in LyX, but could not find "hanging" at all, despite that it indeed has an optional "hanging" module.

  • I my opinion, you should use biblatex+biber, with option style=apa. – Bernard Mar 25 '16 at 9:40
  • Thx a lot. I am using the classicthesis-LyX-v4.2_biblatex_bibtex8 template, which presets everything. I worry that changes would lead to error. Another issue is that I gave up figuring out how to use the database due to limited time. So I just want to mimic the final layout in LyX. I already copied all references from word, and I already made them as a list. The only problem is the aforementioned label stuff. – Wendy Mar 25 '16 at 9:53
  • Then I think you should use a customised (with the enumitem package) description description environment. Add the option [font=\mdseries] to the environment, it should do the trick. – Bernard Mar 25 '16 at 10:34
  • I don't know about enumitem, but I did find the description environment. I have updated my question which includes screenshots for the outcome by following your suggestion. How to add the option in LyX? Does it remove the boldness of description? Thx again. – Wendy Mar 25 '16 at 11:21
  • Could you post the code used for the update? – Bernard Mar 25 '16 at 11:25
1

Rather than abuse the description environment into doing your bidding, you could just use an environment designed to 'hang' your paragraphs. For example:

\documentclass{report}
\usepackage{classicthesis}
\usepackage{hanging}
\usepackage{setspace}
% If global doublespacing:
% \doublespacing
% If only in the References environment:
\usepackage{etoolbox}
\AtBeginEnvironment{hangparas}{\doublespacing}
\AfterEndEnvironment{hangparas}{\addvspace{0.67\baselineskip}}

\begin{document}

This paragraph is only doublespaced if you use the etoolbox method to
activate double-spacing within the \verb|hangparas| environment. If
you simply use the \verb|\doublespacing| command, this paragraph will
also be double-spaced.

\begin{hangparas}{1cm}{1}% `1cm` sets the hang amount; `1` says to hang lines after the first line in each paragraph
  Holosko, M. J. (2006). \emph{Primer for Critiquiing Social Research:
    A Student Guide.} Belmont, CA: Brooks/Cole.

  Shear, K., Frank, E., Houck, P. R., \& Reynolds, C. F. (2005).
  Treatment of complicated grief: A randomized controlled
  trial. \emph{The Journal of American Medical Association},
  \emph{293}(21), 2601--2608.
\end{hangparas}


This paragraph is only doublespaced if you use the etoolbox method to
activate double-spacing within the \verb|hangparas| environment. If
you simply use the \verb|\doublespacing| command, this paragraph will
also be double-spaced.

\end{document}
  • I have seen this in modules, but whenever I add it, and when saving the parent document, an message pops up saying that there are unsaved changes due to overcapacity ....5000..., sth like this. – Wendy Mar 26 '16 at 2:48
  • I have no idea what that means, sorry. I have never used LyX and I do not have it installed. If adding this to a LyX document causes problems, however, that seems like the LyX people need to hear about it: there is absolutely nothing particularly strange about any of these packages (from a LaTeX point of view) unless you are using a form of TeX (the engine) which does not have the e-TeX extensions enabled (which etoolbox requires). Or it is something to do with classicthesis, which is not (I think) the best coded package out there. – jon Mar 26 '16 at 3:01
  • I tested using the original template freshly downloaded. It works even when I load the same number of modules. But how to indent the standard amount: 0.5 inches (1.27cm) in LyX? I don't think I need double spacing. I copied and pasted the references into the Bibliography file in the template and I will upload the screenshot to my question now. – Wendy Mar 26 '16 at 4:02
  • Do you mean: change my 1cm to 0.5in or 1.27cm? Just change the relevant line to \begin{hangparas}{0.5in}{1}. But if you mean how you 'do' that in LyX, I'm not sure. I thought you could add in 'Evil Red Code' (or something like that) directly.... – jon Mar 26 '16 at 4:43
  • Thx a lot! I finally worked it out using ERT. I will show it as an answer. – Wendy Mar 26 '16 at 5:21
1

I also propose two solutions, based on clones of itemize and description:

\documentclass{report}
\usepackage{classicthesis}
\usepackage{enumitem}
\usepackage{titlecaps}
\usepackage{etoolbox} 

\newlist{biblistI}{itemize}{1}
\setlist[biblistI]{label = {}, labelsep =\fontdimen2\font, wide = 0pt, leftmargin =1.667\parindent}%

\newlist{biblistD}{description}{1}
\setlist[biblistD]{font =\mdseries\normalfont\titlecap, labelsep =\fontdimen2\font}%
\BeforeBeginEnvironment{biblistD}{\renewcommand{\descriptionlabel}[1]{#1}}

\begin{document}

\begin{biblistI}%
  \item[Lorem, Ipsum (2016)] at nusquam appellantur his, ut eos erant homero concludaturque.
  Albucius appellantur deterruisset id eam, vivendum partiendo dissentiet
  ei ius. Vis melius facilisis ea, sea id convenire referrentur, takimata
  adolescens ex duo. Ei harum argumentum per. Eam vidit exerci appetere
  ad, ut vel zzril intellegam interpretaris. \marginpar{More dummy text.} \end{biblistI}

\begin{biblistD}%
  \item[Lorem, Ipsum (2016)] at nusquam appellantur his, ut eos erant homero concludaturque.
  Albucius appellantur deterruisset id eam, vivendum partiendo dissentiet
  ei ius. Vis melius facilisis ea, sea id convenire referrentur, takimata
  adolescens ex duo. Ei harum argumentum per. Eam vidit exerci appetere
  ad, ut vel zzril intellegam interpretaris. \marginpar{More dummy text.}
\end{biblistD}

\end{document} 

enter image description here

  • Thx again, but how to remove the preset style of description label by the template, so as to achive the same layout as shown by the first picture in the question (APA reference style)? Please see UPDATE2 in my question for the screenshot of result. – Wendy Mar 26 '16 at 2:07
  • Just remove \scshape from the options – the description part is made with small caps, not capital letters (they're capital letters with the same height as lower case letters). – Bernard Mar 26 '16 at 2:17
  • Thx again. Please see the update2 in my question. There are still two issues. Issue 1: the description label's first letter is not capital; Issue 2: the distance between letters are wider in the description label. – Wendy Mar 26 '16 at 2:28
  • @Wendy: I propose two solutions in my updated answer. – Bernard Mar 26 '16 at 13:46
  • Thx a lot. Could you let me know how to incorporate your solution into the Classicthesis LyX template? That is, which codes to be pasted into the LaTeX preamble, and which codes as ERT (ctrl+L) in LyX file? My first attempt: since I already loaded the module of enumitem, I just copied all remaining codes starting from the fourth line (titlecaps) to the LaTeX preamble, an error message pops up: "command biblistI already defined". – Wendy Mar 27 '16 at 3:51
1

I present the following simplified answer (based on the second answer from the expert) as well as the solution to solve the clashes caused by "hanging" module:

  1. Do not remove the original latex codes in Bibliography.lyx. Document->Setting->Modules, Load the module of "customizable list enumitem", if you have not done so yet.

2: Paste

    \usepackage{etoolbox}
    \AfterEndEnvironment{hangparas}{\addvspace{0.67\baselineskip}}
    \usepackage[notquote]{hanging}

into the Document->Setting->LaTeX preambles of both Bibliography.lyx and classicthesis.lyx.

IMPORTANT NOTE 1: Do not load the "hanging" module from Document->Setting->Modules as it causes exceeding capacity problem once you consolidate the whole thesis.

3: In the main text of Bibliography.lyx, at the top of the page (must be above the original codes, won't work otherwise), Type "Ctrl+L" to create a Latex code window or ERT, paste \renewcommand{\bibname}{References}

4: Change the document environment into "Chapter*" (do not choose "Chapter", but choose this one with a star sign) by pulling down the options from the upperleft of the menu bar

5: Type "Enter", "Ctrl+L" to create another Latex code window, paste the following into the window:

    \begin{hangparas}{1.27cm}{1}
    Surname, Surname, Surname, A. 2005. This is a bibliography. This is
    a bibliography. This is a bibliography. This is a bibliography. This
    is a bibliography. This is a bibliography.  
    \end{hangparas}

IMPORTANT NOTE 2: For the next article, repeat step 2, that is, "Ctrl+L" to creat a Latex code window again.

Outcome: enter image description here

IMPORTANT NOTE 3: if you want to hyper-reference (that is, when you click it, it jumps to the specific location of the citation in the reference list) citations in the maintext, please see my answer for this question How to cross-reference an ERT in LyX?.

Comment: this solution suits those who have an existing reference list in Microsoft Word version. It is effortlessly editable in lyX since "What You See Is What You Get"; it still has correct page numbers; it is listed in Contents.lyx (or TOC) as "References"+a clickable page number. Note that the page number of the first page of references is at the bottom, which is consistent with classicthesis style. The header and page number will appear at the page top as usual from second page.

  • Create needs an e at the end. ;-) – Johannes_B Oct 22 '16 at 7:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.