mirror of
				https://github.com/flynx/photobook.git
				synced 2025-10-31 19:30:08 +00:00 
			
		
		
		
	experimenting with docs...
Signed-off-by: Alex A. Naanou <alex.nanou@gmail.com>
This commit is contained in:
		
							parent
							
								
									2e7faac8a8
								
							
						
					
					
						commit
						ff6b95a891
					
				
							
								
								
									
										53
									
								
								Makefile
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										53
									
								
								Makefile
									
									
									
									
									
										Normal file
									
								
							| @ -0,0 +1,53 @@ | |||||||
|  | #----------------------------------------------------------------------
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | TEX := lualatex | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | #----------------------------------------------------------------------
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %.pdf: %.tex | ||||||
|  | 	$(TEX) $< #> /dev/null | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | # Generate docs from latex package/class...
 | ||||||
|  | #
 | ||||||
|  | # 	- keep only lines starting with '%%'
 | ||||||
|  | # 	- %%%% Text -> \section(Text)
 | ||||||
|  | # 	- %%%%% Text -> \subsection(Text)
 | ||||||
|  | # 	- %% >> code -> \begin{verbatim}code\end{verbatim}
 | ||||||
|  | #
 | ||||||
|  | # NOTE: the idea of keeping latex docs in a latex file is far similar 
 | ||||||
|  | # 		than all the stuff crammed into .dtx, at least for my needs:
 | ||||||
|  | # 			- keep the code readable
 | ||||||
|  | # 			- keep the docs readable
 | ||||||
|  | # 		in both the repo and in installed form.
 | ||||||
|  | # NOTE: this is evolving as need arises, when this gets too complicated 
 | ||||||
|  | # 		we'll split it out into it's own script.
 | ||||||
|  | #
 | ||||||
|  | # XXX need to do this without repeating the recipe...
 | ||||||
|  | #%.tex: %.sty
 | ||||||
|  | %.tex: %.cls | ||||||
|  | 	cat $< \
 | ||||||
|  | 		| egrep "^%%" \
 | ||||||
|  | 		| sed 's/%%%%%% \(.*\)/%%\\\\subsubsection{\1}/' \
 | ||||||
|  | 		| sed 's/%%%%% \(.*\)/%%\\\\subsection{\1}/' \
 | ||||||
|  | 		| sed 's/%%%% \(.*\)/%%\\\\section{\1}/' \
 | ||||||
|  | 		| sed 's/%%\s\+>>\s\+\(.*\)/%%\\\\begin{verbatim} \1 \\\\end{verbatim}/' \
 | ||||||
|  | 		| cut -c 3- - > $@ | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | .PHONY: sweep | ||||||
|  | sweep: | ||||||
|  | 	rm -f *.{aux,fls,glo,gls,hd,idx,ilg,ind,ins,log,out} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | .PHONY: clean | ||||||
|  | clean: sweep | ||||||
|  | 	rm -f *.pdf | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | #----------------------------------------------------------------------
 | ||||||
|  | #                                                   vim:set ts=4 sw=4 :
 | ||||||
							
								
								
									
										718
									
								
								photobook.cls
									
									
									
									
									
								
							
							
						
						
									
										718
									
								
								photobook.cls
									
									
									
									
									
								
							| @ -13,17 +13,44 @@ | |||||||
| % | % | ||||||
| % XXX might be a good idea to add a spine calculator... | % XXX might be a good idea to add a spine calculator... | ||||||
| % | % | ||||||
|  | %---------------------------------------------------------------------- | ||||||
|  | % | ||||||
|  | %% \documentclass{ltxdoc} | ||||||
|  | %% | ||||||
|  | %% \usepackage[a4paper,margin=25mm,left=50mm,nohead]{geometry} | ||||||
|  | %% \usepackage[numbered]{hypdoc} | ||||||
|  | %%% \usepackage{verbatimbox} | ||||||
|  | %% | ||||||
|  | %% | ||||||
|  | %% \begin{document} | ||||||
|  | %% | ||||||
|  | %% \GetFileInfo{\jobname.cls} | ||||||
|  | %% | ||||||
|  | %% \title{\textsf{photobook} --- A new LaTeX class\thanks{This file | ||||||
|  | %% 		describes version \fileversion, last revised \filedate.}} | ||||||
|  | %% | ||||||
|  | %% \author{Alex A. Naanou\thanks{E-mail: alex.nanou@gmail.com}} | ||||||
|  | %% | ||||||
|  | %% \date{Released \filedate} | ||||||
|  | %% | ||||||
|  | %% \maketitle | ||||||
|  | %% | ||||||
|  | %%%% Usage | ||||||
|  | %% | ||||||
|  | %%	>> \documentclass[<options>]{photobook} | ||||||
|  | %% | ||||||
| % | % | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| 
 | 
 | ||||||
| \NeedsTeXFormat{LaTeX2e} | \NeedsTeXFormat{LaTeX2e} | ||||||
| 
 | 
 | ||||||
| % XXX set release date... | % XXX set release date... | ||||||
| \ProvidesClass{photobook}[2021/07/28 Photo book Latex class] | \ProvidesClass{photobook}[2021/07/28 v0.1 Photo book document class] | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||||
| % Class/package options... | %%%% Options | ||||||
|  | %% | ||||||
| 
 | 
 | ||||||
| \RequirePackage{kvoptions} | \RequirePackage{kvoptions} | ||||||
| 
 | 
 | ||||||
| @ -38,83 +65,106 @@ | |||||||
| 
 | 
 | ||||||
| % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||||
| 
 | 
 | ||||||
