[texhax] texhax Digest, Vol 2008, Issue 4

David Roderick angel_ov_north at tiscali.co.uk
Sun Jan 6 22:21:01 CET 2008


> If one can use environments instead of inserting macros (I like 
> environments), then one might use something like this

> \documentclass[a4paper]{article}
> \usepackage{amsmath}
> \usepackage[amsmath,thmmarks]{ntheorem}

> \theoremstyle{empty} % no header
> \theoremsymbol{xxx} % just a dummy
> \newtheorem{innerenv}{Dummy} % header not used anyway
> \makeatletter
> \newenvironment{test}[1][]{%
>    \protected at xdef\innerenvSymbol{\quad\textup{[#1]}}%
>    \begin{innerenv}}{\end{innerenv}}
> \makeatother
> \begin{document}

> \begin{test}[5~marks]
>    \[
>    3^2+4^2 = ?
>    \]
> \end{test}

> \begin{test}[15~marks]
>    \input tufte
> \end{test}

> \end{document}


> only problem is that if a paragraph ends before \end{test}, either via a 
> blank line or via the use of \par, then the placement engine breaks down.

No I cannot reproduce this problem.  works with double 

return carriage of me.
-- 
from 
David Roderick


More information about the texhax mailing list