X-Git-Url: https://melusine.eu.org/syracuse/G/git/?a=blobdiff_plain;f=doc%2Fmp-scratch.tex;h=a4a4da96907a5f51c4cbbc479b8ad95d3c1fd621;hb=e48ffd192baa7ca84c332a7f34441cb567f4c68f;hp=c813cba1f2d92f302204fdf6e5703aa61aa3f497;hpb=350918270324d171c9b7fc6bfb9ffc0c1302eef7;p=mp-scratch.git diff --git a/doc/mp-scratch.tex b/doc/mp-scratch.tex index c813cba..a4a4da9 100644 --- a/doc/mp-scratch.tex +++ b/doc/mp-scratch.tex @@ -51,6 +51,17 @@ Avec les nouveaux programmes 2016 du Cycle 4 (Classes de 5\ieme\ à 3\ieme\ de c \url{http://melusine.eu.org/syracuse/G/mp-scratch/} \end{center} et l'ensemble des fichiers sera à placer correctement dans une arborescence \TeX\footnote{Arborescence locale de préférence, par exemple dans {\sffamily /home/christophe/texmf/metapost/} sous Linux.}. +\\Pour l'utilisation, il sera nécessaire de veiller : +\begin{itemize} +\item à installer, si ce n'est pas fait, la fonte {\sffamily Carlito}\footnote{\url{http://www.tug.dk/FontCatalogue/carlito/} pour un exemple. Le choix reste personnalisable évidemment mais Thierry Pasquier, à juste titre, m'a préconisé d'utiliser une fonte sans serif.}; +\item à modifier, dans le fichier {\sffamily LATEXScratch.mp}, la ligne +\vspace{1em} +\begin{center} + \lstinline! write "\graphicspath{{/home/cp/texmf/metapost/Scratch/}}" to "mptextmp.mp";! +\end{center} +\vspace{1em} +pour indiquer le chemin correspondant à votre installation. +\end{itemize} \section{Utilisation} \begin{figure}[h] \centering @@ -162,27 +173,27 @@ Les \og opérateurs\footnote{Je nomme \og opérateurs\fg\ les variables ou comma \vspace*{2em}\par \item[Groupe {\sffamily Apparence}]\hfil\newline \begin{itemize} - \item[\textbullet]\lstinline!draw DireT("Hello",2);! + \item[\textbullet]\lstinline!draw DireT("\opSimple{Hello}",2);! \par\hfill\includegraphics{CommandeApparence.1} - \item[\textbullet]\lstinline!draw Dire("Hello");! + \item[\textbullet]\lstinline!draw Dire("\opSimple{Hello}");! \par\hfill\includegraphics{CommandeApparence.2} - \item[\textbullet]\lstinline!draw PenserT("Hmm...",2);! + \item[\textbullet]\lstinline!draw PenserT("\opSimple{Hmm...}",2);! \par\hfill\includegraphics{CommandeApparence.3} - \item[\textbullet]\lstinline!draw Penser("Hmm...");! + \item[\textbullet]\lstinline!draw Penser("\opSimple{Hmm...}");! \par\hfill\includegraphics{CommandeApparence.4} \item[\textbullet]\lstinline!draw Montrer;! \par\hfill\includegraphics{CommandeApparence.5} \item[\textbullet]\lstinline!draw Cacher;! \par\hfill\includegraphics{CommandeApparence.6} - \item[\textbullet]\lstinline!draw Basculer("\opAp{costume2}");! + \item[\textbullet]\lstinline!draw Basculer("\opApMenu{costume2}");! \par\hfill\includegraphics{CommandeApparence.7} \item[\textbullet]\lstinline!draw CostumeSuivant;! \par\hfill\includegraphics{CommandeApparence.8} - \item[\textbullet]\lstinline!draw BasculerAR("\opAp{arriere-plan2}");! + \item[\textbullet]\lstinline!draw BasculerAR("\opApMenu{arriere-plan2}");! \par\hfill\includegraphics{CommandeApparence.9} - \item[\textbullet]\lstinline!draw AjouterEffet("\opAp{couleur}",10);! + \item[\textbullet]\lstinline!draw AjouterEffet("\opApMenu{couleur}",10);! \par\hfill\includegraphics{CommandeApparence.10} - \item[\textbullet]\lstinline!draw MettreEffet("\opAp{couleur}",10);! + \item[\textbullet]\lstinline!draw MettreEffet("\opApMenu{couleur}",10);! \par\hfill\includegraphics{CommandeApparence.11} \item[\textbullet]\lstinline!draw AnnulerEffet;! \par\hfill\includegraphics{CommandeApparence.12} @@ -195,10 +206,17 @@ Les \og opérateurs\footnote{Je nomme \og opérateurs\fg\ les variables ou comma \item[\textbullet]\lstinline!draw DeplacerAP("\opOp{$\opMouv{abscisse x}\bm{+}\opSimple{10}$}");! \par\hfill\includegraphics{CommandeApparence.16} \end{itemize} +\vspace{1em}\par Quand \og la scène\fg\ est sélectionnée, on dispose également des commandes : + \begin{itemize} + \item[\textbullet]\lstinline!draw BasculerARA("\opApMenu{arriere-plan2}");! + \par\hfill\includegraphics{CommandeApparence.20} + \item [\textbullet]\lstinline!draw ARSuivant;! + \par\hfill\includegraphics{CommandeApparence.21} + \end{itemize} \par\vspace*{2em}\par Les \og opérateurs\fg\ -\[\includegraphics{CommandeApparence.17}\kern0.1\linewidth\includegraphics{CommandeApparence.18}\kern0.1\linewidth\includegraphics{CommandeApparence.19}\] +\[\includegraphics{CommandeApparence.17}\kern0.1\linewidth\includegraphics{CommandeApparence.18}\kern0.1\linewidth\includegraphics{CommandeApparence.19}\kern0.1\linewidth\includegraphics{CommandeApparence.22}\] s'obtiennent avec la commande \LaTeX\ \lstinline!\opAp{}!. - %\par\vspace*{2em}\par + \par\vspace*{2em}\par \item[Groupe {\sffamily Son}]\hfil\newline \begin{itemize} \item[\textbullet]\lstinline!draw Jouer("miaou");! @@ -285,6 +303,16 @@ s'obtiennent par la commande \LaTeX\ \lstinline!\opSon{}!. \end{minipage} \end{center} s'obtiennent par les commandes \LaTeX\ \lstinline!\opVar{}!, \lstinline!\opList{}! et \lstinline!\opSousList{}!. +\vspace{0.5em} +\begin{center} + \includegraphics{CommandeVariable.15} +% \begin{minipage}{0.6\linewidth} + \begin{lstlisting}[frame=tb] +label(LATEX("\opList{\opSousList{Pythagore} + contient \opSimple{(3;4;5)} ?}"),(0,0)); + \end{lstlisting} +% \end{minipage} +\end{center} \par\vspace*{2em}\par \item[Groupe {\sffamily \'Evènement}]\hfil\newline \begin{itemize} @@ -305,6 +333,12 @@ s'obtiennent par les commandes \LaTeX\ \lstinline!\opVar{}!, \lstinline!\opList{ \item[\textbullet]\lstinline!draw EnvoyerMessageA("message1");! \par\hfill\includegraphics{CommandeEvenements.8} \end{itemize} +\vspace{1em}\par +Quand \og la scène\fg\ est sélectionnée, on dispose de : +\begin{itemize} + \item[\textbullet]\lstinline!draw QScenePressee;! + \par\hfill\includegraphics{CommandeEvenements.9}\footnote{C'est le seul endroit où il y a une majuscule dans les notations {\sffamily Scratch}\ldots} +\end{itemize} \vspace*{2em}\par \item[Groupe {\sffamily Contrôle}]\hfil\newline \begin{itemize} @@ -314,6 +348,7 @@ s'obtiennent par les commandes \LaTeX\ \lstinline!\opVar{}!, \lstinline!\opList{ \par\hfill\includegraphics{CommandeControle.6} \item[\textbullet]\lstinline!draw Stop("ce script");! \par\hfill\includegraphics{CommandeControle.8} +\newpage \item[\textbullet]\lstinline!draw CommencerClone;! \par\hfill\includegraphics{CommandeControle.9} \item[\textbullet]\lstinline!draw CreerClone("Lutin1");! @@ -410,7 +445,7 @@ Les \og opérateurs\fg \end{center} s'obtiennent par les commandes \LaTeX\ \lstinline!\opCap{}! et \lstinline!\opCapCap{}!. Néanmoins, il faut parfois un codage conséquent. Par exemple, voici un capteur et son code. -\par\begin{minipage}{0.3\linewidth} +\par\vspace{1em}\par\begin{minipage}{0.3\linewidth} \includegraphics{CommandeCapteurs.7} \end{minipage} \hfill @@ -444,6 +479,7 @@ Les éléments% \end{minipage} \end{center} s'obtiennent par les commandes \LaTeX\ \lstinline!\opOp{}! et \lstinline!\opSousOp{}!. +\\Afin de rapprocher le package des conventions d'écriture des opérations, le choix du $\times$ à la place de * s'est imposé. Néanmoins, cela peut être discuté et modifié\ldots \vspace*{2em}\par \item[Groupe {\sffamily Ajouter blocs}]\hfil\newline \begin{itemize} @@ -481,7 +517,7 @@ D'un point de vue pédagogique, il m'est apparu nécessaire d'ajouter la possibi \end{figure} \end{description} Terminons cette liste de commandes par un algorithme associé à la suite de Syracuse :) -\[\includegraphics[scale=0.8]{Syracuse.1}\] +\[\includegraphics[scale=0.9]{Syracuse.1}\] \begin{filecontents*}{Syracuse.txt} beginfig(1); draw Drapeau; @@ -654,6 +690,8 @@ endfig; \newpage \section{Historique} \begin{description} +\item[17/02/2017] {\bfseries Version 0.61} - Ajout des commandes correspondantes à la sélection de \og la scène\fg. Mise à jour de la documentation. +\item[16/02/2017] {\bfseries Version 0.59} - Correction des commandes {\sffamily Dire}, {\sffamily DireT}, {\sffamily Penser}, {\sffamily PenserT}. Mise à jour de la documentation (informations sur l'installation du package). \item[15/02/2017] {\bfseries Version 0.57} - Correction de problèmes mineurs d'affichage. Correction de la documentation. \item[14/02/2017] {\bfseries Version 0.55} - Mise à jour de la documentation. \item[13/02/2017] {\bfseries Version 0.53} - Ajout des chanfreins sur les blocs. Correction de \og doublons\fg\ de commandes. Mise à jour de la documentation.