| % layout mode... | %%%%% layout | ||||||
| % |  | ||||||
| % - block (default): |  | ||||||
| % |  | ||||||
| %       blockwidth |  | ||||||
| %   <---------------> |  | ||||||
| % |  | ||||||
| %   +---------------+ |  | ||||||
| %   |               | |  | ||||||
| %   |               | |  | ||||||
| %   |               | |  | ||||||
| %   |               | |  | ||||||
| %   |               | |  | ||||||
| %   +---------------+ |  | ||||||
| % |  | ||||||
| % |  | ||||||
| % - endpaper: |  | ||||||
| % |  | ||||||
| %       blockwidth 2x |  | ||||||
| %   <-------------------------------> |  | ||||||
| % |  | ||||||
| %   +---------------+---------------+ |  | ||||||
| %   |               .               | |  | ||||||
| %   |               .               | |  | ||||||
| %   |               .               | |  | ||||||
| %   |               .               | |  | ||||||
| %   |               .               | |  | ||||||
| %   +---------------+---------------+ |  | ||||||
| %	 |  | ||||||
| % |  | ||||||
| % - cover: |  | ||||||
| % |  | ||||||
| %          blockwidth            blockwidth |  | ||||||
| %       <--------------->     <---------------> |  | ||||||
| %     <-> coverboardgrow                      <-> coverboardgrow |  | ||||||
| %   <-> coverflap                             . <-> coverflap |  | ||||||
| %   . . .                                     . . . |  | ||||||
| %   +-------------------++---++-------------------+    --- |  | ||||||
| %   | + - - - - - - - - ++ - ++ - - - - - - - - + |    --^ coverflap                 |  | ||||||
| %   | . + - - - - - - - ++ - ++ - - - - - - - + . |    --^ coverboardgrow   |  | ||||||
| %   | . .               ..   ..               . . |     ^                   |  | ||||||
| %   | . .               ..   ..               . . |     | blockheight       |  | ||||||
| %   | . .     Back      ..   ..     Front     . . |     |                   |  | ||||||
| %   | . .               ..   ..               . . |     |                   |  | ||||||
| %   | . .               ..   ..               . . |     v                   |  | ||||||
| %   | . + - - - - - - - ++ - ++ - - - - - - - + . |    --v coverboardgrow   |  | ||||||
| %   | + - - - - - - - - ++ - ++ - - - - - - - - + |    --v coverflap                  |  | ||||||
| %   +-------------------++---++-------------------+    --- |  | ||||||
| %                        .   . |  | ||||||
| %                       ^.   .^ spinefold |  | ||||||
| %                        .   . |  | ||||||
| %                        <---> spinewidth |  | ||||||
| % |  | ||||||
| % |  | ||||||
| % - jacket: (XXX) |  | ||||||
| % |  | ||||||
| %   <---> jaketflap/jacketflapback                  <---> jaketflap/jacketflapfront |  | ||||||
| %   .   .                                           .   . |  | ||||||
| %   .   .     blockwidth            blockwidth      .   . |  | ||||||
| %   .   .  <--------------->     <--------------->  .   . |  | ||||||
| %   .   .<-> coverboardgrow                      <-> coverboardgrow |  | ||||||
| %   .   .  .                                     .  .   . |  | ||||||
| %   +---++-----------------++---++-----------------++---+    --- |  | ||||||
| %   |   .. + - - - - - - - ++ - ++ - - - - - - - + ..   |    --^ coverboardgrow |  | ||||||
| %   |   .. .               ..   ..               . ..   |     ^ |  | ||||||
| %   |   .. .               ..   ..               . ..   |     | blockheight |  | ||||||
| %   |   .. .     Back      ..   ..     Front     . ..   |     | |  | ||||||
| %   |   .. .               ..   ..               . ..   |     | |  | ||||||
| %   |   .. .               ..   ..               . ..   |     v |  | ||||||
| %   |   .. + - - - - - - - ++ - ++ - - - - - - - + ..   |    --v coverboardgrow |  | ||||||
| %   +---++-----------------++---++-----------------++---+    ---  |  | ||||||
| %       ..                  .   .                  .. |  | ||||||
| %       ^ jacketwrap        .   .                  ^ jacketwrap |  | ||||||
| %                          ^.   .^ spinefold |  | ||||||
| %                           .   . |  | ||||||
| %                           <---> spinewidth |  | ||||||
| % | % | ||||||
|  | %% \DescribeMacro{layoutmode=<layout>} | ||||||
|  | %% \DescribeMacro{block} | ||||||
|  | %% \DescribeMacro{endpaper} | ||||||
|  | %% \DescribeMacro{cover} | ||||||
|  | %% \DescribeMacro{jacket} | ||||||
|  | %% | ||||||
|  | %%	>> layoutmode=<option> | ||||||
|  | %% | ||||||
|  | %% |block| (default) | ||||||
|  | %% | ||||||
|  | %%% \begin{figure}[h] | ||||||
|  | %% \begin{verbatim} | ||||||
|  | %%       blockwidth | ||||||
|  | %%   <---------------> | ||||||
|  | %% | ||||||
|  | %%   +---------------+ | ||||||
|  | %%   |               | | ||||||
|  | %%   |               | | ||||||
|  | %%   |               | | ||||||
|  | %%   |               | | ||||||
|  | %%   |               | | ||||||
|  | %%   +---------------+ | ||||||
|  | %% \end{verbatim} | ||||||
|  | %%% \end{figure} | ||||||
|  | %% | ||||||
|  | %% | ||||||
|  | %% |endpaper|: | ||||||
|  | %% | ||||||
|  | %%% \begin{figure}[h] | ||||||
|  | %% \begin{verbatim} | ||||||
|  | %%       blockwidth 2x | ||||||
|  | %%   <-------------------------------> | ||||||
|  | %% | ||||||
|  | %%   +---------------+---------------+ | ||||||
|  | %%   |               .               | | ||||||
|  | %%   |               .               | | ||||||
|  | %%   |               .               | | ||||||
|  | %%   |               .               | | ||||||
|  | %%   |               .               | | ||||||
|  | %%   +---------------+---------------+ | ||||||
|  | %% \end{verbatim} | ||||||
|  | %%% \end{figure} | ||||||
|  | %%	 | ||||||
|  | %% | ||||||
|  | %% |cover|: | ||||||
|  | %% | ||||||
|  | %%% \begin{figure}[h] | ||||||
|  | %% \begin{verbatim} | ||||||
|  | %%          blockwidth            blockwidth | ||||||
|  | %%       <--------------->     <---------------> | ||||||
|  | %%     <-> coverboardgrow                      <-> coverboardgrow | ||||||
|  | %%   <-> coverflap                             . <-> coverflap | ||||||
|  | %%   . . .                                     . . . | ||||||
|  | %%   +-------------------++---++-------------------+    --- | ||||||
|  | %%   | + - - - - - - - - ++ - ++ - - - - - - - - + |    --^ coverflap                 | ||||||
|  | %%   | . + - - - - - - - ++ - ++ - - - - - - - + . |    --^ coverboardgrow   | ||||||
|  | %%   | . .               ..   ..               . . |     ^                   | ||||||
|  | %%   | . .               ..   ..               . . |     | blockheight       | ||||||
|  | %%   | . .     Back      ..   ..     Front     . . |     |                   | ||||||
|  | %%   | . .               ..   ..               . . |     |                   | ||||||
|  | %%   | . .               ..   ..               . . |     v                   | ||||||
|  | %%   | . + - - - - - - - ++ - ++ - - - - - - - + . |    --v coverboardgrow   | ||||||
|  | %%   | + - - - - - - - - ++ - ++ - - - - - - - - + |    --v coverflap                  | ||||||
|  | %%   +-------------------++---++-------------------+    --- | ||||||
|  | %%                        .   . | ||||||
|  | %%                       ^.   .^ spinefold | ||||||
|  | %%                        .   . | ||||||
|  | %%                        <---> spinewidth | ||||||
|  | %% \end{verbatim} | ||||||
|  | %%% \end{figure} | ||||||
|  | %% | ||||||
|  | %% | ||||||
|  | %% |jacket|: | ||||||
|  | %% | ||||||
|  | %%% \begin{figure}[h] | ||||||
|  | %% \begin{verbatim} | ||||||
|  | %%   <---> jaketflap/jacketflapback                  <---> jaketflap/jacketflapfront | ||||||
|  | %%   .   .                                           .   . | ||||||
|  | %%   .   .     blockwidth            blockwidth      .   . | ||||||
|  | %%   .   .  <--------------->     <--------------->  .   . | ||||||
|  | %%   .   .<-> coverboardgrow                      <-> coverboardgrow | ||||||
|  | %%   .   .  .                                     .  .   . | ||||||
|  | %%   +---++-----------------++---++-----------------++---+    --- | ||||||
|  | %%   |   .. + - - - - - - - ++ - ++ - - - - - - - + ..   |    --^ coverboardgrow | ||||||
|  | %%   |   .. .               ..   ..               . ..   |     ^ | ||||||
|  | %%   |   .. .               ..   ..               . ..   |     | blockheight | ||||||
|  | %%   |   .. .     Back      ..   ..     Front     . ..   |     | | ||||||
|  | %%   |   .. .               ..   ..               . ..   |     | | ||||||
|  | %%   |   .. .               ..   ..               . ..   |     v | ||||||
|  | %%   |   .. + - - - - - - - ++ - ++ - - - - - - - + ..   |    --v coverboardgrow | ||||||
|  | %%   +---++-----------------++---++-----------------++---+    ---  | ||||||
|  | %%       ..                  .   .                  .. | ||||||
|  | %%       ^ jacketwrap        .   .                  ^ jacketwrap | ||||||
|  | %%                          ^.   .^ spinefold | ||||||
|  | %%                           .   . | ||||||
|  | %%                           <---> spinewidth | ||||||
|  | %% \end{verbatim} | ||||||
|  | %%% \end{figure} | ||||||
| % | % | ||||||
| % XXX in cover layout setup pdf boxes in a way to use \bleed as foldover... | % XXX in cover layout setup pdf boxes in a way to use \bleed as foldover... | ||||||
| % 		...see hyperref docs to set pdf view/print area (???) | % 		...see hyperref docs to set pdf view/print area (???) | ||||||
| @ -166,7 +216,86 @@ | |||||||
| \DeclareStringOption[0pt]{jacketflapback}[50mm] | \DeclareStringOption[0pt]{jacketflapback}[50mm] | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| % pdf layout... | %%%%% Page geometry | ||||||
|  | % | ||||||
|  | %% \DescribeMacro{blockwidth=<len>} | ||||||
|  | %% \DescribeMacro{blockheight=<len>} | ||||||
|  | %% \DescribeMacro{bindingoffset=<len>} | ||||||
|  | %% \DescribeMacro{bleed=<len>} | ||||||
|  | % | ||||||
|  | %%% \begin{figure}[h] | ||||||
|  | %% \begin{verbatim} | ||||||
|  | %%   <---> bleed                                 <---> bleed | ||||||
|  | %% | ||||||
|  | %%   + - - - - - - - - - - - - - - - - - - - - - + - +   ^ | ||||||
|  | %%   .                                           .   .   | bleed | ||||||
|  | %%   .   +---------------------------------------+   .   v   .   .  --- | ||||||
|  | %%   .   |                           ^       .   =   . | ||||||
|  | %%   .   |   .   .   .   .   .   .   |   .   .   =   .               ^ | ||||||
|  | %%   .   |<-- blockwidth ----------------------->=   .               | | ||||||
|  | %%   .   |   .                       |   .   .   =   .               | | ||||||
|  | %%   .   |                           |       .   =   .       textheight | ||||||
|  | %%   .   |   .                       |   .   .   =   .               | | ||||||
|  | %%   .   |                      blockheight  .   =   .               | | ||||||
|  | %%   .   |   .                       |   .   .   =   .               | | ||||||
|  | %%   .   |                           |       <---> bindingoffset     | | ||||||
|  | %%   .   |   .   .   .   .   .   .   |   .   .   =   .               v | ||||||
|  | %%   .   |                           v       .   =   . | ||||||
|  | %%   .   +---------------------------------------+   .   ^   .   .  --- | ||||||
|  | %%   .   .                                       .   .   | bleed | ||||||
|  | %%   + - - - - - - - - - - - - - - - - - - - - - + - +   v | ||||||
|  | %%       .                                       . | ||||||
|  | %%       |   <-- textwidth -------------->   .   | | ||||||
|  | %%                                               ^ binding line | ||||||
|  | %% \end{verbatim} | ||||||
|  | %%% \end{figure} | ||||||
|  | %% | ||||||
|  | % | ||||||
|  | % NOTE: if blockwidth/blockheight are set they will force recalculations  | ||||||
|  | %		and overriding of the paperwidth/paperheight if they were changed | ||||||
|  | %		by the user code anywhere between \documentclass[..]{photobook} | ||||||
|  | %		and \begin{document}... | ||||||
|  | \DeclareStringOption{blockwidth} | ||||||
|  | \DeclareStringOption{blockheight} | ||||||
|  | \DeclareStringOption[0]{bindingoffset}[10mm] | ||||||
|  | \DeclareStringOption[5mm]{bleed}[5mm] | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %%%%% Image clearance | ||||||
|  | % | ||||||
|  | %% \DescribeMacro{clearimage=<len>} | ||||||
|  | % | ||||||
|  | %% Distance from image to paper border (clearance) for full-page images. | ||||||
|  | %% | ||||||
|  | %% this can be: | ||||||
|  | %% - negative value set image bleed,  | ||||||
|  | %% - positive value set distance from paper edge to image. | ||||||
|  | % | ||||||
|  | \DeclareStringOption{clearimage}[-5mm] | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %%%%% Image block layout | ||||||
|  | % | ||||||
|  | %% \DescribeMacro{imageblockwidth=<len>} | ||||||
|  | %% \DescribeMacro{imageblockheight=<len>} | ||||||
|  | %% \DescribeMacro{imageblockoffsettop=<len>} | ||||||
|  | % | ||||||
|  | %% Image block size relative to text block. | ||||||
|  | % | ||||||
|  | % XXX better name... | ||||||
|  | \DeclareStringOption[0.85]{imageblockwidth}[1] | ||||||
|  | \DeclareStringOption[0.85]{imageblockheight}[1] | ||||||
|  | \DeclareStringOption[-0.05]{imageblockoffsettop}[0] | ||||||
|  | 
 | ||||||
