LyXoptional items in a list

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
dee
Posts: 2
Joined: Wed Jun 22, 2016 8:31 pm

optional items in a list

Post by dee »

Hello,

can I have document with two versions, one of them with some extra items in a list?

I started with

Code: Select all

\begin_layout Enumerate
optional item
\end_layout

\begin_layout Enumerate
item
\end_layout
and tried to put first item in a branch, but all attempts I made have some problem. For example this one keeps optional item partially visible even when branch is off.

Code: Select all

\begin_layout Enumerate
\begin_inset Branch optional
status open
\begin_layout Standard
optional item
\end_layout
\end_inset
\end_layout

\begin_layout Enumerate
item
\end_layout
Stepan

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

dee
Posts: 2
Joined: Wed Jun 22, 2016 8:31 pm

optional items in a list

Post by dee »

If I had C preprocessor, I would do

Code: Select all

#if optional
\begin_layout Enumerate
optional item
\end_layout
#endif
Can LyX do something similar with branches? Or do I need ERT?
Post Reply