LyX ⇒ Environment that enumerate and start with a word
Environment that enumerate and start with a word
I like how the environment "Section" has a counter on it, so that when creating a new section, it is numeralised automatically.
I would like to have the same to make a sheet of maths exercices, so an "exercice" environnement, with a counter integrated in it, but instead of being "1." or "2." at the begging of the line, it's "exercice 1" or "exercice 2". Can't seem to find how to do it, but it would be useful, so that if i add exercices in between, i don't have to re enumerate the whole thing.
Thanks
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
- Stefan Kottwitz
- Site Admin
- Posts: 10329
- Joined: Mon Mar 10, 2008 9:44 pm
Re: Environment that enumerate and start with a word
Stefan
Re: Environment that enumerate and start with a word
How do you create an environment. There is a 4 step guide on how to on this site -> https://tex.stackexchange.com/questions ... 779#129779 (first anwser), but it seems complicated, i have to copy and modify some files, is there a way to do it in LyX UI?
- Stefan Kottwitz
- Site Admin
- Posts: 10329
- Joined: Mon Mar 10, 2008 9:44 pm
Re: Environment that enumerate and start with a word
With LaTeX, I would use the


Stefan
Re: Environment that enumerate and start with a word
Then you can put this in your Preamble:
Code: Select all
\setenumerate{label=exercise \arabic*}
edit: Enumitem can do much more than you actually need in this situation. Maybe the LyX-User's Guide (Section 3.3.7) has enough to solve your problem in an even easier way. (But only if you don't want to have all numerations in this way.)