|  | %%%%% PDF Viewer layout | ||||||
|  | % | ||||||
|  | %% \DescribeMacro{pdfpagelayout=<mode>} | ||||||
|  | %% \DescribeMacro{SinglePage} | ||||||
|  | %% \DescribeMacro{OneColumn} | ||||||
|  | %% \DescribeMacro{TwoColumnLeft} | ||||||
|  | %% \DescribeMacro{TwoColumnRight} | ||||||
|  | %% \DescribeMacro{TwoPageLeft} | ||||||
|  | %% \DescribeMacro{TwoPageRight} | ||||||
| % | % | ||||||
| % defaults: | % defaults: | ||||||
| %	- TwoColumnLeft (for layoutmode=block) | %	- TwoColumnLeft (for layoutmode=block) | ||||||
| @ -182,56 +311,11 @@ | |||||||
| \@DeclareLiteralOptionTo{pdfpagelayout}{TwoPageLeft} | \@DeclareLiteralOptionTo{pdfpagelayout}{TwoPageLeft} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| % page geometry... | %%%%% Other options | ||||||
| % | % | ||||||
| %   <---> bleed                                 <---> bleed | %% \DescribeMacro{geometrynodefaults} | ||||||
| % | % | ||||||
| %   + - - - - - - - - - - - - - - - - - - - - - + - +   ^ | %% let the user set geometry defaults. | ||||||
| %   .                                           .   .   | bleed |  | ||||||
| %   .   +---------------------------------------+   .   v   .   .  --- |  | ||||||
| %   .   |                           ^       .   =   . |  | ||||||
| %   .   |   .   .   .   .   .   .   |   .   .   =   .               ^ |  | ||||||
| %   .   |<-- blockwidth ----------------------->=   .               | |  | ||||||
| %   .   |   .                       |   .   .   =   .               | |  | ||||||
| %   .   |                           |       .   =   .       textheight |  | ||||||
| %   .   |   .                       |   .   .   =   .               | |  | ||||||
| %   .   |                      blockheight  .   =   .               | |  | ||||||
| %   .   |   .                       |   .   .   =   .               | |  | ||||||
| %   .   |                           |       <---> bindingoffset     | |  | ||||||
| %   .   |   .   .   .   .   .   .   |   .   .   =   .               v |  | ||||||
| %   .   |                           v       .   =   . |  | ||||||
| %   .   +---------------------------------------+   .   ^   .   .  --- |  | ||||||
| %   .   .                                       .   .   | bleed |  | ||||||
| %   + - - - - - - - - - - - - - - - - - - - - - + - +   v |  | ||||||
| %       .                                       . |  | ||||||
| %       |   <-- textwidth -------------->   .   | |  | ||||||
| %                                               ^ binding line |  | ||||||
| % |  | ||||||
| % NOTE: if blockwidth/blockheight are set they will force recalculations  |  | ||||||
| %		and overriding of the paperwidth/paperheight if they were changed |  | ||||||
| %		by the user code anywhere between \documentclass[..]{photobook} |  | ||||||
| %		and \begin{document}... |  | ||||||
| \DeclareStringOption{blockwidth} |  | ||||||
| \DeclareStringOption{blockheight} |  | ||||||
| \DeclareStringOption[0]{bindingoffset}[10mm] |  | ||||||
| \DeclareStringOption[5mm]{bleed}[5mm] |  | ||||||
| 
 |  | ||||||
