2017-02-17 15:06:56 +00:00
|
|
|
%%%
|
2016-05-10 21:16:20 +00:00
|
|
|
%%%
|
2017-03-19 15:27:16 +00:00
|
|
|
%%% Extensions : shortcuts.sty
|
2016-05-10 21:16:20 +00:00
|
|
|
%%% Version : 1.0
|
|
|
|
%%% Date : 10/05/16
|
|
|
|
%%% Auteur : Jeff LANCE
|
2016-05-28 21:33:38 +00:00
|
|
|
%%% Notes : Cette extension peut demander l'ajout de certains packages.
|
|
|
|
%%% Il est conseillé de l'appeler dans un(e) classe/(package) appelant
|
2016-08-11 16:07:45 +00:00
|
|
|
%%% elle(lui)-même ces packages.
|
2016-05-10 21:16:20 +00:00
|
|
|
%%%
|
|
|
|
%%%
|
|
|
|
|
|
|
|
\NeedsTeXFormat{LaTeX2e}
|
2017-03-19 15:22:05 +00:00
|
|
|
\ProvidesPackage{shortcuts}[2016/05/16 Définitions de raccourcis vers des macros
|
|
|
|
existantes, v1.0]
|
2016-05-10 21:16:20 +00:00
|
|
|
|
2017-02-17 14:09:27 +00:00
|
|
|
\makeatletter
|
2016-05-10 21:16:20 +00:00
|
|
|
|
2018-10-04 20:32:37 +00:00
|
|
|
%
|
|
|
|
%
|
|
|
|
% ENVIRONMENTS
|
|
|
|
%
|
|
|
|
%
|
2016-05-10 21:16:20 +00:00
|
|
|
% itemize
|
|
|
|
\newcommand{\bi}{\begin{itemize}}
|
|
|
|
\newcommand{\ei}{\end{itemize}}
|
|
|
|
|
|
|
|
% enumerate
|
|
|
|
\newcommand{\be}{\begin{enumerate}}
|
|
|
|
\newcommand{\ee}{\end{enumerate}}
|
|
|
|
|
2016-09-14 22:12:20 +00:00
|
|
|
% descriptions
|
|
|
|
\newcommand{\bd}{\begin{description}}
|
|
|
|
\newcommand{\ed}{\end{description}}
|
|
|
|
|
2016-05-10 21:16:20 +00:00
|
|
|
% questions
|
|
|
|
\newcommand{\bq}{\begin{questions}}
|
|
|
|
\newcommand{\eq}{\end{questions}}
|
2016-05-28 21:33:38 +00:00
|
|
|
%--%
|
2016-05-28 21:20:44 +00:00
|
|
|
|
|
|
|
|
2016-05-28 21:33:38 +00:00
|
|
|
|
2018-10-04 20:32:37 +00:00
|
|
|
%
|
|
|
|
%
|
|
|
|
% TEXT
|
|
|
|
%
|
|
|
|
%
|
2017-03-18 21:41:47 +00:00
|
|
|
% Another shortcut for white text.
|
|
|
|
\NewDocumentCommand \ghost { } {%
|
|
|
|
\white
|
|
|
|
}
|
|
|
|
|
2016-08-11 16:20:46 +00:00
|
|
|
% c'est-à-dire
|
|
|
|
\NewDocumentCommand \cad { } {
|
|
|
|
{c'est-à-dire}
|
|
|
|
}
|
2016-08-19 14:56:15 +00:00
|
|
|
\NewDocumentCommand \Cad { } {
|
|
|
|
{C'est-à-dire}
|
|
|
|
}
|
2016-08-11 16:20:46 +00:00
|
|
|
|
2018-10-04 20:32:37 +00:00
|
|
|
|
|
|
|
|
|
|
|
%
|
|
|
|
%
|
|
|
|
% MATHS
|
|
|
|
%
|
|
|
|
%
|
2016-05-28 21:20:44 +00:00
|
|
|
% vecteurs i et j
|
2017-03-19 15:27:16 +00:00
|
|
|
% utilise la syntax du package xparse non appelé dans le préambule de ce
|
2016-05-28 21:33:38 +00:00
|
|
|
% fichier.
|
2016-05-28 21:20:44 +00:00
|
|
|
\NewDocumentCommand \veci { } {
|
2017-05-12 19:22:03 +00:00
|
|
|
\ensuremath{ \vec{\imath} }
|
2016-05-28 21:20:44 +00:00
|
|
|
}
|
|
|
|
\NewDocumentCommand \vecj { } {
|
2017-05-12 19:22:03 +00:00
|
|
|
\ensuremath{ \vec{\jmath} }
|
2016-05-28 21:20:44 +00:00
|
|
|
}
|
2016-08-11 16:07:45 +00:00
|
|
|
|
2018-10-04 20:32:37 +00:00
|
|
|
% repère (base vectorielle) (O;i;j)
|
|
|
|
\NewDocumentCommand \oij { } {
|
|
|
|
\ensuremath{ \left(O\; ;\; \vec{\imath}\; ;\; \vec{\jmath}\right) }
|
|
|
|
}
|
|
|
|
|
|
|
|
% repère (O;I;I)
|
|
|
|
\NewDocumentCommand \OIJ { } {
|
|
|
|
\ensuremath{ \left(O\; ;\; I\; ;\; J\right) }
|
|
|
|
}
|
|
|
|
|
2018-09-25 04:42:35 +00:00
|
|
|
% redéfinition du signe vectoriel
|
2018-10-04 20:32:37 +00:00
|
|
|
\renewcommand{\Vec}[1]{
|
|
|
|
\overrightarrow{#1\vphantom(}
|
|
|
|
}
|
|
|
|
|
|
|
|
% écriture dans un système positionnel
|
|
|
|
\newcommand{\base}[2]{
|
|
|
|
\ensuremath{ \overline{#1\vphantom(}^{#2} }
|
|
|
|
}
|
2018-09-25 04:42:35 +00:00
|
|
|
|
2016-08-11 16:07:45 +00:00
|
|
|
% ensembles
|
2016-08-16 11:17:38 +00:00
|
|
|
\NewDocumentCommand \R { s g } {
|
2016-08-14 22:26:16 +00:00
|
|
|
\IfBooleanTF {#1} {
|
|
|
|
\IfNoValueTF {#2} {
|
2018-10-04 20:32:37 +00:00
|
|
|
\!\!\!\!\ensuremath{\mathbb{R} \setminus \{0\}}\!\!\!
|
2016-08-14 22:26:16 +00:00
|
|
|
}{
|
2018-10-04 20:32:37 +00:00
|
|
|
\!\!\!\!\ensuremath{\mathbb{R} \setminus \{0, #2\}}\!\!\!
|
2016-08-14 22:26:16 +00:00
|
|
|
}
|
|
|
|
}{
|
|
|
|
\IfNoValueTF {#2} {
|
2018-10-04 20:32:37 +00:00
|
|
|
\!\!\!\!\ensuremath{\mathbb{R}}\!\!\!
|
2016-08-14 22:26:16 +00:00
|
|
|
}{
|
2018-10-04 20:32:37 +00:00
|
|
|
\!\!\!\!\ensuremath{\mathbb{R} \setminus \{#2\}}\!\!\!
|
2016-08-14 22:26:16 +00:00
|
|
|
}
|
|
|
|
}
|
2016-08-11 22:23:22 +00:00
|
|
|
}
|
|
|
|
\NewDocumentCommand \RQ { } {
|
2016-08-16 11:14:07 +00:00
|
|
|
\( \mathbb{R} \setminus \mathbb{Q} \)
|
2016-08-11 22:23:22 +00:00
|
|
|
}
|
2016-08-16 11:14:07 +00:00
|
|
|
\NewDocumentCommand \Q { s g } {
|
|
|
|
\IfBooleanTF {#1} {
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Q} \setminus \{0\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Q} \setminus \{0, #2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}{
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Q} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Q} \setminus \{#2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}
|
2016-08-11 22:23:22 +00:00
|
|
|
}
|
2016-08-16 11:14:07 +00:00
|
|
|
\NewDocumentCommand \D { s g } {
|
|
|
|
\IfBooleanTF {#1} {
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{D} \setminus \{0\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{D} \setminus \{0, #2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}{
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{D} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{D} \setminus \{#2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}
|
2016-08-11 22:23:22 +00:00
|
|
|
}
|
2016-08-16 11:14:07 +00:00
|
|
|
\NewDocumentCommand \Z { s g } {
|
|
|
|
\IfBooleanTF {#1} {
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Z} \setminus \{0\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Z} \setminus \{0, #2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}{
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Z} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{Z} \setminus \{#2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}
|
2016-08-11 22:23:22 +00:00
|
|
|
}
|
2016-08-16 11:14:07 +00:00
|
|
|
\NewDocumentCommand \N { s g } {
|
|
|
|
\IfBooleanTF {#1} {
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{N} \setminus \{0\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{N} \setminus \{0, #2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}{
|
|
|
|
\IfNoValueTF {#2} {
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{N} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}{
|
2016-09-29 20:02:27 +00:00
|
|
|
\ensuremath{\!\!\! \mathbb{N} \setminus \{#2\} \!\!}
|
2016-08-16 11:14:07 +00:00
|
|
|
}
|
|
|
|
}
|
2016-08-11 16:07:45 +00:00
|
|
|
}
|
2016-08-18 16:30:13 +00:00
|
|
|
|
2017-03-02 20:58:47 +00:00
|
|
|
|
|
|
|
|
|
|
|
|
2017-02-17 14:09:27 +00:00
|
|
|
\makeatother
|