X-Git-Url: https://git.mdrn.pl/librarian.git/blobdiff_plain/0f3e12398ddbbb07a71eeafb3f960631777cabdc..0b32c81b837233ea59fdd1b5f19edc935f7b626d:/librarian/pdf/wlpub.cls?ds=inline

diff --git a/librarian/pdf/wlpub.cls b/librarian/pdf/wlpub.cls
index f2d3b36..7ace19d 100644
--- a/librarian/pdf/wlpub.cls
+++ b/librarian/pdf/wlpub.cls
@@ -21,6 +21,7 @@
 \RequirePackage{paralist}
 \RequirePackage[normalem]{ulem}
 \RequirePackage{xifthen}
+\RequirePackage{environ} % environments with \BODY, for wyimek
 
 %\DeclareOption{13pt}{%
 %\AtEndOfClass{%
@@ -88,7 +89,7 @@
 \usepackage{fontspec}
 \usepackage{xunicode}
 \usepackage{xltxtra}
-\usepackage{trimspaces}
+%\usepackage{trimspaces} % imported by something else?
 \usepackage{color}
 \usepackage[overload]{textcase}
 \usepackage{scalefnt}
@@ -100,6 +101,11 @@
 \usepackage{calc}
 \usepackage[stable]{footmisc}
 
+%% Wyimki - placing them on correct pages
+\usepackage{changepage}
+%\usepackage{fltpage}
+\usepackage{float}
+
 \pagestyle{plain}
 % bottom figure below footnotes
 %\makeFNabove
@@ -162,7 +168,7 @@ Mapping=tex-text
 \renewcommand{\large}{\fontsize{14}{14.28}\addfontfeature{LetterSpace=0.3}\selectfont} % srodtytul
 \renewcommand{\small}{\fontsize{8}{14.28}\addfontfeature{LetterSpace=0.5}\selectfont} % paginy
 \renewcommand{\Large}{\fontsize{15}{21.42}\addfontfeature{LetterSpace=0.1}\selectfont} % tytuÅ rozdziaÅu
-\renewcommand{\huge}{\fontsize{18}{21.6}\addfontfeature{LetterSpace=0.1}\selectfont} % wyimek
+\renewcommand{\huge}{\fontsize{18}{28.56}\addfontfeature{LetterSpace=0.1}\selectfont} % wyimek
 \renewcommand{\Huge}{\fontsize{24}{40}\selectfont} % cover
 \renewcommand{\footnotesize}{\fontsize{9}{10.74}\selectfont}
 
@@ -257,10 +263,38 @@ Mapping=tex-text
 %% %  \parindent 1em\noindent \hb@xt@ 1.8em{\hss \@makefnmark \enskip}#1
 %% }
 
+% make public
 \def\trimspace#1{\trim@spaces{#1}}
 
 \makeatother
 
+%%%%%%%%%%%%%%%%%%%%%% Wyimki
+%% \floatstyle{plain}
+%% \newfloat{wyimekbox}{p}{wmk}
+%% \floatname{wyimekbox}{Wyimek}
+
+\NewEnviron{wyimek}{%
+  \checkoddpage
+  \ifoddpage
+    \PackageWarning{wlpub}{Wyimek on odd page, omitting it.}
+  \else
+    \begin{figure}[tp]
+      \begin{center}
+        \begin{minipage}[t][\textheight][c]{70mm}
+          \huge\it\BODY
+        \end{minipage}
+      \end{center}
+    \end{figure}
+  \fi
+  \BODY
+}
+
+
+
+
+
+%%%%%%%%%%%%%%%%%%%%%%%%%%
+
 
 \clubpenalty=100000
 \widowpenalty=100000
@@ -270,7 +304,7 @@ Mapping=tex-text
 \newsavebox{\ximagebox}\newlength{\ximageheight}
 \newsavebox{\xglyphbox}\newlength{\xglyphheight}
 \newcommand{\xbox}[1]
-{\savebox{\ximagebox}{#1}\settoheight{\ximageheight}{\usebox {\ximagebox}}%
+{\savebox{\ximagebox}{#1}\settoheight{\ximageheight}{\usebox {\ximapgebox}}%
 \savebox{\xglyphbox}{\char32}\settoheight{\xglyphheight}{\usebox {\xglyphbox}}%
 \raisebox{\ximageheight}[0pt][0pt]{%\raisebox{-\xglyphheight}[0pt] [0pt]{%
 \makebox[0pt][l]{\usebox{\xglyphbox}}}%}%
