From e0c6872cf40896c7be36b11dcc744620f10adf1d Mon Sep 17 00:00:00 2001 From: Norbert Preining Date: Mon, 2 Sep 2019 13:46:59 +0900 Subject: Initial commit --- macros/latex/contrib/fragments/README | 7 ++++ macros/latex/contrib/fragments/checklab.tex | 41 +++++++++++++++++++++++ macros/latex/contrib/fragments/overrightarrow.sty | 14 ++++++++ macros/latex/contrib/fragments/removefr.tex | 13 +++++++ macros/latex/contrib/fragments/subscript.sty | 18 ++++++++++ 5 files changed, 93 insertions(+) create mode 100644 macros/latex/contrib/fragments/README create mode 100644 macros/latex/contrib/fragments/checklab.tex create mode 100644 macros/latex/contrib/fragments/overrightarrow.sty create mode 100644 macros/latex/contrib/fragments/removefr.tex create mode 100644 macros/latex/contrib/fragments/subscript.sty (limited to 'macros/latex/contrib/fragments') diff --git a/macros/latex/contrib/fragments/README b/macros/latex/contrib/fragments/README new file mode 100644 index 0000000000..18b6e0083a --- /dev/null +++ b/macros/latex/contrib/fragments/README @@ -0,0 +1,7 @@ +This directory contains fragments of TeX code designed to work in the +environment of LaTeX. They are made available for the benefit of +those writing LaTeX classes or packages. + +Robin Fairbairns + +8th December 1994 diff --git a/macros/latex/contrib/fragments/checklab.tex b/macros/latex/contrib/fragments/checklab.tex new file mode 100644 index 0000000000..9799a485b8 --- /dev/null +++ b/macros/latex/contrib/fragments/checklab.tex @@ -0,0 +1,41 @@ + % Making those `Label(s) have changed\dots' messages more explicit +% +% The \LaTeX{} kernel produces the messages when something, while the +% |.aux| file is being scanned (after the \cs{AtEndDocument} tokens +% have been executed), sets the \cs{if@tempswa} switch with the +% command \cs{@tempswatrue}. +% +% (This fact can be used by packages, such as my |footmisc.sty|, to +% piggy-back on the message; but it's nice in that circumstance and +% others to be sure where the message is coming from.) +% +% This is a jiffy patch to the kernel so that it produces a +% (\cs{typeout}) message for each label \emph{it} thinks has changed. +% +% Usage: Incorporate this code into a package or class file, or +% \input this file from a package or class file, or +% \makeatletter \input{checklab} \makeatother in your document +% preamble +% +% This software jiffy is placed in the public domain. Do with it as +% you wish, though I have to say I would prefer you not to claim it +% as your own (otoh, it's the product of a twisted mind, so probably +% not an attractive thing to claim). +% +% Robin Fairbairns (rf10@cl.cam.ac.uk) +% Produced in this form 1999/01/15 +% +\def\@testdef #1#2#3{% + \def\reserved@a{#3}% + \expandafter \ifx \csname #1@#2\endcsname \reserved@a + \else + \@tempswatrue + \typeout{label change: #1@#2 was + \expandafter \ifx \csname #1@#2\endcsname \relax + unset + \else + \csname#1@#2\endcsname\space + \fi + now #3}% + \fi +} diff --git a/macros/latex/contrib/fragments/overrightarrow.sty b/macros/latex/contrib/fragments/overrightarrow.sty new file mode 100644 index 0000000000..59d89ad0e9 --- /dev/null +++ b/macros/latex/contrib/fragments/overrightarrow.sty @@ -0,0 +1,14 @@ +% This is overrightarrow.sty, It provides for a command: +% \Overrightarrow which is somewhat like \overrightarrow and somewhat +% like \Rightarrow. Also a couple of helper commands. +% This file is public domain. +% James Kilfiger mapdn@csv.warwick.ac.uk +% +\newcommand\reldoublebar{\mathrel{\smash=}} +\newcommand{\Rightarrowfill@}[1]{% +\m@th \setboxz@h {$#1\reldoublebar $}\ht \z@ \z@ +$#1\copy \z@ +\mkern -6mu\cleaders \hbox {$#1\mkern -2mu\box \z@ \mkern -2mu$}\hfill +\mkern -6mu +\mathord \Rightarrow $} +\newcommand{\Overrightarrow}{\mathpalette{\overarrow@\Rightarrowfill@}} diff --git a/macros/latex/contrib/fragments/removefr.tex b/macros/latex/contrib/fragments/removefr.tex new file mode 100644 index 0000000000..2a58ebf2d7 --- /dev/null +++ b/macros/latex/contrib/fragments/removefr.tex @@ -0,0 +1,13 @@ +%Date: Sat, 30 Jul 1994 17:58:55 PST +%From: Donald Arseneau +% +% \@removefromreset{FOO}{BAR} : Removes counter FOO from the list of +% counters \cl@BAR to be reset when counter BAR +% is stepped. The opposite of \@addtoreset. + +\def\@removefromreset#1#2{\let\@tempb\@elt + \expandafter\let\expandafter\@tempa\csname c@#1\endcsname + \def\@elt##1{\expandafter\ifx\csname c@##1\endcsname\@tempa\else + \noexpand\@elt{##1}\fi}% + \expandafter\edef\csname cl@#2\endcsname{\csname cl@#2\endcsname}% + \let\@elt\@tempb} diff --git a/macros/latex/contrib/fragments/subscript.sty b/macros/latex/contrib/fragments/subscript.sty new file mode 100644 index 0000000000..fc9f6e34f4 --- /dev/null +++ b/macros/latex/contrib/fragments/subscript.sty @@ -0,0 +1,18 @@ +% subscript.sty +% +% Copyright 1999 Robin Fairbairns +% +% this fragment is distributed under the conditions of the LaTeX +% Project Public Licence -- see lppl.txt in the LaTeX distribution +% +% this fragment provides a command \textsubscript, which is +% shamelessly copied from the command \textsuperscript that's part of +% LaTeX +% +% the fragment may be used as a package in its own right, if so +% needed. + +\DeclareRobustCommand*\textsubscript[1]{% + \@textsubscript{\selectfont#1}} +\def\@textsubscript#1{% + {\m@th\ensuremath{_{\mbox{\fontsize\sf@size\z@#1}}}}} -- cgit v1.2.3