mystyle.styを晒す

LaTeXのこととかまとめておく - Seeking for my unique color.
を見て, 自分用スタイルを晒すようにして皆使い回せばいいんじゃないかと思ったので書いてみる. あんまり高度なことはしていない.
格子+暗号用になっているので他の分野の人には使い辛いでしょうねぇ. 論文によって署名だったり暗号だったりを扱うので, .styの方ではある程度の定義しかしていない. 毎回プリアンプルに

\newcommand{\DS}{\Scheme{DS}}
\newcommand{\DSKG}{\algo{G}}
\newcommand{\DSS}{\algo{S}}
\newcoomand{\DSV}{\algo{V}}

と書いて使っている.

%% 
%% This is file 'mystyle.sty'
\NeedsTeXFormat{LaTeX2e}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Theorems & Definitions
% acmthm用/llncsを使うときは消す
\newtheorem{theorem}{Theorem}[section]
\newtheorem{claim}[theorem]{Claim}
\newtheorem{proposition}[theorem]{Proposition}
\newtheorem{lemma}[theorem]{Lemma}
\newtheorem{corollary}[theorem]{Corollary}
\newtheorem{conjecture}[theorem]{Conjecture}
\newtheorem{observation}[theorem]{Observation}
%
\theoremstyle{definition}
\newtheorem{definition}[theorem]{Definition}
\newtheorem{construction}[theorem]{Construction}
\newtheorem{example}[theorem]{Example}
\newtheorem{algorithm}[theorem]{Algorithm}
\newtheorem{PKC}[theorem]{Cryptosystem}
\newtheorem{protocol}[theorem]{Protocol}
\newtheorem{signature}[theorem]{Signature Scheme}
\newtheorem{remark}[theorem]{Remark}
\newtheorem{assumption}[theorem]{Assumption}
% \newtheorem*{remark0}{\indent\sc Remark}
%\newtheorem*{definition0}{\noindent\sc Definition}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Hyphenation
%
\hyphenation{Gauss-ian Gold-reich cryp-to-sys-tem cryp-to-sys-tems}
%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Utilities
%
\def\magicwand{\itemsep=0pt\parskip=0pt\topskip=0pt}
\newcommand{\ignore}[1]{}
\newcommand{\hs}[1]{\hspace*{ #1 mm}}
\newcommand{\vs}[1]{\vspace*{ #1 mm}}
% Barakのパクリ
\newcommand{\eqdef}{\stackrel{def}{=}}
\newcommand{\eqeq}{\stackrel{\rm ?}{=}}
\newcommand{\inr}{\in_{\mbox{\tiny R}}}
\newcommand{\getsr}{\gets_{\mbox{\tiny R}}}
\newcommand{\bits}{\{0,1\}}
% 自分用
% 関数/作用素
\newcommand{\poly}{\mathop{\mathrm{poly}}\nolimits}
\newcommand{\vol}{\mathop{\mathrm{vol}}\nolimits}
\newcommand{\diam}{\mathop{\mathrm{diam}}\nolimits}
\newcommand{\Part}{\mathop{\mathrm{part}}\nolimits}
\newcommand{\Span}{\mathop{\mathrm{span}}\nolimits}
\newcommand{\Round}{\mathop{\mathrm{round}}\nolimits}
\newcommand{\Dist}{\mathop{\mathrm{Dist}}\nolimits}
\newcommand{\View}{\mathop{\mathrm{View}}\nolimits}
\newcommand{\Hom}{\mathop{\mathrm{Hom}}\nolimits}
\newcommand{\Ker}{\mathop{\mathrm{Ker}}\nolimits}
\newcommand{\Img}{\mathop{\mathrm{Im}}\nolimits}
\newcommand{\rank}{\mathop{\mathrm{rank}}\nolimits}
\newcommand{\SD}[2]{\Delta\left(#1,#2\right)}
\def\tr#1{\mathord{\mathopen{{\vphantom{#1}}^t}#1}}
% SETS
\newcommand{\Nset}{\mathbb{N}}
\newcommand{\Zset}{\mathbb{Z}}
\newcommand{\Qset}{\mathbb{Q}}
\newcommand{\Rset}{\mathbb{R}}
\newcommand{\Tset}{\mathbb{T}}
\newcommand{\Cset}{\mathbb{C}}
\newcommand{\Fset}{\mathbb{F}}
%%
\newcommand{\Vec}[1]{\boldsymbol{#1}}
\newcommand{\Mat}[1]{\boldsymbol{#1}}
\newcommand{\Pol}[1]{\mathsf{#1}}
\newcommand{\round}[1]{\mathrm{round}\left( #1 \right)}
\newcommand{\frc}[1]{\mathrm{frc}\left( #1 \right)}
\newcommand{\frcq}[1]{\mathrm{frc}_{q}\left( #1 \right)}
\newcommand{\angles}[1]{\langle{#1}\rangle}
\newcommand{\near}[1]{\left\lfloor{#1}\right\rceil}
\newcommand{\floor}[1]{\left\lfloor{#1}\right\rfloor}
\newcommand{\ceil}[1]{\left\lceil{#1}\right\rceil}
\newcommand{\abs}[1]{\left\lvert{#1}\right\rvert}
\newcommand{\leng}[1]{\left\lvert{#1}\right\rvert}
\newcommand{\card}[1]{\left\lvert{#1}\right\rvert}
\newcommand{\norm}[1]{\left\lVert{#1}\right\rVert}
\newcommand{\ip}[2]{\langle{#1},{#2}\rangle}
\newcommand{\desc}[1]{\left\langle{#1}\right\rangle}
\newcommand{\ideal}[1]{\langle{#1}\rangle}
\newcommand{\conc}{\circ}
%
\newcommand{\Rot}{\mathop{\mathrm{Rot}}\nolimits}
\newcommand{\rot}{\mathop{\mathrm{rot}}\nolimits}
\newcommand{\ROT}{\mathop{\mathnormal{ROT}}\nolimits}
\newcommand{\rev}{\mathop{\mathrm{rev}}\nolimits}
\newcommand{\rec}{\mathop{\mathrm{rec}}\nolimits}
\newcommand{\ord}{\mathop{\mathrm{ord}}\nolimits}
\newcommand{\problem}[1]{\ensuremath{\mathsf{#1}}}
%% keys
\newcommand{\keys}[1]{\mathit{#1}}
\newcommand{\ek}{\keys{ek}}
\newcommand{\dk}{\keys{dk}}
\newcommand{\vk}{\keys{vk}}
\newcommand{\sk}{\keys{sk}}
\newcommand{\pk}{\keys{pk}}
\newcommand{\usk}{\keys{usk}}
\newcommand{\upk}{\keys{upk}}
\newcommand{\gsk}{\keys{g}\kern-.05em\keys{sk}}
\newcommand{\gpk}{\keys{gpk}}
\newcommand{\params}{\keys{param}}
\newcommand{\acc}{\mathsf{accept}}
\newcommand{\rej}{\mathsf{reject}}
%Advarsary
\newcommand{\adv}[1]{\mathcal{#1}}
\newcommand{\ADV}{\mathbf{Adv}}
\newcommand{\EXP}{\mathbf{Exp}}
\newcommand{\atknm}[1]{\textnormal{#1}}
\newcommand{\EUFCMA}{\atknm{euf-cma}}
\newcommand{\IMPCA}{\atknm{imp-ca}}
\newcommand{\Oracle}[1]{\textsc{#1}}
%Scheme
\newcommand{\Scheme}[1]{\mathcal{#1}}
\newcommand{\algo}[1]{\mathsf{#1}}
%Theorem Barakのパクリ
%\newcommand{\namedref}[2]{\hyperref[#2]{#1~\ref*{#2}}} 
\newcommand{\namedref}[2]{#1~\ref{#2}}
\newcommand{\chapterref}[1]{\namedref{Chapter}{#1}}
\newcommand{\sectionref}[1]{\namedref{Section}{#1}}
\newcommand{\appendixref}[1]{\namedref{Appendix}{#1}}
\newcommand{\theoremref}[1]{\namedref{Theorem}{#1}}
\newcommand{\remarkref}[1]{\namedref{Remark}{#1}}
\newcommand{\definitionref}[1]{\namedref{Definition}{#1}}
\newcommand{\lemmaref}[1]{\namedref{Lemma}{#1}}
\newcommand{\claimref}[1]{\namedref{Claim}{#1}}
\newcommand{\constructionref}[1]{\namedref{Construction}{#1}}
\newcommand{\itemref}[1]{\namedref{Item}{#1}}
\newcommand{\propertyref}[1]{\namedref{Property}{#1}}
\newcommand{\protocolref}[1]{\namedref{Protocol}{#1}}
\newcommand{\algorithmref}[1]{\namedref{Algorithm}{#1}}
\newcommand{\assumptionref}[1]{\namedref{Assumption}{#1}}
\newcommand{\figureref}[1]{\namedref{Figure}{#1}}
\newcommand{\tableref}[1]{\namedref{Table}{#1}}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% General Boxes
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\newcommand{\inlinenote}[1]{{[{\bf NOTE:} #1]}}
\newcommand{\DingFingerWhite}{\ding{"2B}}
\newcommand{\DingFingerBlack}{\ding{"2A}}
\newcommand{\DingFingerWithPen}{\ding{"2D}}
\newcommand{\DingCheckShin}{\ding{"33}}
\newcommand{\DingCheckBold}{\ding{"34}}
% for box
\setlength{\fboxsep}{0.8em}
\newenvironment{MyRemark}%
{\smallskip
 \begin{quote}
 \begin{boxedminipage}{.94\textwidth}
 {\LARGE \DingFingerWhite}  }
{\end{boxedminipage}
 \end{quote}
 \smallskip}
% for box
\newenvironment{MyNote}%
{\smallskip
 \begin{quote}
 \begin{boxedminipage}{15cm}
 {\LARGE \DingCheckShin}  }
{\end{boxedminipage}
 \end{quote}
 \smallskip}
%% End of file 'mystyle.sty'

ベクトルはボールドイタリックということなので直した.