From 7f7ad97d2c0c901fc9e2583ba37fac26e15b3a54 Mon Sep 17 00:00:00 2001 From: Manuel Pégourié-Gonnard Date: Thu, 3 Jul 2008 20:44:06 +0000 Subject: new encxvlna packages git-svn-id: svn://tug.org/texlive/trunk@9194 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/encxvlna/encxvlna.sty | 97 +++++++++++++++++++++++ 1 file changed, 97 insertions(+) create mode 100644 Master/texmf-dist/tex/latex/encxvlna/encxvlna.sty (limited to 'Master/texmf-dist/tex/latex/encxvlna') diff --git a/Master/texmf-dist/tex/latex/encxvlna/encxvlna.sty b/Master/texmf-dist/tex/latex/encxvlna/encxvlna.sty new file mode 100644 index 00000000000..eafcff07043 --- /dev/null +++ b/Master/texmf-dist/tex/latex/encxvlna/encxvlna.sty @@ -0,0 +1,97 @@ +\ProvidesPackage{encxvlna}[2008/06/20 encxvlna] +\PackageInfo{encxvlna}{$Id: encxvlna.sty 209 2008-06-20 21:34:39Z zw $\MessageBreak + (C) 2007, Zdenek Wagner, derived from vlna.tex\MessageBreak + developed by Petr Olsak\@gobble} + +% Vlna implementovana jako makra v encTeXu +%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +% Leden 2003 Petr Olsak +% Modified for LaTeX by Z. Wagner + +%% Copyright 2008 Z. Wagner, http://icebearsoft.euweb.cz +% +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% +% The Current Maintainer of this work is Z. Wagner. +% +% This work consists of the files the name of which are listed +% in the documentation, see encxvlna.pdf in the doc directory. + +\expandafter\ifx\csname mubyte\endcsname\relax + \PackageError{encxvlna}{% + encTeX of Feb 2003 or later not detected,\MessageBreak + the rest of the package will be ignored}% + {This package is implemented by new primitives of encTeX of Feb 2003\MessageBreak + but this extension was not detected in your system. You can continue\MessageBreak + but all commands of `encxvlna' will be ignored. If your TeX distribution\MessageBreak + contains encTeX but does not activate it, you have to create the format\MessageBreak + using the -enc switch (e.g. in fmtutils.cnf). If you do not have encTeX\MessageBreak + at all, you have to compile it from the source code. You can find\MessageBreak + the source code including documentation at\MessageBreak + http://math.feld.cvut.cz/olsak/enctex.html + } % Package error message + \expandafter\endinput\fi + +% Toto je ukazka moznosti encTeXu. Na urovni maker muzeme +% naprogramovat program vlna. + +% Pomocna makra: + +\def\setmu #1#2{\mubyte #1##1 #2\endmubyte} % use encTeX Feb 2003 +\bgroup \uccode`X=\endlinechar \uppercase{\gdef\endchar{X}} + \uccode`X=`\{ \uppercase{\gdef\leftbrace{X}} +\egroup + +\def\sylabi #1{% + \setmu \spacesylab {\space#1} % v lese -> v~lese + \setmu \normalsylab {(#1} % (v lese -> (v~lese + \setmu \normalsylab {\endchar#1} % v lese -> v~lese + \setmu \normalsylab {[#1} % [v lese -> [v~lese + \setmu \specsylab {\leftbrace#1} % {v lese -> {v~lese + \setmu \normalsylab {"`#1} % "`v lese -> "`v~lese (uvozovky "`..."') +} +% dve moznosti za predlozkou: mezera nebo konec radku: + +\def\sylab #1{\sylabi {#1\space}\sylabi {#1\endchar}} + +% seznam predlozek: + +\sylab v \sylab k \sylab o \sylab s \sylab u \sylab z +\sylab V \sylab K \sylab O \sylab S \sylab U \sylab Z +\sylab A \sylab I \sylab i \sylab a + +% makra neudelaji nic v matematickem modu a verbatim prostredi: +% take se spravne prenesou do \tableofcontents + +\def\ZW@exx{\expandafter\expandafter\expandafter + \expandafter\expandafter\expandafter\expandafter + \expandafter\expandafter\expandafter\expandafter + \expandafter\expandafter\expandafter\expandafter} +\def\spacesylab {\ifx\protect\@typeset@protect \ifx\rm\@empty\else + \ifmmode\else\ifnum\catcode`\ =10 \ZW@exx\spacesylabP \fi\fi\fi\fi} +\def\normalsylab {\ifx\protect\@typeset@protect \ifx\rm\@empty\else + \ifmmode\else\ifnum\catcode`\ =10 \ZW@exx\normalsylabP \fi\fi\fi\fi} +\def\specsylab {\ifx\protect\@typeset@protect \ifx\rm\@empty\else + \ifmmode\else\ifnum\catcode`\ =10 \ZW@exx\specsylabP \fi\fi\fi\fi} + +\def\spacesylabP {\afterassignment\spacesylabR \let\next= } +\def\spacesylabR {\ifhmode\unskip\fi \next \normalsylabP} +\def\normalsylabP #1 {#1~} +\def\specsylabP #1{{\normalsylabP #1}} + +\AtBeginDocument{\mubytein=2 \mubyteout=3 \mubytelog=3 \relax} % potrebujeme i konstrukce "a v lese -> a~v~lese" + +% For use with microtype.sty + +\def\zw@vlnahook{\g@addto@macro\MT@begin@catcodes{\mubytein 0 }} +\expandafter\ifx\csname MT@setupfont\endcsname\relax + \AtBeginDocument{\expandafter\ifx\csname MT@setupfont\endcsname\relax\else\zw@vlnahook\fi}% +\else \zw@vlnahook \fi -- cgit v1.2.3