| % Distance from image to paper border (clearence) for full-page images. |  | ||||||
| % |  | ||||||
| % this can be: |  | ||||||
| % - negative value set image bleed,  |  | ||||||
| % - positive value set distance frome paper edge to image. |  | ||||||
| % |  | ||||||
| \DeclareStringOption{clearimage}[-5mm] |  | ||||||
| 
 |  | ||||||
| % Image block size relative to text block... |  | ||||||
| % |  | ||||||
| % XXX better name... |  | ||||||
| \DeclareStringOption[0.85]{imageblockwidth}[1] |  | ||||||
| \DeclareStringOption[0.85]{imageblockheight}[1] |  | ||||||
| \DeclareStringOption[-0.05]{imageblockoffsettop}[0] |  | ||||||
| 
 |  | ||||||
| % let the user set geometry defaults. |  | ||||||
| % | % | ||||||
| % NOTE: if this is not set any options set by the uset intersecting with | % NOTE: if this is not set any options set by the uset intersecting with | ||||||
| %		options set in the class will get overriden by class options... | %		options set in the class will get overriden by class options... | ||||||
| @ -240,7 +324,7 @@ | |||||||
| %			paperheight=\bleedblockheight | %			paperheight=\bleedblockheight | ||||||
| %			bindingoffset=\bindingoffset | %			bindingoffset=\bindingoffset | ||||||
| % | % | ||||||
| % XXX better name... | % XXX better name.. | ||||||
| \DeclareBoolOption{geometrynodefaults} | \DeclareBoolOption{geometrynodefaults} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| @ -285,10 +369,14 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Globals... | %%%% Globals | ||||||
| % | % | ||||||
| % NOTE: most of these are setup in \InitPageLengths... | % NOTE: most of these are setup in \InitPage... | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\layoutmode} | ||||||
|  | % | ||||||
|  | %%	Layout mode | ||||||
|  | %% | ||||||
| \edef\layoutmode{\photobook@layoutmode} | \edef\layoutmode{\photobook@layoutmode} | ||||||
| 
 | 
 | ||||||
