General ⇒ QED square in all environments
-
- Posts: 120
- Joined: Fri Nov 14, 2008 9:40 pm
Re: QED square in all environments
Thanks! I'm going to read it. It's just a matter of time.
NEW: TikZ book now 40% off at Amazon.com for a short time.
-
- Posts: 120
- Joined: Fri Nov 14, 2008 9:40 pm
QED square in all environments
I've looked at the package, and, even if I have tested 10 or 11 different configurations, it still does not work.
In the order of my document's code, I have, among other declarations:
Compilation shows me ``Command \theoremstyle already defined''.
Why? Thanks.
In the order of my document's code, I have, among other declarations:
Code: Select all
\documentclass[10pt,a4paper,twoside,final,openright]{book}%report
%% -- USED PACKAGES --
\usepackage[latin1]{inputenc}
%\usepackage{everyshi}
%\usepackage{onglet}
\usepackage[frenchb,english]{babel}
\usepackage{amsmath}
\usepackage[amsmath,thmmarks,amsthm,hyperref]{ntheorem}
\usepackage{amsthm}
\begin{document}
%% Declaration of theorems %%
\newtheoremstyle{theorem}%name
{10pt} % space above
{10pt} % space below
{\slshape} % bofy font
{\parindent} % ident - empty=no indent, \parindent= paragraph indent
{\bfseries} % thm head font
{. } % punctuation after thm head
{ } % space after thm head: `` ``=normal \newline=linebreak
{} % thm head specification
\theoremstyle{theorem}
\theoremsymbol{\qed}
\newtheorem{theorem}{\textcolor{red}{Thèorème}}[section]
\newtheorem{corollary}{\textcolor{orange}{Corollaire}}[section]
\newtheorem{proposition}{Proposition}[section]
\newtheorem{lemma}{\textcolor{green}{Lemme}}[section]
\newtheorem{property}{\textcolor{magenta}{Propriété}}[section]
\newtheoremstyle{exemple}
{10pt}{10pt}{\itshape \footnotesize}{}{\itshape \footnotesize}{.}{\newline}{}
\theoremstyle{exemple}
\theoremsymbol{\qed}
\newtheorem{exemple}{\textcolor{brown}{Exemple}}[section]
\newtheoremstyle{defi}%name
{10pt} % space above
{10pt} % space below
{\rmfamily} % body font
{\parindent} % ident - empty=no indent, \parindent= paragraph indent
{\bfseries} % thm head font
{. } % punctuation after thm head
{ } % space after thm head: `` ``=normal \newline=linebreak
{} % thm head specification
\theoremstyle{defi}
\theoremsymbol{\qed}
\newtheorem{definition}{\textcolor{blue}{Définition}}[section]
%% Declaration of theorems %%
%% BEGINNING OF DOCUMENT %%
\begin{document}
\begin{property}Here is a test.\end{property}
\end{document}
Why? Thanks.
QED square in all environments
please read the manual of all packages you use! The ntheorem manuel says explicitly,
You cannot use both packages at the same time. There are other severe errors in your document (e.g. double \begin{document}, missing color package, paragraph end between parameters). Here is a fixed version that at least compiles:amsthm.sty conflicts with the definition of theorem layouts in theorem.sty, some features of amsthm.sty have been incorporated into option [amsthm] which has to be used instead of \usepackage{amsthm}.
Code: Select all
\documentclass[10pt,a4paper,twoside,final,openright]{book}%report
%% -- USED PACKAGES --
\usepackage{xcolor}
\usepackage[latin1]{inputenc}
%\usepackage{everyshi}
%\usepackage{onglet}
\usepackage[frenchb,english]{babel}
\usepackage{amsmath}
%\usepackage[amsmath,thmmarks,amsthm,hyperref]{ntheorem}
\usepackage{amsthm}
%\begin{document}
%% Declaration of theorems %%
\newtheoremstyle{theorem}%name
{10pt} % space above
{10pt} % space below
{\slshape} % bofy font
{\parindent} % ident - empty=no indent, \parindent= paragraph indent
{\bfseries} % thm head font
{. } % punctuation after thm head
{ } % space after thm head: `` ``=normal \newline=linebreak
{} % thm head specification
\theoremstyle{theorem}
%\theoremsymbol{\qed}
\newtheorem{theorem}{\textcolor{red}{Thèorème}}[section]
\newtheorem{corollary}{\textcolor{orange}{Corollaire}}[section]
\newtheorem{proposition}{Proposition}[section]
\newtheorem{lemma}{\textcolor{green}{Lemme}}[section]
\newtheorem{property}{\textcolor{magenta}{Propriété}}[section]
\newtheoremstyle{exemple}
{10pt}{10pt}{\itshape \footnotesize}{}{\itshape \footnotesize}{.}{\newline}{}
\theoremstyle{exemple}
%\theoremsymbol{\qed}
\newtheorem{exemple}{\textcolor{brown}{Exemple}}[section]
\newtheoremstyle{defi}%name
{10pt} % space above
{10pt} % space below
{\rmfamily} % body font
{\parindent} % ident - empty=no indent, \parindent= paragraph indent
{\bfseries} % thm head font
{. } % punctuation after thm head
{ } % space after thm head: `` ``=normal \newline=linebreak
{} % thm head specification
\theoremstyle{defi}
%\theoremsymbol{\qed}
\newtheorem{definition}{\textcolor{blue}{Définition}}[section]
%% Declaration of theorems %%
%% BEGINNING OF DOCUMENT %%
\begin{document}
\begin{property}Here is a test.\end{property}
\end{document}
-
- Posts: 120
- Joined: Fri Nov 14, 2008 9:40 pm
Re: QED square in all environments
Thanks for correcting my mistakes. Is there anyway a solution for the QED square? Thanks.
QED square in all environments
It should be possible with ntheorem instead of amsthm, as Thorsten already pointed out, but then you have to follow the syntax of ntheorem, not the syntax of amsthm.
-
- Posts: 120
- Joined: Fri Nov 14, 2008 9:40 pm