diff options
author | Karl Berry <karl@freefriends.org> | 2009-09-30 00:11:25 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-09-30 00:11:25 +0000 |
commit | 7a3ad37ae5debe7d7427c0b1efa3e89ad19e59e4 (patch) | |
tree | 5787f38655846985f475303beac52825f86d6637 /Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty | |
parent | 5e098aa246078165cc3b574dd5568e8b1fed2ea0 (diff) |
tex gyre 2.003 (29sep09)
git-svn-id: svn://tug.org/texlive/trunk@15567 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty | 38 |
1 files changed, 30 insertions, 8 deletions
diff --git a/Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty b/Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty index 620bc3a82c0..6ce8d3a2daf 100644 --- a/Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty +++ b/Master/texmf-dist/tex/latex/tex-gyre/tgcursor.sty @@ -8,13 +8,13 @@ %% ---------------------------------------------------------------------------- %% [EN] LaTeX2e support for Tex Gyre Cursor fonts %% The declaration `\usepackage{tgcursor}' in the LaTeX preamble -%% will set TeX Gyre Cursor as the default (serif) font for the document. +%% will set TeX Gyre Cursor as the default typewriter font for the document. %% %% [PL] Wspomaga stosowanie w LaTeXu kroju Tex Gyre Cursor %% Umieszczenie linijki `\usepackage{tgcursor}' w preambule spowoduje -%% ustawienie TeX Gyre Cursor jako podstawowego szeryfowego kroju -%% dokumentu, czyli kroju skojarzonego z poleceniem \rmfamily. -%% W dokumentach po polsku konieczne jest uaktywnienie kodowania +%% ustawienie TeX Gyre Cursor jako podstawowego maszynowego kroju +%% dokumenu, czyli kroju skojarzonego z poleceniem \ttfamily. +%% W dokumenach po polsku konieczne jest uaktywnienie kodowania %% T1, QX lub OT4 (najlepiej przy pomocy pakietu 'polski'). Np.: %% %% \usepackage{tgcursor} @@ -24,11 +24,33 @@ \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{tgcursor} - [2006/11/01 v1.0 TeX Gyre Cursor as default roman family] + [2009/09/10 v1.2 TeX Gyre Cursor as default typewriter family] -\renewcommand{\rmdefault}{qcr} -\renewcommand{\familydefault}{\rmdefault} -\fontfamily{\familydefault} +\def\tg@scale@to@rm#1#2{% + \begingroup + \fontsize{10}{0}\usefont{\encodingdefault}{\rmdefault}{m}{n}% + #1% + \xdef\qcr@scale{% + \strip@pt + \dimexpr 1pt * + \@tempdima / \dimexpr#2pt\relax + \relax}% + \PackageInfo{tgcursor}{The qcr family is scaled by \qcr@scale} + \endgroup +} + +\RequirePackage{kvoptions} +\SetupKeyvalOptions{prefix=qcr@} +\DeclareStringOption{scale}[1] +\define@key{tgcursor}{matchlowercase}[1]{% + \tg@scale@to@rm{\@tempdima#1\fontdimen5\font}{4.17}} +\define@key{tgcursor}{matchuppercase}[1]{% + \tg@scale@to@rm{\setbox0\hbox{XWYZH}\@tempdima#1\ht0}{5.69498}} +\DeclareVoidOption{oldspacing}{} +\ProcessKeyvalOptions* + +\renewcommand{\ttdefault}{qcr} +\renewcommand\bfdefault{b} \endinput %% |