mirror of
https://github.com/flynx/photobook.git
synced 2025-10-29 02:10:08 +00:00
foldout calculation not seems to be correct + cleanup...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
parent
d2f54ee42a
commit
5649c678db
@ -2978,38 +2978,40 @@
|
|||||||
\edef\photobook@foldout@prevfold{in}
|
\edef\photobook@foldout@prevfold{in}
|
||||||
|
|
||||||
% >> \photobook@foldout@pushpanel{<width>}{<fold>}
|
% >> \photobook@foldout@pushpanel{<width>}{<fold>}
|
||||||
% XXX setup numbers in auto-width mode...
|
% XXX might be good to warn the user if the manual fold will not work...
|
||||||
% panel 1 -> maxpanelwidth
|
% after two folds in same direction panels must be strictly smaller...
|
||||||
% panel 2 -> maxpanelwidth - clearfoldoutbinding
|
% ...would be nice to maintain maxpanelwidth and warn if explicit
|
||||||
% ...use \foldoutcellwidthslen to
|
% width is larger...
|
||||||
\newcommand\photobook@foldout@pushpanel[2]{%
|
\newcommand\photobook@foldout@pushpanel[2]{%
|
||||||
% initial max panel size...
|
% initial max panel size...
|
||||||
\ifnum \thephotobook@foldoutpanel = 1%
|
\ifnum \thephotobook@foldoutpanel = 1%
|
||||||
\setlength\photobook@foldout@maxpanelwidth{%
|
\setlength\photobook@foldout@maxpanelwidth{%
|
||||||
\blockwidth
|
\blockwidth
|
||||||
- \clearfoldoutedge}\fi%
|
- \clearfoldoutedge}\fi%
|
||||||
|
% panel #2 -- clear binding...
|
||||||
\ifnum \thephotobook@foldoutpanel = 2%
|
\ifnum \thephotobook@foldoutpanel = 2%
|
||||||
% XXX
|
\setlength\photobook@foldout@maxpanelwidth{%
|
||||||
\fi%
|
\photobook@foldout@maxpanelwidth
|
||||||
|
- \clearfoldoutbinding}\fi%
|
||||||
% calculate widths...
|
% calculate widths...
|
||||||
\ifdim #1 = 0pt%
|
\ifdim #1 = 0pt%
|
||||||
|
% first two panels do not need fold compensation...
|
||||||
\ifnum \thephotobook@foldoutpanel < 3%
|
\ifnum \thephotobook@foldoutpanel < 3%
|
||||||
% XXX
|
|
||||||
\else%
|
|
||||||
% XXX
|
|
||||||
\fi%
|
|
||||||
% double fold twice in same direction...
|
|
||||||
% XXX this should not be done for panel 1 and 2...
|
|
||||||
\ifthenelse{\equal{#2}{\photobook@foldout@prevfold}}{%
|
|
||||||
\setlength\photobook@foldout@panelwidth{%
|
|
||||||
\photobook@foldout@maxpanelwidth
|
|
||||||
+ \paperfoldwidth
|
|
||||||
- \clearfoldoutfold}%
|
|
||||||
% different fold directions -- no resizing needed here...
|
|
||||||
}{%
|
|
||||||
\setlength\photobook@foldout@panelwidth{%
|
\setlength\photobook@foldout@panelwidth{%
|
||||||
\photobook@foldout@maxpanelwidth
|
\photobook@foldout@maxpanelwidth
|
||||||
+ \paperfoldwidth}}%
|
+ \paperfoldwidth}%
|
||||||
|
\else%
|
||||||
|
% double fold twice in same direction...
|
||||||
|
\ifthenelse{\equal{#2}{\photobook@foldout@prevfold}}{%
|
||||||
|
\setlength\photobook@foldout@panelwidth{%
|
||||||
|
\photobook@foldout@maxpanelwidth
|
||||||
|
+ \paperfoldwidth
|
||||||
|
- \clearfoldoutfold}%
|
||||||
|
% different fold directions -- no resizing needed here...
|
||||||
|
}{%
|
||||||
|
\setlength\photobook@foldout@panelwidth{%
|
||||||
|
\photobook@foldout@maxpanelwidth
|
||||||
|
+ \paperfoldwidth}}\fi%
|
||||||
\setlength\photobook@foldout@maxpanelwidth{%
|
\setlength\photobook@foldout@maxpanelwidth{%
|
||||||
\photobook@foldout@panelwidth}%
|
\photobook@foldout@panelwidth}%
|
||||||
% explicit width...
|
% explicit width...
|
||||||
@ -3026,7 +3028,6 @@
|
|||||||
\foldoutcellwidths,\the\photobook@foldout@panelwidth}%
|
\foldoutcellwidths,\the\photobook@foldout@panelwidth}%
|
||||||
\stepcounter{photobook@foldoutpanel}}
|
\stepcounter{photobook@foldoutpanel}}
|
||||||
|
|
||||||
% XXX FOLDMARK...
|
|
||||||
% XXX also add this to jacket/cover...
|
% XXX also add this to jacket/cover...
|
||||||
\newlength\photobook@showmarks@offset
|
\newlength\photobook@showmarks@offset
|
||||||
\setlength\photobook@showmarks@offset{0pt}
|
\setlength\photobook@showmarks@offset{0pt}
|
||||||
@ -3180,15 +3181,16 @@
|
|||||||
|
|
||||||
% XXX BUG: even (left) page panel sizes are in the same order as odd
|
% XXX BUG: even (left) page panel sizes are in the same order as odd
|
||||||
% page -- should be reversed...
|
% page -- should be reversed...
|
||||||
|
% ...use same strategy as for foldmarks...
|
||||||
% XXX revise naming....
|
% XXX revise naming....
|
||||||
% foldoutcell - 1:1 (unclipped)
|
% foldoutcell - 1:1 (unclipped)
|
||||||
% should be clipped to bleeds, i.e. should use
|
% should be clipped to bleeds, i.e. should use
|
||||||
% foldoutcell* and create a new offset cell inside...
|
% foldoutcell* and create a new offset cell inside...
|
||||||
% foldoutcell* - with bleeds like cell* (unclipped)...
|
% foldoutcell* - with bleeds like cell* (unclipped)...
|
||||||
% XXX need to be able to turn clipping on/off (???)
|
% XXX need to be able to turn clipping on/off (???)
|
||||||
|
% XXX should these clip by default???
|
||||||
% XXX doc [from, to]
|
% XXX doc [from, to]
|
||||||
% XXX this can't be used outside of a foldout...
|
% XXX this can't be used outside of a foldout...
|
||||||
% XXX should these clip???
|
|
||||||
% XXX the following two envs are almost identical...
|
% XXX the following two envs are almost identical...
|
||||||
\newenvironment{foldoutcell}[1][0]{%
|
\newenvironment{foldoutcell}[1][0]{%
|
||||||
\begingroup%
|
\begingroup%
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user