TransWikia.com

Writing a good formation with latex

TeX - LaTeX Asked by meteor on April 5, 2021

How to write it? This problem bug me for a long time. Until now, I still don’t know…
enter image description here

One Answer

This might be a very first start with lots of room for improvement. At least now you can play with different settings for widths and colors.

Here's the code:

documentclass{article}
usepackage{enumitem}
usepackage{xcolor}

renewcommand{descriptionlabel}[1]{%
    hspace{labelsep}%
    colorbox{yellow}{textbf{#1}}%
    par
}

newlist{mydescription}{description}{1}

setlist[mydescription]{
  topsep=2ex,
  partopsep=2ex,
  itemsep=1ex,
  font=bfseriescolor{blue},
  labelwidth=3em,
  labelsep*=2em,
  leftmargin =!,
}

begin{document}

begin{mydescription}
  item[G1.] The first item
  item[G2.] The second item

  A longish explanation every true mathematician would deem completely unnecessary …
  item[G3.] The third item etc …
end{mydescription}

end{document}

Here's the output:

Colored Description Labels

Answered by phil-elkabat on April 5, 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