[Rivet-svn] rivet: Add relsize.sty

Rivet Mercurial rivet at projects.hepforge.org
Wed Mar 2 16:45:02 GMT 2016


details:   https://rivet.hepforge.org/hg/rivet/rev/bbf0941370fb
branches:  release-2-4-x
changeset: 5007:bbf0941370fb
user:      Andy Buckley <andy at insectnation.org>
date:      Wed Mar 02 16:36:51 2016 +0000
description:
Add relsize.sty

diffs (truncated from 400 to 50 lines):

--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/data/texmf/tex/latex/relsize/relsize.sty	Wed Mar 02 16:36:51 2016 +0000
@@ -0,0 +1,397 @@
+% relsize.sty       4.1       Mar 29, 2013
+% 
+% Setting the font size relative to the current size
+% 
+% Authored by Donald Arseneau <asnd at triumf.ca> and Matt Swift <swift at bu.edu>.
+% (Inspired by smaller.sty author Bernie Cosell)
+% 
+% This software is contributed to the public domain by its authors, who disclaim
+% all copyrights. For people and jurisdictions that do not recognize contribution
+% to the public domain, this software is licensed by the terms of the unlicense, 
+% <http://unlicense.org/>
+%
+% commands are:
+% \relsize{n}  where n gives the number of steps ("mag-step" = factor of 1.2)
+%              to change the size by;  n = 3 changes from \normalsize to 
+%              \LARGE size.  Negative n selects smaller fonts. n is an
+%              integer (or half-integer).
+%
+% \smaller = \relsize{-1},  \smaller[n] = \relsize{-n}
+% \larger  = \relsize{1},   \larger[n]  = \relsize{n}
+%
+% \textsmaller{text}, \textlarger{text} - versions that take an argument
+%
+% \relscale{f}   like \relsize, but instead of scale-steps,
+%                the parameter is a scale factor, such as .75
+% \textscale{f}{text}
+%
+% The font-size command nearest the requested size will be used, and if
+% the size error is more than \RSpercentTolerance, then the size will
+% be adjusted more precisely using \fontsize.  (The default empty 
+% \RSpercentTolerance signals automatic handling, choosing the tolerance 
+% based on the font declarations.)
+%
+% \mathsmaller{A}, \mathlarger{B}       - math versions 
+%   (The math versions are entirely different from the text versions.)
+%
+% More comments at the end of this file, and full documentation in
+% relsize-doc.pdf
+
+\ProvidesPackage{relsize}[2013/03/29 ver 4.1]
+
+\DeclareRobustCommand\relsize[1]{%
+\ifmmode \@nomath\relsize\else
+  \begingroup
+  % number of demi-magsteps -> \@tempcnta
+  \@tempdima#1\p@ \@tempdima2.0002\@tempdima \divide\@tempdima\p@
+  \@tempcnta\@tempdima


More information about the Rivet-svn mailing list