summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/polski/polski.sty
blob: 075b7c189d9ba27ab7e691ed5c8549a75922fdad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
%%
%% This is file `polski.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% polski.dtx  (with options: `style')
%% 
%% This is a generated file.
%% 
%% Copyright (C) 1994 by Mariusz Olko.  All rights reserved.
%% Copyright (C) 1997, 1998 by Mariusz Olko and Marcin Woli\'nski.
%% Copyright (C) 2000, 2002, 2003, 2007, 2017 by Marcin Woli\'nski.
%% 
%% 
%% This file is part of the package `Polski'
%% -----------------------------------------
%% 
%% It may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.2
%% 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.2 or later is part of all distributions of LaTeX
%% version 1999/12/01 or later.
%% 
%% This file may only be distributed together with a copy of the 'Polski'
%% package.
%% 
\NeedsTeXFormat{LaTeX2e}[1996/12/01]
\ProvidesPackage{polski}[2017/05/04 v1.3.4 Polish language package]
\begingroup
\def\t#1#2!{\def\s{#2}}\t ą!%
\expandafter\endgroup\ifx\s\empty\else
\@ifpackageloaded{inputenc}{\typeout{\space\space\space
                      Inputenc package detected. Catcodes not changed.}}{%
\catcode`\^^a1=11 %\lccode`\^^a1=`\^^a1 \uccode`\^^a1=`\^^81  % a ogonek
\catcode`\^^a2=11 %\lccode`\^^a2=`\^^a2 \uccode`\^^a2=`\^^82  % c acute
\catcode`\^^a6=11 %\lccode`\^^a6=`\^^a6 \uccode`\^^a6=`\^^86  % e ogonek
\catcode`\^^aa=11 %\lccode`\^^aa=`\^^aa \uccode`\^^aa=`\^^8a  % l crossed
\catcode`\^^ab=11 %\lccode`\^^ab=`\^^ab \uccode`\^^ab=`\^^8b  % n acute
\catcode`\^^f3=11 %\lccode`\^^f3=`\^^f3 \uccode`\^^f3=`\^^d3  % o acute
\catcode`\^^b1=11 %\lccode`\^^b1=`\^^b1 \uccode`\^^b1=`\^^91  % s acute
\catcode`\^^bb=11 %\lccode`\^^bb=`\^^bb \uccode`\^^bb=`\^^9b  % z dot
\catcode`\^^b9=11 %\lccode`\^^b9=`\^^b9 \uccode`\^^b9=`\^^99  % z acute
\catcode`\^^81=11 %\lccode`\^^81=`\^^a1 \uccode`\^^81=`\^^81  % A ogonek
\catcode`\^^82=11 %\lccode`\^^82=`\^^a2 \uccode`\^^82=`\^^82  % C accute
\catcode`\^^86=11 %\lccode`\^^86=`\^^a6 \uccode`\^^86=`\^^86  % E ogonek
\catcode`\^^8a=11 %\lccode`\^^8a=`\^^aa \uccode`\^^8a=`\^^8a  % L crossed
\catcode`\^^8b=11 %\lccode`\^^8b=`\^^ab \uccode`\^^8b=`\^^8b  % N accute
\catcode`\^^d3=11 %\lccode`\^^d3=`\^^f3 \uccode`\^^d3=`\^^d3  % O acute
\catcode`\^^91=11 %\lccode`\^^91=`\^^b1 \uccode`\^^91=`\^^91  % S acute
\catcode`\^^9b=11 %\lccode`\^^9b=`\^^bb \uccode`\^^9b=`\^^9b  % Z dot
\catcode`\^^99=11 %\lccode`\^^99=`\^^b9 \uccode`\^^99=`\^^99  % Z acute
}
\sfcode`\^^81=999    % A ogonek
\sfcode`\^^82=999    % C acute
\sfcode`\^^86=999    % E ogonek
\sfcode`\^^8a=999    % L crossed
\sfcode`\^^8b=999    % N acute
\sfcode`\^^d3=999    % O acute
\sfcode`\^^91=999    % S acute
\sfcode`\^^9b=999    % Z dot
\sfcode`\^^99=999    % Z acute
\DeclareMathSymbol{^^a1}{\mathalpha}{letters}{`^^a1}
\DeclareMathSymbol{^^a2}{\mathalpha}{letters}{`^^a2}
\DeclareMathSymbol{^^a6}{\mathalpha}{letters}{`^^a6}
\DeclareMathSymbol{^^aa}{\mathalpha}{letters}{`^^aa}
\DeclareMathSymbol{^^ab}{\mathalpha}{letters}{`^^ab}
\DeclareMathSymbol{^^f3}{\mathalpha}{letters}{`^^f3}
\DeclareMathSymbol{^^b1}{\mathalpha}{letters}{`^^b1}
\DeclareMathSymbol{^^bb}{\mathalpha}{letters}{`^^bb}
\DeclareMathSymbol{^^b9}{\mathalpha}{letters}{`^^b9}
\DeclareMathSymbol{^^81}{\mathalpha}{letters}{`^^81}
\DeclareMathSymbol{^^82}{\mathalpha}{letters}{`^^82}
\DeclareMathSymbol{^^86}{\mathalpha}{letters}{`^^86}
\DeclareMathSymbol{^^8a}{\mathalpha}{letters}{`^^8a}
\DeclareMathSymbol{^^8b}{\mathalpha}{letters}{`^^8b}
\DeclareMathSymbol{^^d3}{\mathalpha}{letters}{`^^d3}
\DeclareMathSymbol{^^91}{\mathalpha}{letters}{`^^91}
\DeclareMathSymbol{^^9b}{\mathalpha}{letters}{`^^9b}
\DeclareMathSymbol{^^99}{\mathalpha}{letters}{`^^99}
\fi
\ifx\l@nohyphenation\@undefined
        \newlanguage\l@nohyphenation
\fi
\def\selecthyphenation#1{%
  \expandafter\ifx\csname l@#1\endcsname\relax
    \PackageError{polski}{No hyphenation patterns for language `#1'}
      {Hyphenation in this language will be disabled.}%
    \selecthyphenation{nohyphenation}%
  \else
    \language\csname l@#1\endcsname
  \fi
  }
\begingroup\expandafter\expandafter\expandafter\endgroup
\expandafter\ifx\csname directlua\endcsname\relax
\else
\expandafter\ifx\csname l@polish\endcsname\relax
\newlanguage\l@polish
\language\l@polish
\InputIfFileExists{hyph-pl}{}{%
  \PackageError{polski}{Couldn't load hyphenation patterns for Polish}%
  {Missing file hyph-pl.tex from the hyph-utf8 project.}%
}%
\fi\fi
\ifx\polish\undefined
  \selecthyphenation{polish}
\else
    \language\polish
\fi
\lefthyphenmin=2
\righthyphenmin=2
\def\Slash{/}
\def\PLSlash#1{%
  \ifx#1\PLSlash
    \ifx\protect\@typeset@protect\else\protect\string\fi\Slash
  \else
    \expandafter \ifx \csname PLSlash@\string#1\endcsname \relax
      \PLSlash@error#1%
    \else
      \expandafter\expandafter\expandafter\PLSlash@letter
      \expandafter\expandafter\expandafter#1%
    \fi
  \fi
}

\def\PLSlash@error#1{\PackageError{polski}{%
Illegal pair of characters /\noexpand#1 occurred}{%
Only a character from the set [acelnosxzACELNOSXZ,'<>/-]
                                        can appear after \Slash.\MessageBreak
Proceed, I will omit both \Slash\ and the character following it.\MessageBreak
You can also correct your mistake NOW, typing I followed by\MessageBreak
whatever should be in the place of the offending pair.}}
\def\PlPrIeC{%
  \ifx\protect\@typeset@protect
    \expandafter\@firstofone
  \else
    \noexpand\PlPrIeC
  \fi
}
\def\PLSlash@letter#1{\csname PLSlash@#1\endcsname}
\def\PL@accent@def#1#2{%
  \expandafter\def \csname PLSlash@\string #1\endcsname{#2}}
\PL@accent@def{a}{\k a}
\PL@accent@def{c}{\@tabacckludge'c}
\PL@accent@def{e}{\k e}
\PL@accent@def{l}{\PlPrIeC{\l}}
\PL@accent@def{n}{\@tabacckludge'n}
\PL@accent@def{o}{\@tabacckludge'o}
\PL@accent@def{s}{\@tabacckludge's}
\PL@accent@def{x}{\@tabacckludge'z}
\PL@accent@def{z}{\.z}
\PL@accent@def{A}{\k A}
\PL@accent@def{C}{\@tabacckludge'C}
\PL@accent@def{E}{\k E}
\PL@accent@def{L}{\PlPrIeC{\L}}
\PL@accent@def{N}{\@tabacckludge'N}
\PL@accent@def{O}{\@tabacckludge'O}
\PL@accent@def{S}{\@tabacckludge'S}
\PL@accent@def{X}{\@tabacckludge'Z}
\PL@accent@def{Z}{\.Z}
\PL@accent@def{<}{\PlPrIeC{\guillemotleft}}
\PL@accent@def{>}{\PlPrIeC{\guillemotright}}
\PL@accent@def{,}{\PlPrIeC{\quotedblbase}}
\PL@accent@def{'}{\PlPrIeC{\textquotedblright}}
\PL@accent@def{-}{\PlPrIeC{\dywiz}}
\let \PL@accent@def \undefined
\@ifpackageloaded{plprefix}{}{%
    \def\prefixing{\catcode`/=\active
        \bgroup \uccode`\~=`/ \uppercase{\egroup \let~\PLSlash}%
        \let\pr@fix=T}
    \def\nonprefixing{\catcode`/=12 \let\pr@fix=F}
}
\def\arc#1{\mathop{\operator@font
     arc\thinspace\escapechar-1 \string#1}\nolimits}
\def\ar#1{\mathop{\operator@font
     ar\thinspace\escapechar-1 \string#1}\nolimits}
\def\tg{\mathop{\operator@font tg}\nolimits}
\def\ctg{\mathop{\operator@font ctg}\nolimits}
\def\tgh{\mathop{\operator@font tgh}\nolimits}
\def\ctgh{\mathop{\operator@font ctgh}\nolimits}
\def\nwd{\mathop{\operator@font nwd}}
\def\PL@redef@funcnames{%
  \let\tan=\tg     \let\cot=\ctg
  \let\tanh=\tgh   \let\coth=\ctgh
  \def\arcsin{\arc\sin}
  \def\arccos{\arc\cos}
  \def\arctan{\arc\tg}
  \def\arccot{\arc\ctg}
  \let\gcd\nwd
  }
\def\dywiz{\kern0sp\discretionary{-}{-}{-}\penalty10000\hskip0sp\relax}
\newcommand*\pauza{\unskip\kern.2em\textemdash\hskip.2em\ignorespaces}
\newcommand*\ppauza{\unskip\kern.2em\textendash\hskip.2em\ignorespaces}
\def\prefacename{Przedmowa}
\def\refname{Literatura}
\def\abstractname{Streszczenie}
\def\bibname{Bibliografia}
\def\chaptername{Rozdzia\PLSlash l} % uppercasing in running head must work
\def\appendixname{Dodatek}
\def\contentsname{Spis tre\'sci}
\def\listfigurename{Spis rysunk\'ow}
\def\listtablename{Spis tabel}
\def\indexname{Skorowidz}
\def\figurename{Rysunek}
\def\tablename{Tabela}
\def\partname{Cz\k e\'s\'c}
\def\enclname{Za\l\k aczniki}
\def\ccname{Do wiadomo\'sci}
\def\headtoname{Do}
\def\pagename{Strona}
\def\seename{zob.}
\def\proofname{Dow\'od}
\def\today{\number\day~\ifcase\month\or
  stycznia\or lutego\or marca\or kwietnia\or maja\or czerwca\or
  lipca\or sierpnia\or wrze\'snia\or pa\'zdziernika\or
  listopada\or grudnia\fi \space\number\year \PLdateending}
\def\PL@setmaths{%
    \def\PLm@ths{}
    \@ifundefined{T@OT4}{%
      \input ot4enc.def
    }{}
    \SetMathAlphabet{\mathbf}{normal}{OT4}{cmr}{bx}{n}
    \SetMathAlphabet{\mathsf}{normal}{OT4}{cmss}{m}{n}
    \SetMathAlphabet{\mathit}{normal}{OT4}{cmr}{m}{it}
    \SetMathAlphabet{\mathtt}{normal}{OT4}{cmtt}{m}{n}
    \SetMathAlphabet{\mathsf}{bold}{OT4}{cmss}{bx}{n}
    \SetMathAlphabet{\mathit}{bold}{OT4}{cmr}{bx}{it}
    \bgroup\let\@font@warning\@font@info
    \SetSymbolFont{operators}   {normal}{OT4}{cmr} {m}{n}
    \SetSymbolFont{letters}     {normal}{OML}{plm} {m}{it}
    \SetSymbolFont{symbols}     {normal}{OMS}{plsy}{m}{n}
    \SetSymbolFont{largesymbols}{normal}{OMX}{plex}{m}{n}
    \SetSymbolFont{operators}   {bold}  {OT4}{cmr} {bx}{n}
    \SetSymbolFont{letters}     {bold}  {OML}{plm} {b}{it}
    \SetSymbolFont{symbols}     {bold}  {OMS}{plsy}{b}{n}
    \egroup
    \DeclareMathSymbol{\xleq}{3}{symbols}{172}
    \DeclareMathSymbol{\xgeq}{3}{symbols}{173}
}
\def\PL@redef@relations{
    \let\leq=\xleq
    \let\geq=\xgeq
    \let\le=\leq
    \let\ge=\geq
}
\DeclareOption{plmath}{%
    \PL@setmaths
}
\DeclareOption{nomathsymbols}{%
    \def\PLn@m@thsn@mes{}
}
\DeclareOption{MeX}{%
  \AtBeginDocument{%
    \@ifundefined{T@OT1}{}{%
    \DeclareTextCommand{\=}{OT1}{\dywiz}%
    \DeclareTextAccent{\macron}{OT1}{22}}%
    \@ifundefined{T@T1}{}{%
    \DeclareTextCommand{\=}{T1}{\dywiz}%
    \DeclareTextAccent{\macron}{T1}{9}}%
    \@ifundefined{T@OT4}{}{%
    \DeclareTextCommand{\=}{OT4}{\dywiz}%
    \DeclareTextAccent{\macron}{OT4}{22}}%
    \@ifundefined{T@QX}{}{%
    \DeclareTextCommand{\=}{QX}{\dywiz}%
    \DeclareTextAccent{\macron}{QX}{9}}%
    }%
    \let\xle\xleq
    \let\xge\xgeq
    \let\polish\l@polish
    \let\english\l@english
    \def\MeX{M\kern-.111em\lower.6ex\hbox{E}\kern-.075emX}
    \DeclareRobustCommand\LaMeX{%   after latex.dtx
        L\kern-.36em
        {\setbox0\hbox{T}%
         \vbox to\ht0{\hbox{%
                            \csname S@\f@size\endcsname
                            \fontsize\sf@size\z@
                            \math@fontsfalse\selectfont
                            A}
                      \vss}%
        }%
        \kern-.15em
        \MeX\@}%
    }
\DeclareOption{T1}{%
    \@ifundefined{T@T1}{\input{t1enc.def}}{}
    \def\encodingdefault{T1}\fontencoding{T1}%
    \def\PL@ncodingd@fined{}
}
\DeclareOption{QX}{%
    \@ifundefined{T@QX}{\input{qxenc.def}}{}
    \def\encodingdefault{QX}\fontencoding{QX}%
    \def\PL@ncodingd@fined{}
}
\DeclareOption{OT1}{%
    \def\encodingdefault{OT1}\fontencoding{OT1}%
    \def\PL@ncodingd@fined{}
}
\DeclareOption{OT4}{%
    \@ifundefined{T@OT4}{\input{ot4enc.def}}{}%
    \def\encodingdefault{OT4}%
    \fontencoding{OT4}%
    \def\PL@ncodingd@fined{}%
}
\DeclareOption{prefixinginverb}{%
        \def\PL@prefixinginverb{1}%
}
\DeclareOption{noprefixinginverb}{%
        \def\PL@prefixinginverb{0}%
}
\DeclareOption{roku}{%
   \def\PLdateending{\nobreakspace roku}
}
\DeclareOption{r.}{%
   \def\PLdateending{\nobreakspace r.}
}
\DeclareOption{noroku}{%
   \def\PLdateending{}
}
\ExecuteOptions{prefixinginverb,noroku}
\ProcessOptions
\frenchspacing
\def\tempa{OT1}
\ifx\tempa\f@encoding
    \@ifundefined{PL@ncodingd@fined}{%
        \IfFileExists{ot4cmr.fd}{%
            \typeout{\space\space\space
                Switching to Polish text encoding and Polish maths fonts.}
            \@ifundefined{T@OT4}{%
                \input ot4enc.def
            }{}%
            \def\encodingdefault{OT4}
            \fontencoding{OT4}\selectfont
            \PL@setmaths
        }{%
        \typeout{\space\space\space
          Can't locate Polish fonts.  Will use default encoding.}
        }%
        \def\@PL@OT@check{%
            \bgroup
                \def\tempa{OT1}\ifx\tempa\cf@encoding
                    \@ifpackageloaded{ot1patch}{}{%
                        \PackageError{polski}{%
Zaczynasz skladac dokument uzywajac oryginalnych\MessageBreak
czcionek TeXa.  Czcionki te nie maja kompletu polskich\MessageBreak
znakow.  W zwiazku z tym LaTeX bedzie zglaszal bledy.\MessageBreak
\MessageBreak
Zainstaluj czcionki z dystrybucji MeXa dostepne\MessageBreak
na ftp://ftp.gust.org.pl, sprobuj uzyc czcionek EC\MessageBreak
dodajac opcje T1 do wywolania pakietu polski'ego\MessageBreak
lub w ostatecznosci uzyj pakietu ot1patch.}{}}%
                \fi
            \egroup
            \let\@PL@OT@check=\undefined}%
        \AtBeginDocument{\@PL@OT@check}%
    }{%
    \let\PL@ncodingd@fined=\undefined
    }%
\fi
\@ifundefined{PLn@m@thsn@mes}{
  \PL@redef@funcnames
  \@ifundefined{PLm@ths}{}{\PL@redef@relations}
  }{}
\if 0\PL@prefixinginverb
  \expandafter\def\expandafter\dospecials\expandafter{\dospecials\do\/}
\fi
\let\PLn@m@thn@mes=\undefined
\let\PLm@ths=\undefined
\let\PL@setmaths=\undefined
\let\PL@redef@relations=\undefined
\let\PL@redef@funcnames=\undefined
\let\PL@prefixinginverb=\undefined
\endinput
%%
%% End of file `polski.sty'.