LyXImporting LaTeX Macros to LyX

Information and discussion about LyX, a WYSIWYM editor, available for Linux, Windows and Mac OS X systems.
Post Reply
rsegev
Posts: 2
Joined: Wed May 06, 2015 9:16 am

Importing LaTeX Macros to LyX

Post by rsegev »

Hi, A question regarding LyX: How do I import a LaTeX file into LyX so that the the LaTeX macros are imported into LyX Math Macros?

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

scottkosty
Site Moderator
Posts: 542
Joined: Sat Sep 01, 2012 6:38 am

Importing LaTeX Macros to LyX

Post by scottkosty »

rsegev wrote:Hi, A question regarding LyX: How do I import a LaTeX file into LyX so that the the LaTeX macros are imported into LyX Math Macros?
The way to import a .tex file in LyX is to go to File > Import > LaTeX (plain). If that does not import LaTeX macros as LyX Math Macros, I think the only thing you can do is file an enhancement request at http://www.lyx.org/trac .
rsegev
Posts: 2
Joined: Wed May 06, 2015 9:16 am

Re: Importing LaTeX Macros to LyX

Post by rsegev »

I think I found the answer myself. LyX imports the LaTeX macros into LyX math macros if and only if they are defined in the main text (after the \begin{document}) and not in the preamble.
scottkosty
Site Moderator
Posts: 542
Joined: Sat Sep 01, 2012 6:38 am

Importing LaTeX Macros to LyX

Post by scottkosty »

rsegev wrote:I think I found the answer myself. LyX imports the LaTeX macros into LyX math macros if and only if they are defined in the main text (after the \begin{document}) and not in the preamble.
Ah that makes sense. Glad you got it figured out!
Post Reply