| % layout mode tests... | % layout mode tests... | ||||||
| @ -301,62 +389,129 @@ | |||||||
| \newif\ifcoverlikelayout | \newif\ifcoverlikelayout | ||||||
| \newif\ifblocklayout | \newif\ifblocklayout | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\pdfpagelayout} | ||||||
|  | % | ||||||
|  | %%	Controls the default layout in the pdf viewer. | ||||||
|  | %% | ||||||
| \edef\pdfpagelayout{\photobook@pdfpagelayout} | \edef\pdfpagelayout{\photobook@pdfpagelayout} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\spinewidth} | ||||||
|  | % | ||||||
|  | %%	Spine width | ||||||
|  | %% | ||||||
| \newlength\spinewidth | \newlength\spinewidth | ||||||
| \setlength\spinewidth{\photobook@spinewidth} | \setlength\spinewidth{\photobook@spinewidth} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\spinefold} | ||||||
|  | % | ||||||
|  | %%	Spine fold width | ||||||
|  | %% | ||||||
| \newlength\spinefold | \newlength\spinefold | ||||||
| \setlength\spinefold{\photobook@spinefold} | \setlength\spinefold{\photobook@spinefold} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\coverboardgrow} | ||||||
|  | % | ||||||
|  | %%	Controls how much biger the cover board is than the page block | ||||||
|  | %% | ||||||
| \newlength\coverboardgrow | \newlength\coverboardgrow | ||||||
| \setlength\coverboardgrow{\photobook@coverboardgrow} | \setlength\coverboardgrow{\photobook@coverboardgrow} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\coverflap} | ||||||
|  | % | ||||||
|  | %%	Cover flap | ||||||
|  | %% | ||||||
| \newlength\coverflap | \newlength\coverflap | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\jacketwrap} | ||||||
|  | %% \DescribeMacro{\jacketflap} | ||||||
|  | %% \DescribeMacro{\jacketflapfront} | ||||||
|  | %% \DescribeMacro{\jacketflapback} | ||||||
|  | % | ||||||
|  | %%	Jacker configuration | ||||||
|  | %% | ||||||
| \newlength\jacketwrap | \newlength\jacketwrap | ||||||
| \newlength\jacketflap | \newlength\jacketflap | ||||||
| \newlength\jacketflapfront | \newlength\jacketflapfront | ||||||
| \newlength\jacketflapback | \newlength\jacketflapback | ||||||
| % NOTE: page and bleed block sizes are set via \InitPageLengths | 
 | ||||||
|  | %% \DescribeMacro{\blockwidth} | ||||||
|  | %% \DescribeMacro{\blockheight} | ||||||
|  | % | ||||||
|  | %%	Page block size | ||||||
|  | %% | ||||||
|  | % NOTE: page and bleed block sizes are set via \InitPage | ||||||
| \newlength\blockwidth | \newlength\blockwidth | ||||||
| \newlength\blockheight | \newlength\blockheight | ||||||
| % NOTE: these are equivalent to \paperwidth and \paperheight but are  | 
 | ||||||
| %		independent of them... | %% \DescribeMacro{\bleedblockwidth} | ||||||
|  | %% \DescribeMacro{\bleedblockheight} | ||||||
|  | % | ||||||
|  | %%	Page block size with bleeds | ||||||
|  | %% | ||||||
|  | %%	These are equivalent to |\paperwidth| and |\paperheight| but are  | ||||||
|  | %%	independent of them... | ||||||
| \newlength\bleedblockwidth | \newlength\bleedblockwidth | ||||||
| \newlength\bleedblockheight | \newlength\bleedblockheight | ||||||
| 
 | 
 | ||||||
| % original page block size... | %% \DescribeMacro{\pageblockwidth} | ||||||
|  | %% \DescribeMacro{\pageblockheight} | ||||||
| % | % | ||||||
| % for the block layout these are the same as \blockwidth and \blockheight | %% Original page block size | ||||||
| % for other layouts these are the original page layout size while the  | %% | ||||||
| % \blockwidth are set tho the current layout visible size... | %% for the block layout these are the same as |\blockwidth| and |\blockheight| | ||||||
|  | %% for other layouts these are the original page layout size while the  | ||||||
|  | %% |\blockwidth| are set tho the current layout visible size. | ||||||
| \newlength\pageblockwidth | \newlength\pageblockwidth | ||||||
| \newlength\pageblockheight | \newlength\pageblockheight | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\bleed} | ||||||
|  | % | ||||||
|  | %%	Page bleed size | ||||||
|  | %% | ||||||
| \newlength\bleed | \newlength\bleed | ||||||
| \setlength\bleed{\photobook@bleed} | \setlength\bleed{\photobook@bleed} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\bindingoffset} | ||||||
|  | % | ||||||
|  | %%	Binding offset | ||||||
|  | %% | ||||||
| \newlength\bindingoffset | \newlength\bindingoffset | ||||||
| \setlength\bindingoffset{\photobook@bindingoffset} | \setlength\bindingoffset{\photobook@bindingoffset} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\clearimage} | ||||||
|  | % | ||||||
|  | %%	Image clearence | ||||||
|  | %% | ||||||
| % NOTE: since this can be any number but we need to detect if it was set  | % NOTE: since this can be any number but we need to detect if it was set  | ||||||
| %		manually we'll set it to \maxdimen and hope noe will print  | %		manually we'll set it to \maxdimen and hope noe will print  | ||||||
| %		something big enough and dare to use it as image clearence... | %		something big enough and dare to use it as image clearence... | ||||||
| \newlength{\clearimage} | \newlength{\clearimage} | ||||||
| \setlength\clearimage{\maxdimen} | \setlength\clearimage{\maxdimen} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\imageblockwidth} | ||||||
|  | %% \DescribeMacro{\imageblockheight} | ||||||
|  | % | ||||||
|  | %%	Image block width relative to |\textwidth| | ||||||
|  | %% | ||||||
| \edef\imageblockwidth{\photobook@imageblockwidth} | \edef\imageblockwidth{\photobook@imageblockwidth} | ||||||
| 
 |  | ||||||
