I've created a set of macros in Lyx that I use continuously. I want to automatically include them in all my
From what I've been reading in the forums, perhaps the most elegant way is to create a
.sty file with my macros in it, save it in some folder, and then add stuff to the LaTeX preamble in the document settings of Lyx.
What I wasn't able to find is how to actually do the above, given that I'm not an experienced Tex/Lyx user. So my questions are:
- How do you create and edit a
- What exactly do you need to type in the
.styfile? Say I want the macro (I'm typing it as it appears in Lyx).
I understand the above should be wrapped by some extra code (
\newcommand etc.), but I don't know the precise format.
- Where do you place your
.styfile such that it can be included in all
*.lyxdocuments globally? I'm a Windows user if it matters and I want to avoid adding it to every folder that contains a lyx document.
- What do I need to type in the preamble? or more generally, how do I implement it in my document defaults?