Modified xfloat in latex causes runaway argument -


i required use customized document class modifies xfloat...

\input{report.cls}  % single space figures, tables, , footnotes % redefine macro used floats (including figures , tables) % single spacing used.  (note \def\figure{\@float{figure}set % single spacing} doesn't work because figure has optional argument) \def\@xfloat#1[#2] {   \ifhmode     \@bsphack\@floatpenalty -\@mii   \else     \@floatpenalty-\@miii   \fi   \def\@captype{#1}   \ifinner     \@parmoderr\@floatpenalty\z@   \else\@next\@currbox\@freelist {     \@tempcnta\csname ftype@#1\endcsname     \multiply\@tempcnta\@xxxii\advance\@tempcnta\sixt@@n     \@tfor \@tempa :=#2\do {       \if\@tempa h\advance\@tempcnta \@ne\fi       \if\@tempa t\advance\@tempcnta \tw@\fi       \if\@tempa b\advance\@tempcnta 4\relax\fi       \if\@tempa p\advance\@tempcnta 8\relax\fi     }     \global\count\@currbox\@tempcnta   } \@fltovf\fi   \global\setbox\@currbox\vbox\bgroup   \def\baselinestretch{1}\@normalsize   \boxmaxdepth\z@  % leave captions indented, hope % \hsize\columnwidth   \@parboxrestore } 

however, when creating document float...

\documentclass{customclass} \begin{document} \begin{figure} test \end{figure} \end{document} 

i error...

runaway argument? tbp]test \end {figure} ! paragraph ended before \@xfloat complete. \par l.7

it appears line breaking causing issue. putting whole block in document class on same line fixes issue.


Comments

Popular posts from this blog

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

java - Could not locate OpenAL library -

sorting - opencl Bitonic sort with 64 bits keys -