| \edef\imageblockheight{\photobook@imageblockheight} | \edef\imageblockheight{\photobook@imageblockheight} | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\imageblockoffsettop} | ||||||
|  | % | ||||||
|  | %% | ||||||
|  | %% | ||||||
| \edef\imageblockoffsettop{\photobook@imageblockoffsettop} | \edef\imageblockoffsettop{\photobook@imageblockoffsettop} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Init / reset... | %%%% Initialization | ||||||
| 
 | %% | ||||||
| \newcommand\InitPageLengths{ | %% \DescribeMacro{\InitPage} | ||||||
|  | % | ||||||
|  | %%	Initialize page dimentions. | ||||||
|  | %% | ||||||
|  | \newcommand\InitPage{ | ||||||
| 	% layout bools/tests... | 	% layout bools/tests... | ||||||
| 	\coverlayoutfalse | 	\coverlayoutfalse | ||||||
| 	\hardcoverlayoutfalse | 	\hardcoverlayoutfalse | ||||||
| @ -496,12 +651,16 @@ | |||||||
| 		\relax} } | 		\relax} } | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| \newcommand\ResetPageLengths{ | %% \DescribeMacro{\ResetPage} | ||||||
|  | % | ||||||
|  | %%	Reset and re-initialize page dimentions. | ||||||
|  | %% | ||||||
|  | \newcommand\ResetPage{ | ||||||
| 	\setlength\blockwidth{0mm} | 	\setlength\blockwidth{0mm} | ||||||
| 	\setlength\blockheight{0mm} | 	\setlength\blockheight{0mm} | ||||||
| 	\edef\pdfpagelayout{} | 	\edef\pdfpagelayout{} | ||||||
| 	% | 	% | ||||||
| 	\InitPageLengths } | 	\InitPage} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| @ -511,7 +670,7 @@ | |||||||
| % Setup... | % Setup... | ||||||
| 
 | 
 | ||||||
| % init/update lengths... | % init/update lengths... | ||||||
| \InitPageLengths | \InitPage | ||||||
| 
 | 
 | ||||||
