TransWikia.com

Creating Lists with Unique Identifiers

TeX - LaTeX Asked by babb on July 1, 2021

I’m attempting to create lists with unique identifiers and am unable to do so. By unique identifiers I mean a list on the format of:

Q1. (…)

Q2. (…)

Q3. (…)

and so on. By using enumerate or itemize I am unable to change the list from showing as:

  1. (…)

  2. (…)

  3. (…)

or similar only with squares or dots instead of numbers. Any ideas how to do this in a efficient way? As of now I’m using hspace{12p} to give the desired effect, but it doesn’t work perfectly. My problem is that the indentation doesn’t work as it does for enumerate.

hspace{12pt} C1. Example Text for Question 1

 hspace produces this: Some random gibberish to show how the text doesn't indent in the same way that the title of the list item does.

begin{enumerate}
item C1. Example Text for Question 1

enumerate produces this: Some random gibberish to show how the text doesn't indent in the same way that the title of the list item does.

end{enumerate}
code for image included in text

One Answer

enter image description here

I think what you're asking for can be achieved with the enumitem package:

documentclass{article}
usepackage{enumitem}
begin{document}
    begin{enumerate}[label=Qarabic{*}.]
        item The first thing in the list
        item The second thing in the list.
        This item is really long and so the text wraps over multiple lines but is still properly indented.
        item The third thing in the list
    end{enumerate}
end{document}

or with the enumerate package:

documentclass{article}
usepackage{enumerate}
begin{document}
    begin{enumerate}[Q1.]
        item The first thing in the list
        item The second thing in the list.
        This item is really long and so the text wraps over multiple lines but is still properly indented.
        item The third thing in the list
    end{enumerate}
end{document}

Correct answer by Willoughby on July 1, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP