chapter gray box
[librarian.git] / librarian / pdf / fnprep.cls
1 % -*- coding: utf-8 -*-
2 \NeedsTeXFormat{LaTeX2e}
3 \ProvidesClass{fnprep}[2011/11/28 Modern Poland Foundation Report style]
4
5
6 %\RequirePackage{geometry}
7 \RequirePackage{setspace}
8 \RequirePackage{type1cm}
9 \RequirePackage{amssymb}
10 \RequirePackage{amsmath}
11 \RequirePackage{paralist}
12 \RequirePackage[normalem]{ulem}
13 \RequirePackage{xifthen}
14 \RequirePackage{environ} % environments with \BODY, for wyimek
15
16
17 \DeclareOption*{\PassOptionsToClass{\CurrentOption}{report}}
18 \ProcessOptions\relax
19 \LoadClass{report}
20 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
21
22 \usepackage{multicol}
23 \usepackage[explicit]{titlesec}
24 \usepackage{titletoc}
25 \usepackage{fancyhdr}
26 \usepackage[MeX]{polski}
27
28 \usepackage{trace}
29 \usepackage{caption}
30 \usepackage{tabularx}
31 \usepackage{icomma}
32 \usepackage[xetex]{graphicx}
33 \usepackage[silent]{fontspec} % silent - no warnings, quiet - warn only to log
34 \usepackage{xunicode}
35 \usepackage{xltxtra}
36 %\usepackage{trimspaces} % imported by something else?
37 \usepackage{xcolor}
38 \usepackage[overload]{textcase}
39 \usepackage{scalefnt}
40 \usepackage[colorlinks=false,linkcolor=white,pdfborder={0,0,0},setpagesize=false,urlcolor=black,xetex,linktocpage]{hyperref}
41 %\usepackage{hyperref}
42 \usepackage{endnotes}
43 \let\footnote=\endnote
44 \newcommand{\printfootnotes}{%
45   \markboth{\MakeTextUppercase{Przypisy}}{}
46   \renewcommand{\enoteheading}{}
47   \begingroup
48   \cleardoublepage
49   \parindent 0pt
50   \parskip 2ex
51   \def\enotesize{\normalsize}
52   \theendnotes
53   \endgroup
54 }
55
56 %\usepackage{fnpos}
57 \usepackage{printlen}
58 \usepackage{calc}
59 \usepackage[stable]{footmisc}
60
61 %http://tex.stackexchange.com/questions/40510/set-first-paragraph-no-indentation-after-re-definition-of-section#40512
62
63 \usepackage{chngcntr}
64 \counterwithout{footnote}{chapter}
65 \usepackage{microtype}
66
67
68 %%% Hyphenation opts:
69 %\pretolerance=10000
70 \tolerance=2600
71 \emergencystretch=30pt
72
73
74
75
76 %%%%%%%%%%%%%%%%%%%%%%% Paper size
77
78 \usepackage[%
79   paperwidth=297mm,%
80   paperheight=210mm,%
81   top=\dimexpr22.578mm+28pt\relax,%
82   left=15mm,%
83   right=20mm,%
84   bottom=24.439mm,%
85   headsep=47pt,% 2x grid(14) - 9 (text font size) + 28pt
86 ]{geometry}%
87 \setlength\columnsep{10mm}
88 \newlength\szpaltawidth
89 \setlength\szpaltawidth{80mm}
90
91 %%%%%%%%%%%%%%%%%%%%%%%% Fonts
92
93 \setmainfont[
94 ItalicFont = Lato-Italic,
95 BoldFont = Lato-Bold,
96 BoldItalicFont = Lato-BoldItalic,
97 Ligatures={Common, Contextual},
98 SmallCapsFont = Lato-Regular,
99 SmallCapsFeatures={Letters=SmallCaps},
100 Mapping=tex-text
101 ]{Lato-Regular}
102 \newfontface\latoblack{Lato-Black}
103 \newfontface\headfont{LeagueGothic-Regular}
104 %% Lato Light 
105
106 \setlength{\parindent}{3mm}
107 \setlength{\parskip}{0mm}
108
109 % \normalsize – normalny tekst 
110 % \large - normalny tekst headingowy (nie wiem czy jest inny niz normalsize?)
111 % \Large - troche większy tekst headingowy (spis treści)
112 % \huge - pagina tytuł rozdziału
113 % \Huge - naglowek na szarym tle
114
115 % grid 14, normal 9/12, 
116 % sródtytuły leage 10/8 14
117 % XXXX pagina: (mała? nie uzywana!)league 8, kerning 60 -› (30, 90), przy nowoczesna polska 100
118 % pagina: 28pt od top: 10mm  CMY 0 75 100
119 % kolumna-›teskt base 2xgrid
120 % tabela header 14pt, LEAGE GOT RE [pad: left:3mm, 1,41mm od góry 
121 % tabela  rynna 5mm
122 % tabela kreska 0.7pt pomarancz, potem 0.5pt też pomarańcz
123 % tabela tekst: 8.5/11pt lato regular (wtedy pomaranczem wyróżnienia)
124 % kern 5
125 % (bez gridu) (abo 8.5/11pt reglar) , poza interlinią 1mm odpycha enter
126
127 % footer: --||-- 
128 % footer LATO BLACK 15 -- pagina(strona) TYLKO Z PRAWEJ
129 % footer srodek. league gothic  10  k70 
130 % toc:wstep leag gothic 38  kern 75
131 % toc: 11pkt na grid 7 
132 % marginesy: top: 22.578 mm bottom 24.439mm rynna 10; out 20mm, ins
133 % 15mm
134 % sród->text base 2xgrid
135 % toc: wstep->text 3xgrid,
136 % toc: left: 25mm  right: 25mm
137 % toc długość tytułu (łamanie) 10m od końca 
138 % toc: od numeru enspace (indent)
139 % footer 2xgrid od dołu 9.7mm
140 % master toc: margin left: -width - 10 / 2 ; 136mm [3x łam]
141 % footnotes SOURCE SANS PRO 8/11pt semibold na gridzie (ale nie musi) spacing
142 % 100 
143 % master toc: 11pt/21pt leage na pół-grid (jak ejst mniejsze
144 % --licencja to 10pt!)
145 % master toc head 15pt, 
146 % master toc wpisy: 11pt - (można 11pt + black)
147 % TYtUL leag gothi  46pt
148
149 % sponsorzy np 9pt
150 \newcommand{\headingbig}{\fontsize{28}{28}\selectfont}
151 \renewcommand{\Huge}{\fontsize{38}{42}\selectfont}
152 \renewcommand{\huge}{\fontsize{15}{21}\selectfont}
153 \renewcommand{\LARGE}{\fontsize{14}{14}\selectfont}
154 \renewcommand{\large}{\fontsize{10}{14}\selectfont} % 21
155 \renewcommand{\Large}{\fontsize{11}{14}\selectfont}
156 \newcommand{\TOCtext}{\fontsize{11}{21}\selectfont}
157 \renewcommand{\normalsize}{\fontsize{9}{14}\selectfont}
158 \renewcommand{\footnotesize}{\fontsize{8}{10.5}\selectfont} % 
159 \renewcommand{\scriptsize}{\fontsize{8.5}{11}\selectfont}
160 \newcommand{\titlesize}{\fontsize{46}{46}\selectfont}
161 \newcommand{\footerbig}{\fontsize{15}{15}\selectfont}
162 \newcommand{\footernormal}{\fontsize{10}{10}\selectfont}
163
164
165 %% \renewcommand{\normalsize}{\fontsize{10.4}{14.28}\addfontfeature{LetterSpace=3.0}\selectfont}
166 %% \renewcommand{\large}{\fontsize{14}{14.28}\addfontfeature{LetterSpace=3.0,Letters=Uppercase}\selectfont} % srodtytul
167 %% \renewcommand{\small}{\fontsize{8}{14.28}\addfontfeature{LetterSpace=5.0}\selectfont} % paginy
168 %% \renewcommand{\Large}{\fontsize{15}{21.42}\addfontfeature{LetterSpace=0.0}\selectfont} % tytuł rozdziału
169 %% \renewcommand{\huge}{\fontsize{18}{28.56}\addfontfeature{LetterSpace=1.0}\selectfont} % wyimek
170 %% \renewcommand{\Huge}{\fontsize{24}{40}\selectfont} % cover
171 %% \renewcommand{\footnotesize}{\addfontfeature{LetterSpace=1.0}\fontsize{9}{10.74}\selectfont}
172
173
174
175 % • • • • • • • • • COLORS • •
176 \definecolor{stoK}{cmyk}{0,0,0,1}
177 \definecolor{theme}{gray}{.3}
178 \definecolor{headcolor}{HTML}{EA5F21}
179 \definecolor{graybg}{cmyk}{0,0,0,0.55}
180 %\color{stoK}
181
182 % • • • • • • • • METADATA • •
183
184 \makeatletter
185 \newcommand{\@address}{}
186 \newcommand{\address}[1]{\renewcommand{\@address}{#1}}
187 \makeatother
188
189 % • • • • • • • • HEADINGS • •
190 %% this will go to \leftmark
191
192 \makeatletter
193 \pagestyle{fancy}
194 \fancyhf{}
195 \renewcommand{\chaptermark}[1]{\markboth{\MakeTextUppercase{#1}}{}}
196 % on the odd right : chapter title
197 \fancyhead[LE,RO]{{\color{headcolor}\headfont\headingbig\leftmark}}
198 \fancyfoot[RO]{{\color{gray}\latoblack\footerbig\thepage}}
199 \fancyfoot[RE]{{\color{gray}\headfont\footernormal\MakeTextUppercase{\@title}}}
200 \fancyfoot[LO]{{\color{gray}\headfont\footernormal\MakeTextUppercase{\@address}}}
201
202 \renewcommand{\headrulewidth}{0pt}
203 \renewcommand{\footrulewidth}{0pt}
204 \makeatother
205
206 %%%%%%%%%% Nagłówek pierwszej strony rozdziału
207 \makeatletter
208 \fancypagestyle{plain}{%
209 \fancyhf{}
210 \fancyfoot[RO]{{\color{gray}\latoblack\footerbig\thepage}}
211 \fancyfoot[LO]{{\color{gray}\headfont\footernormal\MakeTextUppercase{\@address}}}
212 }
213 \makeatother
214
215 % • • • • • • • • TITLES • • •
216 % no chapter numbers and no ``Rozdział'' word
217 %\renewcommand{\thechapter}{}
218 %\renewcommand{\chaptername}{}
219
220 % • chapter • • • • • • • • • •
221
222
223 %% \newsavebox{\chaptitlebox}
224 %% \newenvironment{chaptertitlebox}%
225 %% {\begin{lrbox}{\chaptitlebox}\begin{minipage}{\dimexpr\linewidth-0.5\columnsep\relax}}%
226 %% {\vfill\end{minipage}\end{lrbox}%
227 %% \vspace{-5mm}\colorbox{graybg}{\usebox{\chaptitlebox}}%
228 %% } 
229
230 %% \begin{lrbox}{\@tempboxa}\begin{minipage}[t][\dimexpr\textheight-0.5cm\relax]{\dimexpr\linewidth-0.5\columnsep\relax}}{\end{minipage}\end{lrbox}%
231 %%    \colorbox{graybg}{\raisebox{1cm}{\usebox{\@tempboxa}}}
232 %% }
233
234 \makeatletter
235 \newcommand{\nochapternumbers}{
236   \renewcommand{\thesection}{\@arabic \c@section .}
237 }
238 \makeatother
239
240 \nochapternumbers
241 \startcontents[chapter]
242
243 \newcommand{\chapterblock}[1]{%
244 \clearpage%
245 \addcontentsline{toc}{chapter}{#1}%
246 \setlength{\fboxsep}{0pt}%
247 \noindent\colorbox{graybg}{%
248 \rule{0pt}{28pt}%
249 \hspace{2.5mm}%
250 \begin{minipage}[t][\dimexpr\textheight-28pt\relax]{\dimexpr\szpaltawidth-5mm\relax}%
251 \Huge{}\headfont\color{white}#1%
252 \vspace{\dimexpr21mm-11mm\relax}%
253 \par{\printcontents[chapter]{}{1}{}}
254 \end{minipage}%(testing)%\rule{0.1pt}{\baselineskip}%
255 \hspace{2.5mm}}%
256 \vspace{\dimexpr-\parskip-11pt\relax}%
257 }
258
259 \titlespacing*{\chapter}{0pt}{0pt}{0pt}
260
261 % • section • • • • • • • • • • • • • • • 
262 \titleformat{\section}[runin]%
263 {\large\headfont%\nochapternumbers
264 }%
265 {}{0pt}{\makebox[\linewidth][l]{\color{headcolor}\raggedright{}\thesection\enskip #1}%
266 % this is just to make the spacing between section and following
267 % text right (newlines produce strange amount of space
268 \makebox[\linewidth][l]{~}}%
269
270 \titlecontents{section}[0pt]{\headfont\Large\color{white}}%
271 {\thecontentslabel\enspace}{\contentsmargin{0pt}}%
272 {\hfill\color{white}{\thecontentspage}}
273
274
275 % \fboxsep=0pt % for framebox
276 % ramki wkokół elementów \fbox{}
277 %\titlespacing*{\section}{0pt}{0pt}{2\baselineskip}
278
279
280 %% \titleformat{\chapter}[block]%
281 %% {\Large\intro\addfontfeature{LetterSpace=0.5,Kerning={Uppercase}}}%
282 %% {}{0pt}{\parbox{80mm}{\raggedright#1}}
283 %% \newlength{\chapterposcorrection}\newlength{\chapterspaceafter}
284 %% \setlength{\chapterposcorrection}{-\headsep-2\baselineskip-2.352mm} % 2.352 is a measured correction:
285 %% \setlength{\chapterspaceafter}{14\baselineskip-14pt+2.352mm}%\f@size of large
286 %% \titlespacing*{\chapter}{0pt}{\chapterposcorrection}{\chapterspaceafter}
287
288 %% %% Sections
289 %% \titleformat{\section}%
290 %% {\addfontfeature{LetterSpace=0.3}\large}%
291 %% {\thesection{}.}{.5em}{\MakeTextUppercase{#1}}
292 %% \renewcommand{\thesection}{\Roman{section}}
293 %% \titlespacing*{\section}{0pt}{\baselineskip}{0em}
294
295 %% \titleformat{\subsection}[block]%
296 %% {}%
297 %% {\thesubsection{}.}{.5em}{\MakeTextUppercase{#1}.}[]
298
299 %% \renewcommand{\thesubsection}{\Alph{subsection}}
300 %% \titlespacing*{\subsection}{0pt}{\baselineskip}{0em}
301
302 %% \newcommand{\typosubsubsection}[1]{%
303 %% {\textsc{#1}}
304 %% }
305
306
307 %%%%% Footnotes (works with footmisc) %%%%%%%%
308 \newlength{\footnoteindent}\newlength{\footnoteprespace}
309 \setlength{\footnoteindent}{8mm}%{3.5mm}
310 \setlength{\footnoteprespace}{0em}
311 \makeatletter
312
313 \renewcommand\@makefnmark{%
314 \hspace{\footnoteprespace}
315 \hbox{{\normalfont \@thefnmark}}%
316 }
317 \renewcommand\thefootnote{[\arabic{footnote}]}
318
319 \setlength{\footnotemargin}{-\footnoteindent-\footnoteprespace-.3em}
320 \renewcommand\footnotelayout[1]{%
321   \setlength{\leftskip}{\footnoteindent}#1}
322
323 %% \long\def\@makefntext#1{%
324 %% \setlength{\leftskip}{\footnoteindent}%
325 %% \setlength{\hskip}{-\footnoteindent-\footnoteprespace-.1em}%
326 %% \hb@xt@ \dimexpr\footnoteindent+\footnoteprespace%
327 %% {\@makefnmark}#1
328 %% %  \parindent 1em\noindent \hb@xt@ 1.8em{\hss \@makefnmark \enskip}#1
329 %% }
330
331 %%%%% Endnotes
332 \newlength{\myendnoteprespace}\setlength{\myendnoteprespace}{.5em}
333 \newlength{\myendnoteindent}\setlength{\myendnoteindent}{14mm+.5em}
334
335 \renewcommand\theendnote{[\roman{endnote}]}
336 \renewcommand\makeenmark{\hspace{\myendnoteprespace}\theenmark}
337 \renewcommand{\notesname}{}
338 \newcommand{\authornotes}{
339 %  \newpage
340     \cleardoublepage
341     \chapter{Przypisy autora}
342     \setlength{\parindent}{0pt}
343     \def\enotesize{\normalsize}
344     \theendnotes
345 }
346 %% \newcommand{\@makeentext}[1]{%
347 %% \noindent\theenmark\hspace{\footnoteindent}#1
348 %% }
349
350 %% \def\enoteformat{\rightskip\z@ \parindent=0em
351 %%  \makebox[\myendnoteindent][l]{\makeenmark}} % 12.4mm - measured biggest endnote marker (in Moglen text [xxxviii])
352 \def\enoteformat{\rightskip\z@ \setlength{\leftskip}{\myendnoteindent-\myendnoteprespace} \parindent=0em
353   \leavevmode\llap{\makebox[\myendnoteindent][l]{\makeenmark}}}
354
355
356 % make public
357 \def\trimspace#1{\trim@spaces{#1}}
358
359 \makeatother
360
361 %%%%%%%%%%%%%%%%%%%%%% Wyimki
362 %% \floatstyle{plain}
363 %% \newfloat{wyimekbox}{p}{wmk}
364 %% \floatname{wyimekbox}{Wyimek}
365
366 \NewEnviron{wyimek}{%
367   \checkoddpage
368   \ifoddpage
369     \PackageWarning{wlpub}{Wyimek on odd page, omitting it ( \BODY )}
370   \else
371     \begin{figure}[tp]
372       \begin{center}
373         \begin{minipage}[t][\textheight][c]{70mm}
374           \huge\it\BODY
375         \end{minipage}
376       \end{center}
377     \end{figure}
378   \fi
379   \BODY
380 }
381
382 %% wyimek that doesn't leave text in text flow
383 %% TODO: reduce code duplication
384 \NewEnviron{wyimekextra}{%
385   \checkoddpage
386   \ifoddpage
387     \PackageWarning{wlpub}{Wyimek on odd page, omitting it ( \BODY )}
388   \else
389     \begin{figure}[tp]
390       \begin{center}
391         \begin{minipage}[t][\textheight][c]{70mm}
392           \huge\it\BODY
393         \end{minipage}
394       \end{center}
395     \end{figure}
396   \fi
397 }
398
399
400
401
402 %%%%%%%%%%%%%%%%%%%%%%%%%%
403
404
405 \clubpenalty=700
406 \widowpenalty=700
407 \hyphenpenalty=3500
408 \doublehyphendemerits=9000
409 \finalhyphendemerits=6000
410
411
412 % see http://osdir.com/ml/tex.xetex/2005-10/msg00003.html
413 \newsavebox{\ximagebox}\newlength{\ximageheight}
414 \newsavebox{\xglyphbox}\newlength{\xglyphheight}
415 \newcommand{\xbox}[1]
416 {\savebox{\ximagebox}{#1}\settoheight{\ximageheight}{\usebox {\ximapgebox}}%
417 \savebox{\xglyphbox}{\char32}\settoheight{\xglyphheight}{\usebox {\xglyphbox}}%
418 \raisebox{\ximageheight}[0pt][0pt]{%\raisebox{-\xglyphheight}[0pt] [0pt]{%
419 \makebox[0pt][l]{\usebox{\xglyphbox}}}%}%
420 \usebox{\ximagebox}%
421 \raisebox{0pt}[0pt][0pt]{\makebox[0pt][r]{\usebox{\xglyphbox}}}}
422
423
424 \newcommand{\makecover}{
425   %% \paperwidth=297mm
426
427
428   %% \paperheight=210mm
429
430   \newgeometry{paperwidth=297mm,paperheight=210mm}
431   \pdfpageheight=210mm
432   \pdfpagewidth=297mm
433
434   \thispagestyle{empty}
435   \newlength{\PictHOffset}
436   \newlength{\PictVOffset}
437   \setlength{\PictHOffset}{1in}
438   \addtolength{\PictHOffset}{\hoffset}
439   \addtolength{\PictHOffset}{\oddsidemargin}
440
441   \setlength{\PictVOffset}{1in}
442   \addtolength{\PictVOffset}{\voffset}
443   \addtolength{\PictVOffset}{\topmargin}
444   \addtolength{\PictVOffset}{\headheight}
445   \addtolength{\PictVOffset}{\headsep}
446   \addtolength{\PictVOffset}{\topskip}
447
448   \addtolength{\PictVOffset}{-\paperheight}
449
450   \noindent\hspace*{-\PictHOffset}%
451   \raisebox{\PictVOffset}[0pt][0pt]{\makebox[0pt][l]{%
452       \includegraphics[height=\pdfpageheight,width=\pdfpagewidth]{cover.pdf}}}
453
454   \restoregeometry
455   \pdfpageheight=210mm
456   \pdfpagewidth=148mm
457
458   }
459
460 \renewcommand{\maketitle}{
461   %\vspace{\paperheight}
462   \thispagestyle{empty}
463   \cleardoublepage
464   \setcounter{page}{1}
465   \thispagestyle{empty}
466   \begin{center}
467   \intro
468   {
469     \begin{spacing}{1.4}
470     \Huge \noindent \thetitle
471     \end{spacing}
472   }
473   \end{center}
474
475   \vspace{\baselineskip}
476
477   \begin{center}
478     \intro
479     {
480       \huge \noindent
481       \theauthor
482
483     }
484   \end{center}
485                   %\emph{\thankyou}\\
486                   %\indent\emph{You made this book possible.}
487   \vspace{7\baselineskip}
488
489   \begin{center}
490     \includegraphics[scale=.2]{logo.eps}
491   \end{center}
492
493 }
494
495
496 \newcommand{\editorialsection}{
497   \clearpage
498   \thispagestyle{empty}
499   {
500     \setlength{\parindent}{0mm}
501     \small
502   \input{editorial}
503   }
504 }
505
506 \renewcommand*\contentsname{Spis treści}
507 \newcommand{\spistresci}{
508 {
509   \intro
510   \setcounter{tocdepth}{0}
511   \tableofcontents
512   \newpage
513 }
514 }
515
516
517
518
519 \newcommand{\tytul}[1]{%
520 #1%
521 \vspace{1em}%
522 }
523
524 \newcommand{\nazwapodutworu}[1]{%
525 \section*{#1}%
526 }
527
528 \newcommand{\autorutworu}[1]{%
529 #1
530 %\subsection*{\typosubsection{#1}}%
531 }
532
533 \newcommand{\dzielonadrzedne}[1]{%
534 \subsection*{#1}%
535 }
536
537 \newcommand{\nazwautworu}[1]{%
538 \section*{#1}%
539 }
540
541 \newcommand{\podtytul}[1]{%
542 \subsection*{\typosubsubsection{#1}}%
543 }
544
545 \newcommand{\podtytulpodutworu}[1]{%
546 \subsection*{\typosubsubsection{#1}}%
547 }
548
549 \newcommand{\translator}[1]{%
550 \subsection*{\typosubsubsection{tłum. #1}}%
551 }
552 \newcommand{\translatorsline}[1]{%
553 #1
554 }
555
556 \newcommand{\powiesc}[1]{#1}
557 \newcommand{\opowiadanie}[1]{#1}
558 \newcommand{\lirykal}[1]{#1}
559 \newcommand{\lirykalp}[1]{#1}
560 \newcommand{\dramatwierszowanyl}[1]{#1}
561 \newcommand{\dramatwierszowanylp}[1]{#1}
562 \newcommand{\dramatwspolczesny}[1]{#1}
563
564
565 \newcommand{\dedykacja}[1]{%
566 \begin{em}%
567 \begin{flushright}%
568 #1%
569 \end{flushright}%
570 \end{em}%
571 }
572
573 \newcommand{\dlugicytat}[1]{%
574 \begin{quotation}%
575 \noindent{}\ignorespaces#1%
576 \end{quotation}%
577 \hspace{\parindent}
578 }
579
580 \newcommand{\poezjacyt}[1]{%
581 \begin{verse}%
582 #1%
583 \end{verse}%
584 }
585 \newcommand{\motto}[1]{%
586 \begin{em}%
587 #1%
588 \end{em}%
589 }
590 \newcommand{\listaosob}[2]{%
591 \par{#1}%
592 \begin{itemize}%
593 #2%
594 \end{itemize}%
595 }
596
597 \newcommand{\nagloweklisty}[1]{%
598 \typosubsubsection{#1}%
599 }
600
601 \newcommand{\listaosoba}[1]{%
602 \item{#1}%
603 }
604
605 \newcommand{\kwestia}[1]{%
606 \par{#1}%
607 }
608
609 \newcommand{\naglowekakt}[1]{%
610 \pagebreak
611 \subsection*{\typosubsection{#1}}%
612 }
613 \newcommand{\naglowekczesc}[1]{%
614 \pagebreak
615 \part{#1}%
616 }
617 \newcommand{\srodtytul}[1]{%
618 \subsection{#1}%
619 }
620
621 \newcommand{\naglowekscena}[1]{%
622 \subsubsection*{\typosubsubsection{#1}}%
623 }
624
625 \newcommand{\theautorrozdzialu}{}
626
627 \newcommand{\autorrozdzialu}[1]{%
628 \renewcommand{\theautorrozdzialu}{{\normalfont\normalsize\newline{}\newline{}\parbox{\textwidth}{\normalsize\it #1}}}
629 }
630
631
632 \newcommand{\naglowekrozdzial}[1]{%
633 \startcontents[chapter]
634 \markboth{#1}{}
635 %
636 \chapterblock{#1}
637 }
638
639 \newcommand{\naglowekosoba}[1]{%
640 \par{\textsc{#1}}\nopagebreak%
641 }
642 \newcommand{\naglowekpodrozdzial}[1]{%
643 \section{#1}\nopagebreak%
644 }
645 \newcommand{\miejsceczas}[1]{%
646 \par{\emph{#1}}%
647 }
648 \newcommand{\didaskalia}[1]{%
649 \par{\emph{#1}}%
650 }
651
652 \newcommand{\akap}[1]{%
653 #1
654
655 % newline here needed, we don't use \par cause it ignores \noindent before
656 }
657 \newcommand{\akapdialog}[1]{%
658 \par{#1}%
659 }
660 \newcommand{\akapcd}[1]{%
661 \par{#1}%
662 }
663
664 \newcommand{\mottopodpis}[1]{%
665 \begin{em}%
666 \begin{flushright}%
667 #1%
668 \end{flushright}%
669 \end{em}%
670 }
671
672 \newcommand{\strofa}[1]{%
673 #1\vspace{\baselineskip}%
674 }
675
676 \newcommand{\wers}[1]{#1}
677
678 \newcommand{\wersakap}[1]{%
679 \hspace*{1em}#1%
680 }
681 \newcommand{\werscd}[1]{%
682 \hspace*{8em}#1%
683 }
684 \newcommand{\werswciety}[2][1em]{%
685 \hspace*{#1}#2%
686 }
687
688
689 \newcommand{\mat}[1]{$#1$}
690
691 \newcommand{\didasktekst}[1]{%
692 \emph{#1}%
693 }
694 \newcommand{\slowoobce}[1]{%
695 \emph{#1}%
696 }
697 \makeatletter
698
699 \newif\ifinnota \innotafalse
700
701 \newcommand{\tytuldziela}[1]{%
702   \ifinnota
703    #1%
704   \else
705    \emph{#1}%
706   \fi
707 }
708 \makeatother
709
710 \newcommand{\wyroznienie}[1]{%
711 \emph{#1}%
712 }
713
714 \newcommand{\nota}[1]{%
715 %\sekcjaasterysk{}
716 \begin{em}%
717   \innotatrue
718 %\begin{flushleft}%
719   \noindent{}\small{}#1%
720   \innotafalse
721 %\end{flushleft}%
722 \end{em}%
723 }
724
725
726 \newcommand{\osoba}[1]{%
727 #1%
728 }
729
730 \newcommand{\sekcjaswiatlo}{%
731 \vspace{\baselineskip}%
732 }
733
734 \newcommand{\sekcjaasterysk}{%
735 \vspace{\baselineskip}%
736 \begin{center}%
737 \par{*}%
738 \end{center}%
739 }
740
741 \newcommand{\separatorlinia}{%
742 \vspace{10pt}%
743 \hrule{}%
744 \vspace{10pt}%
745 }
746
747 \newcommand{\ilustrscale}[0]{1}
748 \newcommand{\setilustrscale}[1]{\renewcomand{\ilustrscale}{#1}}
749
750 \newcommand{\ilustr}[3][]{
751   \begin{center}%
752     \ifthenelse{\isempty{#1}}%
753     {\par{\includegraphics{\trimspace{#2}}\\#3}}%
754     {\par{\includegraphics[#1]{\trimspace{#2}}\\#3}}%
755   \end{center}%
756 }
757
758
759 \newcommand{\lista}[1]{%
760 \begin{compactenum}
761 %\setlength{\parskip}{\parindent}
762 #1
763 \end{compactenum}
764 }
765
766 \newcommand{\punkt}[1]{%
767 \item #1
768 }
769 \newcommand{\link}[2]{\href{#1}{\uline{#2}\footnote{#1}}}
770
771 \newcommand{\www}[1]{{\normalfont\href{#1}{#1}}}