5

I can't figure out how to embed a command like \textbf or something in a newly created environment, I have:

\newenvironment{definition}
  {\begin{quote}}
  {\end{quote}}

I want to customize my definition environment with some additional commands, but if I try something simple like:

\newenvironment{definition}
  {\textbf{\begin{quote}}
  {\end{quote}}}

pdflatex refuses to compile a PDF. Where am I wrong? Is there a limit for a newly created environment?

11

Use a declaration instead:

\newenvironment{definition}
  {\bfseries\begin{quote}}
  {\end{quote}}

Declarations are like switches, their effect ends when the environment is closed.

  • thanks, just to know, where i can find the complete reference to this basic commands for latex? – Micro Nov 6 '11 at 21:37
  • @Micro: In LaTeX: A Document Preparation System by Leslie Lamport, the creator of LaTeX. For freely available online sources, have a look at Introductions and Guides to LaTeX. There should be links on this site as well. – Stefan Kottwitz Nov 6 '11 at 21:44

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.