| % minimal geometry setup... | % minimal geometry setup... | ||||||
| \RequirePackage[ | \RequirePackage[ | ||||||
| @ -543,7 +702,7 @@ | |||||||
| % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | % - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - | ||||||
| % Geometry... | % Geometry... | ||||||
| 
 | 
 | ||||||
| 	\InitPageLengths | 	\InitPage | ||||||
| 
 | 
 | ||||||
| 	% no-defaults -- the user is expected to set things up... | 	% no-defaults -- the user is expected to set things up... | ||||||
| 	\ifphotobook@geometrynodefaults | 	\ifphotobook@geometrynodefaults | ||||||
| @ -610,32 +769,52 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Generic Commands.... | %%%% Generic commands | ||||||
|  | %% | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\keywords} | ||||||
|  | % | ||||||
|  | %%	Set pdf metadata keywords | ||||||
|  | %% | ||||||
|  | %%	>>	\keywords{<keywords>} | ||||||
|  | %% | ||||||
| \def\@keywords{} | \def\@keywords{} | ||||||
| 
 | 
 | ||||||
| \newcommand\keywords[1]{% | \newcommand\keywords[1]{% | ||||||
| 	\def\@keywords{#1}} | 	\def\@keywords{#1}} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\subject} | ||||||
|  | % | ||||||
|  | %%	Set pdf metadata subject | ||||||
|  | %% | ||||||
|  | %%	>>	\subject{<subject>} | ||||||
|  | %% | ||||||
| \def\@subject{} | \def\@subject{} | ||||||
| 
 | 
 | ||||||
| \newcommand\subject[1]{% | \newcommand\subject[1]{% | ||||||
| 	\def\@subject{#1}} | 	\def\@subject{#1}} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\cleartoleftpage} | ||||||
|  | % | ||||||
|  | %%	Forces content to left page | ||||||
|  | %% | ||||||
| \newcommand*{\cleartoleftpage}{% | \newcommand*{\cleartoleftpage}{% | ||||||
| 	\clearpage | 	\clearpage | ||||||
| 	\if@twoside | 	\if@twoside | ||||||
| 		\ifodd\c@page | 		\ifodd\c@page | ||||||
| 			\hbox{}\newpage | 			\hbox{}\newpage | ||||||
| 			\if@twocolumn | 			\if@twocolumn | ||||||
| 				\hbox{}\newpage | 				\hbox{}\newpage \fi\fi\fi } | ||||||
| 			\fi |  | ||||||
| 		\fi |  | ||||||
| 	\fi } |  | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
|  | %% \DescribeMacro{\pdfpagecount} | ||||||
|  | % | ||||||
|  | %%	Get pdf page count | ||||||
|  | %% | ||||||
|  | %%	>>	\pdfpagecount{<file.pdf>} | ||||||
|  | %% | ||||||
| \newcommand\pdfpagecount[1]{ | \newcommand\pdfpagecount[1]{ | ||||||
| 	\ifpdftex | 	\ifpdftex | ||||||
| 		\pdfximage{#1} | 		\pdfximage{#1} | ||||||
| @ -653,8 +832,12 @@ | |||||||
| 			tex.write(pages) } \fi\fi } | 			tex.write(pages) } \fi\fi } | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| % \pdfspinewidth{paper-thikness}{cover-thikness}{block-pdf} | %% \DescribeMacro{\pdfspinewidth} | ||||||
| % | % | ||||||
|  | %%	Calculate spine thickness | ||||||
|  | %% | ||||||
|  | %%	>>	\pdfspinewidth{<paper-thikness>}{<cover-thikness>}{<block-pdf>} | ||||||
|  | %% | ||||||
| % NOTE: really "like" how LaTeX overcomplicats simple math... | % NOTE: really "like" how LaTeX overcomplicats simple math... | ||||||
| \newcommand\pdfspinewidth[3]{% | \newcommand\pdfspinewidth[3]{% | ||||||
| 	\setlength\spinewidth{\dimexpr | 	\setlength\spinewidth{\dimexpr | ||||||
| @ -693,110 +876,7 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Captions... | %%%% Environments | ||||||
| % XXX need to be able to configure/pass/override: |  | ||||||
| %		- size / \captionsize... |  | ||||||
| %		- color... |  | ||||||
| % XXX captions seem not to account for \imageblockoffsettop... |  | ||||||
| 
 |  | ||||||
| %\newcommand\captionsize{\scriptsize} |  | ||||||
| \newcommand\captionsize{\fontsize{6.5pt}{8pt}\selectfont} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % \imagecaption{caption}{location-date} |  | ||||||
| % |  | ||||||
| \newcommand\imagecaption[2]{ |  | ||||||
| 	{\captionsize% |  | ||||||
| 		#1 % |  | ||||||
| 		\par\vspace{-\parskip}% |  | ||||||
| 		#2}} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % \overlaycaption{caption}{location-date} |  | ||||||
| % |  | ||||||
| \newcommand\overlaycaption[2]{ |  | ||||||
| 	\begin{flushright} |  | ||||||
| 		\captionsize% |  | ||||||
| 		\color{black}{% |  | ||||||
| 			\colorbox{white}{ #1 }% |  | ||||||
| 			\par\vspace{-\parskip}% |  | ||||||
| 			\colorbox{white}{ #2 }} |  | ||||||
| 	\end{flushright}} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % \captionsidebox[offset]{imagebox}{text} |  | ||||||
| % |  | ||||||
| \newcommand\captionsidebox[3][0mm]{ |  | ||||||
| 	\begin{minipage}{\dimexpr  |  | ||||||
| 			% caption-image distance... |  | ||||||
| 			-1em |  | ||||||
| 			-\clearimage  |  | ||||||
| 			+\blockwidth |  | ||||||
| 			-(\wd#2 - #1) |  | ||||||
| 			+(\nudgeimageby) |  | ||||||
| 			-(0.5\blockwidth - 0.5\textwidth) \relax}% |  | ||||||
| 		{ \captionsize #3 } |  | ||||||
| 	\end{minipage}} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % \captionboxleft[offset]{imagebox}{text} |  | ||||||
| % \captionboxright[offset]{imagebox}{text} |  | ||||||
| % |  | ||||||
| \newcommand\captionboxleft[3][0mm]{ |  | ||||||
| 	\null |  | ||||||
| 	\vfill |  | ||||||
| 	\begin{flushleft} |  | ||||||
| 	\captionsidebox[#1]{#2}{% |  | ||||||
| 		\begin{flushright} |  | ||||||
| 			#3 |  | ||||||
| 		\end{flushright}} |  | ||||||
| 	\end{flushleft}} |  | ||||||
| \newcommand\captionboxright[3][0mm]{ |  | ||||||
| 	\null |  | ||||||
| 	\vfill |  | ||||||
| 	\begin{flushright} |  | ||||||
| 	\captionsidebox[#1]{#2}{% |  | ||||||
| 		\begin{flushleft} |  | ||||||
| 			#3 |  | ||||||
| 		\end{flushleft}} |  | ||||||
| 	\end{flushright}} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % XXX \CAPTIONWIDTHFIX |  | ||||||
| % \captionbottombox[offset]{imagebox}{text} |  | ||||||
| % |  | ||||||
| % XXX for some reason the width is wrong here... |  | ||||||
| \newcommand\captionbottombox[3][0mm]{ |  | ||||||
| 	\hspace{ #1 }{ |  | ||||||
| 		% XXX the \CAPTIONWIDTHFIX factor is compensating for an odd alignment error... |  | ||||||
| 		\begin{minipage}{\dimexpr \CAPTIONWIDTHFIX + \wd#2 \relax} |  | ||||||
| 			{ \captionsize #3 } |  | ||||||
| 		\end{minipage}}} |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| % \graycaptionpage{text} |  | ||||||
| % |  | ||||||
| % XXX should this be \captionsize or \scriptsize |  | ||||||
| \newcommand\graycaptionpage[1]{ |  | ||||||
| 	\pagestyle{empty} |  | ||||||
| 	\pagecolor{normgray} |  | ||||||
| 	\color{white} |  | ||||||
| 	\null |  | ||||||
| 	\vfill |  | ||||||
| 	\hspace{0.66\textwidth}{% |  | ||||||
| 		\begin{minipage}{0.33\textwidth} |  | ||||||
| 			\setlength{\parskip}{0.5em}% |  | ||||||
| 			\captionsize\it% |  | ||||||
| 			#1 |  | ||||||
| 		\end{minipage} } |  | ||||||
| 	\newpage |  | ||||||
| 	\nopagecolor |  | ||||||
| 	\color{black} } |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| 
 |  | ||||||
| %---------------------------------------------------------------------- |  | ||||||
| % Envs... |  | ||||||
| % | % | ||||||
| % XXX need a way to place images / templates into these... | % XXX need a way to place images / templates into these... | ||||||
| % XXX should these only be visible in respective modes or for non-zero widths??? | % XXX should these only be visible in respective modes or for non-zero widths??? | ||||||
| @ -1056,7 +1136,123 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Page Templates... | %%%% Captions | ||||||
|  | % XXX need to be able to configure/pass/override: | ||||||
|  | %		- size / \captionsize... | ||||||
|  | %		- color... | ||||||
|  | % XXX captions seem not to account for \imageblockoffsettop... | ||||||
|  | 
 | ||||||
|  | %\newcommand\captionsize{\scriptsize} | ||||||
|  | \newcommand\captionsize{\fontsize{6.5pt}{8pt}\selectfont} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\imagecaption} | ||||||
|  | % | ||||||
|  | %%	>> \imagecaption{<caption>}{<location-date>} | ||||||
|  | %% | ||||||
|  | \newcommand\imagecaption[2]{ | ||||||
|  | 	{\captionsize% | ||||||
|  | 		#1 % | ||||||
|  | 		\par\vspace{-\parskip}% | ||||||
|  | 		#2}} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\overlaycaption} | ||||||
|  | % | ||||||
|  | %%	>> \overlaycaption{<caption>}{<location-date>} | ||||||
|  | %% | ||||||
|  | \newcommand\overlaycaption[2]{ | ||||||
|  | 	\begin{flushright} | ||||||
|  | 		\captionsize% | ||||||
|  | 		\color{black}{% | ||||||
|  | 			\colorbox{white}{ #1 }% | ||||||
|  | 			\par\vspace{-\parskip}% | ||||||
|  | 			\colorbox{white}{ #2 }} | ||||||
|  | 	\end{flushright}} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\captionsidebox} | ||||||
|  | % | ||||||
|  | %%	>> \captionsidebox[<offset>]{<imagebox>}{<text>} | ||||||
|  | %% | ||||||
|  | \newcommand\captionsidebox[3][0mm]{ | ||||||
|  | 	\begin{minipage}{\dimexpr  | ||||||
|  | 			% caption-image distance... | ||||||
|  | 			-1em | ||||||
|  | 			-\clearimage  | ||||||
|  | 			+\blockwidth | ||||||
|  | 			-(\wd#2 - #1) | ||||||
|  | 			+(\nudgeimageby) | ||||||
|  | 			-(0.5\blockwidth - 0.5\textwidth) \relax}% | ||||||
|  | 		{ \captionsize #3 } | ||||||
|  | 	\end{minipage}} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\captionboxleft} | ||||||
|  | %% \DescribeMacro{\captionboxright} | ||||||
|  | % | ||||||
|  | %%	>> \captionboxleft[<offset>]{<imagebox>}{<text>} | ||||||
|  | %%	>> \captionboxright[<offset>]{<imagebox>}{<text>} | ||||||
|  | %% | ||||||
|  | \newcommand\captionboxleft[3][0mm]{ | ||||||
|  | 	\null | ||||||
|  | 	\vfill | ||||||
|  | 	\begin{flushleft} | ||||||
|  | 	\captionsidebox[#1]{#2}{% | ||||||
|  | 		\begin{flushright} | ||||||
|  | 			#3 | ||||||
|  | 		\end{flushright}} | ||||||
|  | 	\end{flushleft}} | ||||||
|  | \newcommand\captionboxright[3][0mm]{ | ||||||
|  | 	\null | ||||||
|  | 	\vfill | ||||||
|  | 	\begin{flushright} | ||||||
|  | 	\captionsidebox[#1]{#2}{% | ||||||
|  | 		\begin{flushleft} | ||||||
|  | 			#3 | ||||||
|  | 		\end{flushleft}} | ||||||
|  | 	\end{flushright}} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | % XXX \CAPTIONWIDTHFIX | ||||||
|  | %% \DescribeMacro{\captionbottombox} | ||||||
|  | % | ||||||
|  | %%	>> \captionbottombox[<offset>]{<imagebox>}{<text>} | ||||||
|  | %% | ||||||
|  | % XXX for some reason the width is wrong here... | ||||||
|  | \newcommand\captionbottombox[3][0mm]{ | ||||||
|  | 	\hspace{ #1 }{ | ||||||
|  | 		% XXX the \CAPTIONWIDTHFIX factor is compensating for an odd alignment error... | ||||||
|  | 		\begin{minipage}{\dimexpr \CAPTIONWIDTHFIX + \wd#2 \relax} | ||||||
|  | 			{ \captionsize #3 } | ||||||
|  | 		\end{minipage}}} | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %% \DescribeMacro{\graycaptionpage} | ||||||
|  | % | ||||||
|  | %%	>> \graycaptionpage{<text>} | ||||||
|  | %% | ||||||
|  | % XXX should this be \captionsize or \scriptsize | ||||||
|  | \newcommand\graycaptionpage[1]{ | ||||||
|  | 	\pagestyle{empty} | ||||||
|  | 	\pagecolor{normgray} | ||||||
|  | 	\color{white} | ||||||
|  | 	\null | ||||||
|  | 	\vfill | ||||||
|  | 	\hspace{0.66\textwidth}{% | ||||||
|  | 		\begin{minipage}{0.33\textwidth} | ||||||
|  | 			\setlength{\parskip}{0.5em}% | ||||||
|  | 			\captionsize\it% | ||||||
|  | 			#1 | ||||||
|  | 		\end{minipage} } | ||||||
|  | 	\newpage | ||||||
|  | 	\nopagecolor | ||||||
|  | 	\color{black} } | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | 
 | ||||||
|  | %---------------------------------------------------------------------- | ||||||
|  | %%%% Page Templates | ||||||
| 
 | 
 | ||||||
| \newsavebox\photobook@imagebox | \newsavebox\photobook@imagebox | ||||||
| 
 | 
 | ||||||
| @ -1308,7 +1504,7 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| % Spread Templates... | %%%% Spread Templates | ||||||
| 
 | 
 | ||||||
| \newlength{\photobook@tmpnudgeimageby} | \newlength{\photobook@tmpnudgeimageby} | ||||||
| \newlength{\photobook@tmpvnudgeimageby} | \newlength{\photobook@tmpvnudgeimageby} | ||||||
| @ -1681,11 +1877,11 @@ | |||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| %%% XXX DEBUG... | %5%% XXX DEBUG... | ||||||
| %%\AtBeginDocument{ | %%%\AtBeginDocument{ | ||||||
| %%} | %%%} | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| %---------------------------------------------------------------------- | %---------------------------------------------------------------------- | ||||||
| %                                                  vim:set ts=4 sw=4 : | %% \end{document} %                                 im:set ts=4 sw=4 : | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user