LyXHow to use List-like environment within another environment?

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
lyxrocks
Posts: 91
Joined: Sat Oct 23, 2010 5:59 pm

How to use List-like environment within another environment?

Post by lyxrocks »

For example, if I want to define multiple things in my "Definition 2", I want these things to be itemized, how can I do it? when I try to do it, the environment changes into Itemize, so it's not part of my "Definition 2" anymore.

i included a picture to be more clear, as you can see, the a1 and a2 lines are NOT part of my Definition 2 anymore.
lyxquestion.jpg
lyxquestion.jpg (45.72 KiB) Viewed 4009 times

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

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

lyxrocks
Posts: 91
Joined: Sat Oct 23, 2010 5:59 pm

Re: How to use List-like environment within another environm

Post by lyxrocks »

anyone?
User avatar
cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

How to use List-like environment within another environment?

Post by cgnieder »

I am absolutely no expert on LyX (I've used it once a few minutes ago). One way would be insert TeX code directly into the definition. I would think there should be a better way, though.
lyx1.png
lyx1.png (18.38 KiB) Viewed 3997 times
site moderator & package author
lyxrocks
Posts: 91
Joined: Sat Oct 23, 2010 5:59 pm

How to use List-like environment within another environment?

Post by lyxrocks »

thanks for the reply, i tried it and it doesn't seem to work, as shown below...i also included the lyx file in the attachment just in case.
example.jpg
example.jpg (94.17 KiB) Viewed 3991 times
Attachments
example.lyx
(6.36 KiB) Downloaded 297 times
User avatar
cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

How to use List-like environment within another environment?

Post by cgnieder »

You need to leave a space between \item and »a«. If you look at the source \LyX otherwise uses \itema which in consequence leads to an undefined control sequence error.

Regards
site moderator & package author
lyxrocks
Posts: 91
Joined: Sat Oct 23, 2010 5:59 pm

Re: How to use List-like environment within another environm

Post by lyxrocks »

wow, it worked thanks!!!

although i wonder if there is a more sophisticated way to do it without using TeX code. or a less sophisticated way, depends on how you look at it :)
Post Reply