\usepackage[latin1]{inputenc}
\usepackage{pstricks,pst-node,pst-text,pst-3d}
\usepackage{amsmath, wasysym}

%************************* Commands for the Theorem class environment******************************
\newcounter{theo}
\newcommand{\mtheo}{\vspace{0.2cm} \stepcounter{theo}\bf \small \magenta Theorem \arabic{theo}: }
\newcounter{prop}
\newcommand{\mprop}{\vspace{0.2cm} \stepcounter{prop}\bf \small \black Proposition \arabic{prop}: }
\newcounter{coro}
\newcommand{\mcoro}{\vspace{0.2cm} \stepcounter{coro}\bf \small \black Corollary \arabic{coro}: }
\newcounter{lemma}
\newcommand{\mlemma}{\vspace{0.2cm} \stepcounter{lemma}\bf \small \black Lemma \arabic{lemma}: }
\newcounter{remark}
\newcommand{\mremark}{\vspace{0.2cm} \stepcounter{remark}\bf \small \black Remark \arabic{remark}: }
\newcounter{exam}
\newcommand{\mexam}{\vspace{0.2cm} \stepcounter{exam}\bf \small \black Example \arabic{exam}: }
%*************************************************************************************************


%*********************** Commands for the usage of automatically stepping up counters*************
\newcommand{\cdn}[2]{\fromSlide*{#2}{\addtocounter{#1}{-1}}}
%decrease the counter#2 by #1 from slide #3
%if you want to step up a counter at one use, then please counter down this counter at
%the and of the slide by the following way: if you want to use the counter at slide M, \cdn{counter}{M}
\newcommand{\rcount}[3]{\onlySlide*{#2}{\addtocounter{#1}{#3}}}
%And don't forget to recover the counter by this command as the last command in you slide:
%\rcount{counter}{last page number}

%*************************Simplification for the overlays control command**************************
%*************************These command is short for editing, but not understandable**************
\newcommand{\os}[2]{\onlySlide*{#1}{#2}}  %\onlySlide*
\newcommand{\fs}[2]{\fromSlide*{#1}{#2}}  %\fromSlide*
\newcommand{\us}[2]{\untilSlide*{#1}{#2}}  %\untillSlide*

%************************Commands for some new Fonts*********************************************
\newcommand{\itsc}{\it \scriptsize}
\newcommand{\mitem}[1]{\item #1 \vspace*{0.1cm}}
\newcommand{\smitem}[1]{\item #1 \vspace*{0.05cm}}


%********************************A example for slide************************************************
\iffalse

\documentclass[pdf,fyma,slideColor,colorBG]{prosper}
\input{Jin_style_prosper.tex}

\FontText{   % Change the default fontsize  in slides
 \usefont{T1}{phv}{m}{n}\fontsize{9pt}{9pt}\selectfont\fymadarkblue}{%
 \usefont{T1}{phv}{m}{n}\fontsize{8pt}{8pt}\selectfont\fymadarkblue}

\title{A Example of the Application of Jin\_style\_prosper.tex}
\subtitle{\LaTeX\ presentations made easy}
\author{\href{http://www.se.cuhk.edu.hk/~hqjin}{{\green Jin Hanqing}}}
\institution{Dept. System Engineering \& Engineering Management \\
The Chinese University of Hong Kong

\vspace*{0.5cm}
Thanks to Mr. \href{http://www.se.cuhk.edu.hk/~zqxu}{{\green Xu Zuoquan}},
\href{http://wikka.ctex.org/HomePage}{{\green CTex.org}},
\href{http://www.se.cuhk.edu.hk/~hqjin/Material/pdflatex-guidelines-book.pdf}{{\green pdflatex-guidelines-book}},
\href{http://www.se.cuhk.edu.hk/~hqjin/Material/pstbook.zip}{{\green pstbook}}
}

\begin{document}
\maketitle


\overlays{6}{
\begin{slide}{Outline}
%\begin{itemstep}
{\mtheo} This should be Theorem 1 in
\fs{3}{\psellipse[linecolor=blue](0.5cm,0.1cm)(0.5cm,0.2cm)}
\rnode{s1}{{\red Slide 1}}

\fs{2}{
\vspace{2cm}
This is a test for the command in
\rnode{s2}{{\red Slide 2}}

\pscircle[linecolor=red,fillcolor=yellow,linewidth=0.5cm, linestyle=dotted](1cm, 1.6cm){1cm}
}

\fs{3}{\psellipse[linecolor=blue](5.15cm,0.85cm)(0.5cm,0.2cm)
       \nccurve[linecolor=green,linewidth=0.1cm, angleA=330,angleB=150]{->}{s1}{s2}}

\fs{4}{\vspace{-0.35cm}
{\mtheo} This should be Theorem 2 in \rnode{s3}{{\red Slide 4}}, and we have a test

\pscircle[linecolor=red,fillcolor=yellow,linewidth=0.05cm, linestyle=dotted](3cm, 2.5cm){1cm}
}

\fs{5}{
{\mtheo} This should be Theorem 3 in \rnode{s4}{{\red Slide 5}}. and we have a test for a circle with yellow interior
and blue contour

\pscircle[linecolor=blue, fillcolor=yellow, linewidth=0.1cm, fillstyle=solid,linestyle=dashed](5cm, 3.9cm){1cm}
\rput(6.5cm,3.9cm){\Huge \red \smiley}
       \nccurve[linecolor=green,linewidth=0.1cm, angleA=330,angleB=150]{->}{s1}{s2}
}
%\end{itemstep}

\fs{6}{
\vspace{0.2cm}
Similar ways for the numbering for equations, where the counter is ``equation''.
test end in {\red Slide 6} }

\cdn{theo}{1}
\cdn{theo}{4}
\cdn{theo}{5}
\rcount{theo}{6}{3}
\end{slide}
}

\end{document}

\fi
