I have used LyX to write my dissertation, and for the most part, it has worked quite well. I am baffled by the current compilation error, however. After adding a couple floats, I now get the following errors:
! Package float Error: Unknown float style `' . See the float package documentation for explanation. Type H <return> for immediate help. ... l.49 \floatstyle{} Your command was ignored. Type I <command> <return> to replace it with another command, or <return> to continue without it. \@float@every@=\toks27 \c@=\count116 ! Improper alphabetic constant. <to be read again> \spacefactor l.56 \usepackage {url} A one-character control sequence belongs after a ` mark. So I'm essentially inserting \0 here. ! Improper \spacefactor. <recently read> \spacefactor l.56 \usepackage {url} You can refer to \spacefactor only in horizontal mode; you can refer to \prevdepth only in vertical mode; and neither of these is meaningful inside \write. So I'm forgetting what you said and using zero instead. ! Missing $ inserted. <inserted text> $ l.56 \usepackage {url} I've inserted a begin-math/end-math symbol since I think you left one out. Proceed, with fingers crossed. ! LaTeX Error: Missing \begin{document}. See the LaTeX manual or LaTeX Companion for explanation. Type H <return> for immediate help. ... l.56 \usepackage {url} You're in trouble here. Try typing <return> to proceed. If that doesn't work, type X <return> to quit. ! Illegal unit of measure (pt inserted). <to be read again> = l.56 \usepackage {url} I first tried to remove the new floats, but that made no difference. I then tried compiling an older commit, and that worked just fine. When I compare `tex` exports of both versions, however, I see that an empty float construct has been appended to the user-defined float definitions: \floatstyle{} \newfloat{}{}{} \providecommand{\name}{} \floatname{}{\protect\name} Why would this occur if I have not attempted to define a new float? How should I stop it from occurring? **EDIT:** If I delete the new float definition, I can get a `tex` export to compile, but the layout is messed up in some places and all of my references are broken. **UPDATE:** Pursuant to the comments, here is the front matter from the `tex` documents. First, the old document (which compiles just fine): % LyX 2.1.4dev created this file. For more info, see http://www.lyx.org/. %% Do not edit unless you really know what you are doing. \documentclass[oneside,english,titlepage]{authesis} \usepackage[T1]{fontenc} \usepackage[latin9]{inputenc} \setcounter{secnumdepth}{3} \setcounter{tocdepth}{3} \usepackage{color} \usepackage{babel} \usepackage{array} \usepackage{float} \usepackage{graphicx} \usepackage[numbers]{natbib} \usepackage[unicode=true] {hyperref} \makeatletter %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands. \newcommand{\noun}[1]{\textsc{#1}} %% Special footnote code from the package 'stblftnt.sty' %% Author: Robin Fairbairns -- Last revised Dec 13 1996 \let\SF@@footnote\footnote \def\footnote{\ifx\protect\@typeset@protect \expandafter\SF@@footnote \else \expandafter\SF@gobble@opt \fi } \expandafter\def\csname SF@gobble@opt \endcsname{\@ifnextchar[%] \SF@gobble@twobracket \@gobble } \edef\SF@gobble@opt{\noexpand\protect \expandafter\noexpand\csname SF@gobble@opt \endcsname} \def\SF@gobble@twobracket[#1]#2{} %% Because html converters don't know tabularnewline \providecommand{\tabularnewline}{\\} \floatstyle{ruled} \newfloat{algorithm}{tbp}{loa}[chapter] \providecommand{\algorithmname}{Algorithm} \floatname{algorithm}{\protect\algorithmname} \floatstyle{ruled} \newfloat{model}{tbp}{lol} \providecommand{\modelname}{Model} \floatname{model}{\protect\modelname} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands. \usepackage{amsmath} \usepackage{url} \makeatother \begin{document} \title{DOES ONE SIZE FIT ALL?\\ \emph{AN ANALYSIS OF}\\ \emph{TAX AND EXPENDITURE LIMITATIONS}\\ \emph{IN COLORADO}} And now, the new, problematic document: %% LyX 2.1.4dev created this file. For more info, see http://www.lyx.org/. %% Do not edit unless you really know what you are doing. \documentclass[oneside,english,titlepage]{authesis} \usepackage[T1]{fontenc} \usepackage[latin9]{inputenc} \setcounter{secnumdepth}{3} \setcounter{tocdepth}{3} \usepackage{color} \usepackage{babel} \usepackage{array} \usepackage{float} \usepackage{graphicx} \usepackage[numbers]{natbib} \usepackage[unicode=true] {hyperref} \makeatletter %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands. \newcommand{\noun}[1]{\textsc{#1}} %% Special footnote code from the package 'stblftnt.sty' %% Author: Robin Fairbairns -- Last revised Dec 13 1996 \let\SF@@footnote\footnote \def\footnote{\ifx\protect\@typeset@protect \expandafter\SF@@footnote \else \expandafter\SF@gobble@opt \fi } \expandafter\def\csname SF@gobble@opt \endcsname{\@ifnextchar[%] \SF@gobble@twobracket \@gobble } \edef\SF@gobble@opt{\noexpand\protect \expandafter\noexpand\csname SF@gobble@opt \endcsname} \def\SF@gobble@twobracket[#1]#2{} %% Because html converters don't know tabularnewline \providecommand{\tabularnewline}{\\} \floatstyle{ruled} \newfloat{algorithm}{tbp}{loa}[chapter] \providecommand{\algorithmname}{Algorithm} \floatname{algorithm}{\protect\algorithmname} \floatstyle{ruled} \newfloat{model}{tbp}{lol} \providecommand{\modelname}{Model} \floatname{model}{\protect\modelname} \floatstyle{} \newfloat{}{}{} \providecommand{\name}{} \floatname{}{\protect\name} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands. \usepackage{amsmath} \usepackage{url} \makeatother \begin{document} \title{DOES ONE SIZE FIT ALL?\\ \emph{AN ANALYSIS OF}\\ \emph{TAX AND EXPENDITURE LIMITATIONS}\\ \emph{IN COLORADO}} -- Marvin Ward Jr. Associate Analyst Tax Analysis Division *Congressional Budget Office <http://www.cbo.gov>* Email: marvin.w...@cbo.gov <marvin.w...@dc.gov> Phone: (202) 226-2688