1

MWE:

This is for a custom.module file that should be accessed using the top-left drop down menu in LyX:

#\DeclareLyXModule{custom}
#DescriptionBegin
#Legal Format
#DescriptionEnd
#Author: Jalep

Format 63

Style Title
    Category              Custom
    Margin                Static
    LatexType             Command
    LatexName             title
    OptionalArgs          0
    Preamble
     \newcommand\MEETtitle{\large[1] { \noindent \LARGE \bf \begin{center} #1 \end{center}\rm } \vskip.1in \rm\normalsize } 
     \let\title\MEETtitle
     \renewcommand\maketitle{\vskip0pt} 
    EndPreamble
End

Goal:

I'm trying to use this module file to allow a user in LyX to access commands created in my custom.cls file without having to type the TeX code in their LyX file i.e. using the top-left drop down menu. I can't find documentation really on how to format the module file, but I have based my MWE off this post.

More context:

The code between Preamble and EndPreamble is straight from the commands used in my custom.cls file. As done in the post I reference above.

Issue:

LyX does not respond well to what I've written in this file: "Error reading custom module".

2
  • 1
    Hi, welcome. Try removing the line with Format 63. Dec 6, 2018 at 21:34
  • Wow that worked! Like magic. Thank you Torbjørn and thanks for a very happy and successful welcome.
    – jed
    Dec 6, 2018 at 21:46

1 Answer 1

1

The error was in the line with Format 63. After removing, this worked successfully.

MWE:

#\DeclareLyXModule{custom}
#DescriptionBegin
#Legal Format
#DescriptionEnd
#Author: Jalep

Style Title
    Category              Custom
    Margin                Static
    LatexType             Command
    LatexName             title
    OptionalArgs          0
    Preamble
     \newcommand\MEETtitle{\large[1] { \noindent \LARGE \bf \begin{center} #1 \end{center}\rm } \vskip.1in \rm\normalsize } 
     \let\title\MEETtitle
     \renewcommand\maketitle{\vskip0pt} 
    EndPreamble
End 

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .