1 | %% |
---|
2 | %% This is file `baposter.cls' |
---|
3 | %% |
---|
4 | %% A relatively comfortable latex class to produce posters with a grid based |
---|
5 | %% layout. It comes with a number of combinable styles and is (maybe only for |
---|
6 | %% the writer) easy to extend, as all the graphics is based on pgf. |
---|
7 | %% |
---|
8 | %% It is meant to be used with pdftex, but might also work with pslatex if you |
---|
9 | %% are not interested in things like transparency. |
---|
10 | %% |
---|
11 | %% Copyright (C) 2007-2011 Brian Amberg |
---|
12 | %% Copyright (C) 2011 Reinhold Kainhofer <reinhold@kainhofer.com> |
---|
13 | %% |
---|
14 | %% 29. September 2011: |
---|
15 | %% - Finally fixed confusion with paper size handling and landscape. This required seperate handling of papersizes |
---|
16 | %% known to the geometry package and other packages. |
---|
17 | %% 26. September 2011: |
---|
18 | %% - Reverted drawing of faded borders to manual method, as the current result does not work with evince, |
---|
19 | %% and produced spurious colored boxes with okular and acroread. |
---|
20 | %% - Added one more example due to popular request |
---|
21 | %% 16. September 2011: |
---|
22 | %% - Removed nag package, such that it compiles on older systems |
---|
23 | %% - Added more examples |
---|
24 | %% 15. September 2011: |
---|
25 | %% - Merged fork by (rk) back into mainline, essentially taking over all the great improvements that Reinhold Kainhofer coded. |
---|
26 | %% We call this version 2, as it breaks the interface in some small points. Essentially watch out for this: |
---|
27 | %% - no/yes keys are now false/true |
---|
28 | %% - the shade-lr etc. keys have the hypen removed, and are now called shadelr etc. |
---|
29 | % - Added more examples, which are all adapted to work with the current version |
---|
30 | %% 27. August 2011 (rk): |
---|
31 | %% - Completely factored out all drawing commands to handler functions, assigned via choice keys |
---|
32 | %% - Added cornerradius, boxheaderheight, boxpadding options |
---|
33 | %% - Added missing roundedright |
---|
34 | %% 26. August 2011 (rk): |
---|
35 | %% - Turned headerbox cmd into posterbox environment (allows verbatim) |
---|
36 | %% - pass several options to packages |
---|
37 | %% - added debug cls option to reduce default output |
---|
38 | %% - rewrote several loops and ifthenelse |
---|
39 | %% - Use boolean and choice keys for all options |
---|
40 | %% - Changed all choice options to set a global function to |
---|
41 | %% \baposter@OPTION@OPTIONVALUE, which are a functions that execute the |
---|
42 | %% option's setting (drawing routine, color setting for tikz, etc.) |
---|
43 | %% - Add a5paper |
---|
44 | %% 07. April 2011: Fixed paper size handling |
---|
45 | %% - Fixed Paper Size handling, you can now specify all page sizes using paperwidth=, paperheight= class options. |
---|
46 | %% - Added rudimentary documentation of the available keys. |
---|
47 | %% 11. December 2010: Fixed "Empty Second Page" bug |
---|
48 | %% - A second empty page was introduced when a document ended with |
---|
49 | %% \end{poster} |
---|
50 | %% \end{document} |
---|
51 | %% This was fixed thanks to a suggestion by Martin Aulbach |
---|
52 | %% - Added |
---|
53 | %% \thispagestyle{empty} |
---|
54 | %% to suppress page numbers, which became visible when the margins are large. |
---|
55 | %% The underlying problem of page-size handling has not yet been solved. |
---|
56 | %% 30. September 2010: Border Bugfixes |
---|
57 | %% - Correct background color with textborder=rounded-small, Thanks to Ke Chen for the bugreport and patch |
---|
58 | %% - Correctly draw rectangular text boxes, Thanks to abenkst for the bugreport and fix |
---|
59 | %% 10. June 2010: Added option to set the number of columns |
---|
60 | %% - added a class option to set the number of columns |
---|
61 | %% - columns=5: sets the number of columns to 5, possible values are 1..6, default is 3 in portrait and 4 in landscape format |
---|
62 | %% 29. April 2009: Incorporated Patches by Arne Henningsen |
---|
63 | %% - added some class options |
---|
64 | %% - a4shrink: shrink the paper to A4 size (for printing drafts or handouts) |
---|
65 | %% - movebody=Xpt: move the text/poster body Xpt to the right |
---|
66 | %% (or to the left if Xpt is negative), |
---|
67 | %% e.g. for manually centering the poster on the page |
---|
68 | %% - showframe: use the "showframe" option of the "geometry" package |
---|
69 | %% - a0paper (default): set paper size to A0 |
---|
70 | %% - archE: set paper size to Arch E |
---|
71 | %% - setting "background" can be "none" now (otherwise the "showframe" |
---|
72 | %% option has no effect) |
---|
73 | %% - the page number has been removed (it was mostly not visible before) |
---|
74 | %% - the "margin=" option works now |
---|
75 | %% 04. December 2008 |
---|
76 | %% - Mainly an update to the landscape example |
---|
77 | %% 14. November 2008 |
---|
78 | %% - Actually center the title when eyecatcher is used. |
---|
79 | %% 04. November 2008 |
---|
80 | %% - Fixed bug with eyecatcher not working. |
---|
81 | %% 26. June 2008 |
---|
82 | %% - Fixed bug with plain background mode. |
---|
83 | %% 14. June 2008 |
---|
84 | %% - Support for portrait/landscape switching. |
---|
85 | %% - Some smaller bugfixes. |
---|
86 | %% 01. June 2007 |
---|
87 | %% - First version released. |
---|
88 | %% |
---|
89 | %% Use this class with pdflatex |
---|
90 | %% |
---|
91 | %% I have confirmed that this package works with |
---|
92 | %% - texlive 2007 and |
---|
93 | %% - miktex 2.7 |
---|
94 | %% |
---|
95 | %% It does not seem to work with |
---|
96 | %% - miktex 2.2 |
---|
97 | %% - some old versions of tetex |
---|
98 | %% |
---|
99 | %% |
---|
100 | %% TODO: |
---|
101 | %% -) Rename backgrounds back to shaded-tb shade-lr |
---|
102 | %% -) Rename textborder back to rounded-small (consistent naming needed!) |
---|
103 | %% -) Rename headershade back to shade-lr, shade-tb, shade-tb-inverse |
---|
104 | %% -) Rename headershape back to small-rounded |
---|
105 | %% -) Option value consistency (small-rounded vs. rounded-small; missing ones) |
---|
106 | %% -) Rename \baposterHeaderSetShade, \baposterHeaderDrawText to include @ and verb |
---|
107 | %% |
---|
108 | %% |
---|
109 | %% Licence: GPL |
---|
110 | \ProvidesClass{baposter}[2011/11/26 v2.0 baposter class] |
---|
111 | \NeedsTeXFormat{LaTeX2e}[1995/06/01] |
---|
112 | \LoadClass{article} |
---|
113 | \typeout{baposter: Brian Amberg, 2007, 2008, 2009, 2010, 2011 | http://www.brian-amberg.de/uni/poster/} |
---|
114 | \typeout{baposter: Reinhold Kainhofer, 2011 | http://reinhold.kainhofer.com/} |
---|
115 | |
---|
116 | %% Define lengths only once on inclusion, such that we can make multiple posters |
---|
117 | \newlength{\baposter@basepaperwidth} |
---|
118 | \newlength{\baposter@basepaperheight} |
---|
119 | \newlength{\baposter@basemargin} |
---|
120 | \newlength{\baposter@finalpaperwidth} |
---|
121 | \newlength{\baposter@finalpaperheight} |
---|
122 | \newlength{\baposter@finalmargin} |
---|
123 | \newlength{\headerheight}% |
---|
124 | \newlength{\colwidth}% |
---|
125 | \newlength{\colheight}% |
---|
126 | \newlength{\baposter@@colspacing}% |
---|
127 | \newlength{\baposter@box@@cornerradius}% |
---|
128 | \newlength{\baposter@box@@boxheaderheight}% |
---|
129 | \newlength{\baposter@box@@boxpadding}% |
---|
130 | \newlength{\boxstartx}% |
---|
131 | \newlength{\boxstarty}% |
---|
132 | \newlength{\boxwidth}% |
---|
133 | \newlength{\boxheight}% |
---|
134 | \newlength{\baposter@titleimage@left@width}% |
---|
135 | \newlength{\baposter@titleimage@right@width}% |
---|
136 | \newlength{\baposter@titleimage@right@height}% |
---|
137 | \newlength{\baposter@titleimage@textwidth}% |
---|
138 | \newbox\baposter@box@content% |
---|
139 | \newbox\baposter@titleimage@left% |
---|
140 | \newbox\baposter@titleimage@title% |
---|
141 | \newbox\baposter@titleimage@right% |
---|
142 | |
---|
143 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
144 | % Packages |
---|
145 | %------------------------------------------------------------------------------- |
---|
146 | % The only ``weird'' dependency of this package is pgf. All the rest should be |
---|
147 | % installed on any decent system. |
---|
148 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
149 | \typeout{Use Packages} |
---|
150 | \RequirePackage{xkeyval} |
---|
151 | \RequirePackage{calc} |
---|
152 | \RequirePackage[cmyk]{xcolor} |
---|
153 | \RequirePackage{tikz} |
---|
154 | \RequirePackage{pgf} |
---|
155 | \RequirePackage{ifthen} |
---|
156 | \RequirePackage[T1]{fontenc} |
---|
157 | %\RequirePackage[l2tabu, orthodox]{nag} |
---|
158 | \usetikzlibrary{decorations} |
---|
159 | \usetikzlibrary{fadings} |
---|
160 | \usetikzlibrary{snakes} |
---|
161 | \usetikzlibrary{calc} |
---|
162 | |
---|
163 | |
---|
164 | |
---|
165 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
166 | % Settings |
---|
167 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
168 | |
---|
169 | % Choose a smaller value for larger fonts |
---|
170 | \newcommand{\baposter@fontscale}{0.265} |
---|
171 | |
---|
172 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
173 | % Zoom |
---|
174 | %------------------------------------------------------------------------------- |
---|
175 | % We scale the page from fontscale * papersize up to papersize |
---|
176 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
177 | |
---|
178 | |
---|
179 | %% Paper sizes |
---|
180 | \newif\if@landscape |
---|
181 | \newif\if@geometryKnowsThisSize |
---|
182 | \DeclareOptionX{landscape}{\@landscapetrue} |
---|
183 | \DeclareOptionX{portrait}{} |
---|
184 | |
---|
185 | \newcommand{\baposter@setfinalpapersize}[2]{% |
---|
186 | \if@geometryKnowsThisSize |
---|
187 | \setlength{\baposter@finalpaperwidth}{#1}% |
---|
188 | \setlength{\baposter@finalpaperheight}{#2}% |
---|
189 | \else |
---|
190 | \if@landscape |
---|
191 | % Transpose length, if geometry does not handle the papersize based on the key |
---|
192 | \setlength{\baposter@finalpaperwidth}{#2}% |
---|
193 | \setlength{\baposter@finalpaperheight}{#1}% |
---|
194 | \else |
---|
195 | \setlength{\baposter@finalpaperwidth}{#1}% |
---|
196 | \setlength{\baposter@finalpaperheight}{#2}% |
---|
197 | \fi |
---|
198 | \fi |
---|
199 | } |
---|
200 | |
---|
201 | % Default paperwidth and paperheight = a0paper |
---|
202 | \DeclareOptionX{paperwidth}[841mm]{\setlength{\baposter@finalpaperwidth}{#1}} |
---|
203 | \DeclareOptionX{paperheight}[1189mm]{\setlength{\baposter@finalpaperheight}{#1}} |
---|
204 | \DeclareOptionX{archA} { \baposter@setfinalpapersize{9in}{12in}}% |
---|
205 | \DeclareOptionX{archB} { \baposter@setfinalpapersize{12in}{18in}}% |
---|
206 | \DeclareOptionX{archC} { \baposter@setfinalpapersize{18in}{24in}}% |
---|
207 | \DeclareOptionX{archD} { \baposter@setfinalpapersize{24in}{36in}}% |
---|
208 | \DeclareOptionX{archE} { \baposter@setfinalpapersize{36in}{48in}}% |
---|
209 | \DeclareOptionX{archE1} { \baposter@setfinalpapersize{30in}{42in}}% |
---|
210 | \DeclareOptionX{archE2} { \baposter@setfinalpapersize{26in}{38in}}% |
---|
211 | \DeclareOptionX{archE3} { \baposter@setfinalpapersize{27in}{39in}}% |
---|
212 | \DeclareOptionX{a0paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{841mm}{1189mm}}%g |
---|
213 | \DeclareOptionX{a1paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{594mm}{841mm}}%g |
---|
214 | \DeclareOptionX{a2paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{420mm}{594mm}}%g |
---|
215 | \DeclareOptionX{a3paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{297mm}{420mm}}%g |
---|
216 | \DeclareOptionX{a4paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{210mm}{297mm}}%g |
---|
217 | \DeclareOptionX{a5paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{148mm}{210mm}}%g |
---|
218 | \DeclareOptionX{a6paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{105mm}{148mm}}%g |
---|
219 | \DeclareOptionX{b0paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{1000mm}{1414mm}}%g |
---|
220 | \DeclareOptionX{b1paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{707mm}{1000mm}}%g |
---|
221 | \DeclareOptionX{b2paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{500mm}{707mm}}%g |
---|
222 | \DeclareOptionX{b3paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{353mm}{500mm}}%g |
---|
223 | \DeclareOptionX{b4paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{250mm}{353mm}}%g |
---|
224 | \DeclareOptionX{b5paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{176mm}{250mm}}%g |
---|
225 | \DeclareOptionX{b6paper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{125mm}{176mm}}%g |
---|
226 | \DeclareOptionX{ansiapaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{8.5in}{11in}}% |
---|
227 | \DeclareOptionX{ansibpaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{11in}{17in}}% |
---|
228 | \DeclareOptionX{ansicpaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{17in}{22in}}% |
---|
229 | \DeclareOptionX{ansidpaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{22in}{34in}}% |
---|
230 | \DeclareOptionX{ansiepaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{34in}{44in}}% |
---|
231 | \DeclareOptionX{letterpaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{8.5in}{11in}}% |
---|
232 | \DeclareOptionX{legalpaper} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{8.5in}{14in}}% |
---|
233 | \DeclareOptionX{executivepaper}{\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{7.25in}{10.5in}}% |
---|
234 | \DeclareOptionX{screen} {\@geometryKnowsThisSizetrue\baposter@setfinalpapersize{225mm}{180mm}}%g |
---|
235 | |
---|
236 | % Margin |
---|
237 | \setlength{\baposter@finalmargin}{1.5cm} |
---|
238 | \DeclareOptionX{fontscale}[0.292]{\renewcommand{\baposter@fontscale}{#1}} |
---|
239 | \DeclareOptionX{margin} [1.5cm]{\setlength{\baposter@finalmargin}{#1}} |
---|
240 | |
---|
241 | % move text/poster body to the right (or to the left if negative) |
---|
242 | \newlength{\baposter@movebody} |
---|
243 | \setlength{\baposter@movebody}{0cm} |
---|
244 | \DeclareOptionX{movebody}[0cm]{\setlength{\baposter@movebody}{#1}} |
---|
245 | |
---|
246 | |
---|
247 | \newif\if@debug |
---|
248 | \DeclareOptionX{debug}{\@debugtrue} |
---|
249 | %% Will be passed on to other packages (xcolor and geometry), still we don't want unused warnings |
---|
250 | \DeclareOptionX{table}{} |
---|
251 | \DeclareOptionX{showframe}{} |
---|
252 | |
---|
253 | \ProcessOptionsX |
---|
254 | |
---|
255 | \if@debug |
---|
256 | \newcommand{\debug}[1]{\typeout{#1}} |
---|
257 | \else |
---|
258 | \newcommand{\debug}[1]{} |
---|
259 | \fi |
---|
260 | |
---|
261 | |
---|
262 | |
---|
263 | \setlength{\baposter@basepaperwidth} {\baposter@fontscale\baposter@finalpaperwidth } |
---|
264 | \setlength{\baposter@basepaperheight}{\baposter@fontscale\baposter@finalpaperheight} |
---|
265 | \setlength{\baposter@basemargin} {\baposter@fontscale\baposter@finalmargin} |
---|
266 | \newlength{\baposter@basemarginright} |
---|
267 | \setlength{\baposter@basemarginright}{\baposter@basemargin} |
---|
268 | \addtolength{\baposter@basemarginright}{-\baposter@fontscale\baposter@movebody} |
---|
269 | \newlength{\baposter@basemarginleft} |
---|
270 | \setlength{\baposter@basemarginleft}{\baposter@basemargin} |
---|
271 | \addtolength{\baposter@basemarginleft}{\baposter@fontscale\baposter@movebody} |
---|
272 | |
---|
273 | \typeout{Paperwidth=\the\baposter@finalpaperwidth} |
---|
274 | \typeout{Paperheight=\the\baposter@finalpaperheight} |
---|
275 | \typeout{BasePaperwidth=\the\baposter@basepaperwidth} |
---|
276 | \typeout{BasePaperheight=\the\baposter@basepaperheight} |
---|
277 | \usepackage[ |
---|
278 | paperwidth=\baposter@basepaperwidth, |
---|
279 | paperheight=\baposter@basepaperheight, |
---|
280 | tmargin=\baposter@basemargin, |
---|
281 | bmargin=\baposter@basemargin, |
---|
282 | lmargin=\baposter@basemarginleft, |
---|
283 | rmargin=\baposter@basemarginright, |
---|
284 | ]{geometry} |
---|
285 | |
---|
286 | \usepackage{pgfpages} |
---|
287 | \if@landscape |
---|
288 | \if@geometryKnowsThisSize |
---|
289 | \pgfpagesuselayout{resize to}[physical paper width=\baposter@finalpaperheight,physical paper height=\baposter@finalpaperwidth] |
---|
290 | \else |
---|
291 | \pgfpagesuselayout{resize to}[physical paper width=\baposter@finalpaperwidth,physical paper height=\baposter@finalpaperheight] |
---|
292 | \fi |
---|
293 | \else |
---|
294 | \pgfpagesuselayout{resize to}[physical paper width=\baposter@finalpaperwidth,physical paper height=\baposter@finalpaperheight] |
---|
295 | \fi |
---|
296 | |
---|
297 | |
---|
298 | |
---|
299 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
300 | % Default functions for borders/backgrounds |
---|
301 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
302 | |
---|
303 | %% These functions will all be redefined from the actual option values. In |
---|
304 | %% particular, they will be set to \baposter@optionname@optionvalue, which |
---|
305 | %% should do the actual work / setting for that particular optionvalue. |
---|
306 | |
---|
307 | \newcommand{\baposterPosterDrawBackground}[2]{} % Draw poster background |
---|
308 | |
---|
309 | \newcommand{\baposterBoxGetShape}{} % Returns path of text box shape |
---|
310 | \newcommand{\baposterBoxDrawBackground}[2]{} % Draw bg of boxes |
---|
311 | \newcommand{\baposterBoxDrawBorder}[1]{} % Draw border of individual boxes |
---|
312 | |
---|
313 | \newcommand{\baposterHeaderGetShape}{} % Returns path of text box shape |
---|
314 | \newcommand{\baposterHeaderSetShade}[3]{} % Set bg style for box headers |
---|
315 | \newcommand{\baposterHeaderDrawBackground}[3]{} % Draw background of box header |
---|
316 | \newcommand{\baposterHeaderDrawBorder}[1]{} % Draw border of box header |
---|
317 | \newcommand{\baposterHeaderDrawText}[1]{} % Draw text inside box header |
---|
318 | |
---|
319 | \newcommand{\@@previousbox}{notset} % stores the previously processed box for below=auto |
---|
320 | |
---|
321 | % Function to set a user-defined background |
---|
322 | \newcommand{\baposter@backgroundCmd}{\error{No background command defined. Use \background{...} to define background}} |
---|
323 | \newcommand{\background}[1]{\renewcommand{\baposter@backgroundCmd}{#1}} |
---|
324 | |
---|
325 | |
---|
326 | |
---|
327 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
328 | % Handle poster and box options |
---|
329 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
330 | |
---|
331 | \debug{Handling keys} |
---|
332 | |
---|
333 | %% |
---|
334 | %% POSTER OPTIONS |
---|
335 | %% |
---|
336 | %% Store all poster options in variables of the form \baposter@option |
---|
337 | %% choose-keys also store the index in \baposter@optionnr |
---|
338 | %% choose-keys typically also assign a function |
---|
339 | \definecolor{baposter@silver}{cmyk}{0,0,0,0.7} |
---|
340 | \define@boolkey[ba]{poster}[baposter@]{grid} [false] {} |
---|
341 | \define@boolkey[ba]{poster}[baposter@]{eyecatcher} [true] {} |
---|
342 | \define@cmdkey [ba]{poster}[baposter@]{headerheight} [0.1\textheight]{} |
---|
343 | \define@cmdkey [ba]{poster}[baposter@]{columns} [{}] {} |
---|
344 | \define@cmdkey [ba]{poster}[baposter@]{colspacing} [1em] {} |
---|
345 | \define@cmdkey [ba]{poster}[baposter@]{bgColorOne} [baposter@silver]{} |
---|
346 | \define@cmdkey [ba]{poster}[baposter@]{bgColorTwo} [green] {} |
---|
347 | |
---|
348 | % background can be one of: shadeLR, shadeTB, plain, user, none |
---|
349 | \define@choicekey*+[ba]{poster}{background}% |
---|
350 | [\baposter@background\baposter@backgroundnr]% |
---|
351 | {shadeLR, shadeTB, plain, user, none} [plain] {% |
---|
352 | \debug{Poster background: \baposter@background} |
---|
353 | \renewcommand{\baposterPosterDrawBackground}[2]{ |
---|
354 | \csname baposter@background@\baposter@background\endcsname{##1}{##2}} |
---|
355 | }{ |
---|
356 | \PackageWarning{baposter}{Unknown background `\baposter@background' (use |
---|
357 | shadeLR, shadeTB, plain, none, or user). If user is used, you also |
---|
358 | have to define \background{...}.} |
---|
359 | \renewcommand{\baposterPosterDrawBackground}[2]{\baposter@background@none{##1}{##2}} |
---|
360 | } |
---|
361 | |
---|
362 | |
---|
363 | %% |
---|
364 | %% BOX OPTIONS |
---|
365 | %% |
---|
366 | \define@cmdkey[ba]{posterbox}[baposter@box@]{cornerradius} [1em] {} |
---|
367 | \define@cmdkey[ba]{posterbox}[baposter@box@]{boxheaderheight} [2em] {} |
---|
368 | \define@cmdkey[ba]{posterbox}[baposter@box@]{boxpadding} [0.5em] {} |
---|
369 | |
---|
370 | |
---|
371 | % textborder can be one of: none, bars, coils, triangles, rectangle, rounded, |
---|
372 | % roundedleft, roundedsmall, faded; UNIMPLEMENTED: roundedright |
---|
373 | \edef\baposter@box@textborder@validvalues{none,bars,coils,triangles,rectangle,rounded,roundedleft,roundedsmall,faded} |
---|
374 | \define@choicekey*+[ba]{posterbox}{textborder}% |
---|
375 | [\baposter@box@textborder\baposter@box@textbordernr]% |
---|
376 | {none,bars,coils,triangles,rectangle,rounded,roundedleft,roundedright,roundedsmall,faded} [rectangle] {% |
---|
377 | \debug{Text border: \baposter@box@textborder} |
---|
378 | \renewcommand{\baposterBoxGetShape}{ |
---|
379 | \csname baposter@box@boxshape@\baposter@box@textborder\endcsname} |
---|
380 | \renewcommand{\baposterBoxDrawBorder}[1]{ |
---|
381 | \csname baposter@box@drawborder@\baposter@box@textborder\endcsname{##1}} |
---|
382 | }{ |
---|
383 | \PackageWarning{baposter}{Unknown text-border style `\baposter@box@textborder'. |
---|
384 | Edit your file to choose a valid option (\baposter@box@textborder@validvalues).} |
---|
385 | \renewcommand{\baposterBoxGetShape}{\baposter@boxshape@rectangle} |
---|
386 | \renewcommand{\baposterBoxDrawBorder}[1]{\baposter@drawborder@rectangle{##1}} |
---|
387 | } |
---|
388 | |
---|
389 | % boxshade can be one of: shadeLR, shadeTB, plain, none |
---|
390 | \define@choicekey*+[ba]{posterbox}{boxshade}% |
---|
391 | [\baposter@box@boxshade\baposter@box@boxshadenr]% |
---|
392 | {shadelr,shadetb,plain,none} [none] {% |
---|
393 | \debug{Box shade: \baposter@box@boxshade} |
---|
394 | \renewcommand{\baposterBoxDrawBackground}[2]{ |
---|
395 | \csname baposter@box@drawbackground@\baposter@box@boxshade\endcsname{##1}{##2}} |
---|
396 | }{ |
---|
397 | \PackageWarning{baposter}{Unknown boxshade style `\baposter@boxshade'. |
---|
398 | Edit your file to choose a valid option.} |
---|
399 | \renewcommand{\baposterBoxDrawBackground}[2]{\baposter@box@drawbackground@none{##1}{##2}} |
---|
400 | } |
---|
401 | |
---|
402 | % headershade can be one of: shade-lr, shade-tb, shade-tb-inverse, plain |
---|
403 | \define@choicekey*+[ba]{posterbox}{headershade}% |
---|
404 | [\baposter@box@headershade\baposter@box@headershadenr]% |
---|
405 | {shadelr, shadetb, shadetbinverse, plain} [shadelr] {% |
---|
406 | \debug{Header shade: \baposter@box@headershade} |
---|
407 | \renewcommand{\baposterHeaderSetShade}[3]{ |
---|
408 | \csname baposter@box@headershade@\baposter@box@headershade\endcsname{##1}{##2}{##3}} |
---|
409 | }{ |
---|
410 | \PackageWarning{baposter}{Unknown headershade style `\baposter@box@headershade'. |
---|
411 | Edit your file to choose a valid option.} |
---|
412 | \renewcommand{\baposterHeaderSetShade}[3]{\baposter@box@headershade@none{##1}{##2}{##3}} |
---|
413 | } |
---|
414 | |
---|
415 | % headershape can be one of: rectangle, rounded, smallrounded, roundedleft, roundedright |
---|
416 | \define@choicekey*+[ba]{posterbox}{headershape}% |
---|
417 | [\baposter@box@headershape\baposter@box@headershapenr]% |
---|
418 | {rectangle,rounded,smallrounded,roundedleft,roundedright} [roundedright] {% |
---|
419 | \debug{Header shape: \baposter@box@headershape} |
---|
420 | \renewcommand{\baposterHeaderGetShape}{ |
---|
421 | \csname baposter@box@headershape@\baposter@box@headershape\endcsname} |
---|
422 | \renewcommand{\baposterHeaderDrawText}[1]{ |
---|
423 | \csname baposter@box@headerdrawtext@\baposter@box@headershape\endcsname{##1}} |
---|
424 | \renewcommand{\baposterHeaderDrawBorder}[1]{ |
---|
425 | \csname baposter@box@headerdrawborder@\baposter@box@headershape\endcsname{##1}} |
---|
426 | }{ |
---|
427 | \PackageWarning{baposter}{Unknown headershape style `\baposter@headershape'. |
---|
428 | Edit your file to choose a valid option.} |
---|
429 | \renewcommand{\baposterHeaderGetShape}{\baposter@box@headershape@rectangle} |
---|
430 | \renewcommand{\baposterHeaderDrawText}[1]{\baposter@box@headerdrawtext@rectangle{##1}} |
---|
431 | \renewcommand{\baposterHeaderDrawBorder}[1]{\baposter@box@headerdrawborder@rectangle{##1}} |
---|
432 | } |
---|
433 | |
---|
434 | % headerborder can be one of: open, closed, none |
---|
435 | \define@choicekey*+[ba]{posterbox}{headerborder}% |
---|
436 | [\baposter@box@headerborder\baposter@box@headerbordernr]% |
---|
437 | {open,closed,none} [open] {% |
---|
438 | \debug{Header border: \baposter@box@headerborder} |
---|
439 | % \renewcommand{\baposterHeaderBorder}{ |
---|
440 | % \csname baposter@headerborder@\baposter@box@headerborder\endcsname} |
---|
441 | }{ |
---|
442 | \PackageWarning{baposter}{Unknown headerborder style `\baposter@headerborder'. |
---|
443 | Edit your file to choose a valid option.} |
---|
444 | % \renewcommand{\baposterHeaderBorder}{\baposter@box@headerborder@rectangle} |
---|
445 | } |
---|
446 | |
---|
447 | |
---|
448 | \define@cmdkey[ba]{posterbox}[baposter@box@]{borderColor} [yellow] {} |
---|
449 | \define@cmdkey[ba]{posterbox}[baposter@box@]{headerColorOne} [red] {} |
---|
450 | \define@cmdkey[ba]{posterbox}[baposter@box@]{headerColorTwo} [brown] {} |
---|
451 | \define@cmdkey[ba]{posterbox}[baposter@box@]{headerFontColor} [black] {} |
---|
452 | \define@cmdkey[ba]{posterbox}[baposter@box@]{boxColorOne} [magenta] {} |
---|
453 | \define@cmdkey[ba]{posterbox}[baposter@box@]{boxColorTwo} [cyan] {} |
---|
454 | \define@cmdkey[ba]{posterbox}[baposter@box@]{headerfont} [\scshape\Large] {} |
---|
455 | \define@cmdkey[ba]{posterbox}[baposter@box@]{textfont} [{}] {} |
---|
456 | \define@cmdkey[ba]{posterbox}[baposter@box@]{postertitlecolor} [black] {} |
---|
457 | |
---|
458 | |
---|
459 | \define@cmdkey[ba]{posterbox}[baposter@box@]{linewidth} [2pt] {} |
---|
460 | |
---|
461 | \define@cmdkey[ba]{posterbox}[baposter@box@]{below} [notset]{} |
---|
462 | \define@cmdkey[ba]{posterbox}[baposter@box@]{above} [notset]{} |
---|
463 | \define@cmdkey[ba]{posterbox}[baposter@box@]{aligned}[notset]{} |
---|
464 | \define@cmdkey[ba]{posterbox}[baposter@box@]{bottomaligned}[notset]{} |
---|
465 | \define@cmdkey[ba]{posterbox}[baposter@box@]{column} [0] {} |
---|
466 | \define@cmdkey[ba]{posterbox}[baposter@box@]{row} [0] {} |
---|
467 | \define@cmdkey[ba]{posterbox}[baposter@box@]{span} [1] {} |
---|
468 | \define@cmdkey[ba]{posterbox}[baposter@box@]{height} [auto] {} |
---|
469 | \define@cmdkey[ba]{posterbox}[baposter@box@]{name} [noname]{} |
---|
470 | |
---|
471 | % Set some default values, the poster and posterbox environments can override: |
---|
472 | \setkeys[ba]{poster}{ |
---|
473 | % Debug grid |
---|
474 | grid=false, |
---|
475 | % Is there an eyecatcher image |
---|
476 | eyecatcher=true, |
---|
477 | columns={}, |
---|
478 | % Colours |
---|
479 | bgColorOne=baposter@silver, |
---|
480 | bgColorTwo=green, |
---|
481 | % |
---|
482 | colspacing=1em, |
---|
483 | headerheight=0.1\textheight, |
---|
484 | background=shadeLR, |
---|
485 | }{} |
---|
486 | \setkeys[ba]{posterbox}{ |
---|
487 | % Position |
---|
488 | column=0,row=0,span=1, |
---|
489 | below=notset,above=notset, |
---|
490 | bottomaligned=notset, |
---|
491 | aligned=notset, |
---|
492 | height=auto, |
---|
493 | % Name |
---|
494 | name=noname, |
---|
495 | % Box design: border: |
---|
496 | linewidth=1pt, |
---|
497 | borderColor=yellow, |
---|
498 | cornerradius=1em, |
---|
499 | % text box: |
---|
500 | textfont={}, |
---|
501 | boxshade=plain, |
---|
502 | boxColorOne=magenta, |
---|
503 | boxColorTwo=cyan, |
---|
504 | textborder=faded, |
---|
505 | boxpadding=0.5em, |
---|
506 | % header |
---|
507 | headerfont=\scshape\Large,% or headerfont=\color{white}\textsf\textbf |
---|
508 | headerFontColor=black, |
---|
509 | headerColorOne=red, |
---|
510 | headerColorTwo=brown, |
---|
511 | headershape=rectangle, |
---|
512 | headershade=shadeLR, |
---|
513 | headerborder=none, |
---|
514 | boxheaderheight=2em, |
---|
515 | postertitlecolor=black, |
---|
516 | }{} |
---|
517 | |
---|
518 | |
---|
519 | |
---|
520 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
521 | %%% Background options and functions (one function for each possible value) |
---|
522 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
523 | |
---|
524 | \newcommand{\baposter@background@shadelr}[2]{ |
---|
525 | \debug{BAPOSTER: Using shade left right background.} |
---|
526 | \begin{tikzpicture}[remember picture,overlay]% |
---|
527 | \shade [shading=axis,left color=#1,right color=#2] (current page.north west) |
---|
528 | rectangle(current page.south east); |
---|
529 | \end{tikzpicture}% |
---|
530 | } |
---|
531 | \newcommand{\baposter@background@shadetb}[2]{ |
---|
532 | \debug{BAPOSTER: Using shade top to bottom background.} |
---|
533 | \begin{tikzpicture}[remember picture,overlay]% |
---|
534 | \shade [shading=axis,top color=#1,bottom color=#2] (current page.north west) |
---|
535 | rectangle(current page.south east); |
---|
536 | \end{tikzpicture}% |
---|
537 | } |
---|
538 | \newcommand{\baposter@background@plain}[2]{ |
---|
539 | \debug{BAPOSTER: Using plain background.} |
---|
540 | \begin{tikzpicture}[remember picture,overlay]% |
---|
541 | \fill [fill=#1] (current page.north west) rectangle(current page.south east); |
---|
542 | \end{tikzpicture}% |
---|
543 | } |
---|
544 | \newcommand{\baposter@background@user}[2]{ |
---|
545 | \debug{BAPOSTER: Using user background.} |
---|
546 | \baposter@backgroundCmd% |
---|
547 | } |
---|
548 | \newcommand{\baposter@background@none}[2]{ |
---|
549 | \debug{BAPOSTER: Using no background.} |
---|
550 | } |
---|
551 | |
---|
552 | |
---|
553 | |
---|
554 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
555 | %%% Return shape path of text box (depending on the box shape) |
---|
556 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
557 | |
---|
558 | \newcommand{\baposter@box@boxshape@none}{\baposter@box@boxshape@rectangle} |
---|
559 | \newcommand{\baposter@box@boxshape@bars}{ |
---|
560 | (\baposter@box@name tnw) -- (\baposter@box@name sw) % |
---|
561 | (\baposter@box@name se) -- (\baposter@box@name tne) |
---|
562 | } |
---|
563 | \newcommand{\baposter@box@boxshape@coils}{\baposter@box@boxshape@bars} |
---|
564 | \newcommand{\baposter@box@boxshape@triangles}{\baposter@box@boxshape@bars} |
---|
565 | \newcommand{\baposter@box@boxshape@rectangle}{ |
---|
566 | (\baposter@box@name tnw) -- (\baposter@box@name sw) -- % |
---|
567 | (\baposter@box@name se) -- (\baposter@box@name tne)% |
---|
568 | } |
---|
569 | \newcommand{\baposter@box@boxshape@faded}{ |
---|
570 | (\baposter@box@name tnw) -- (\baposter@box@name sw) % |
---|
571 | (\baposter@box@name tne) -- (\baposter@box@name se) |
---|
572 | } |
---|
573 | \newcommand{\baposter@box@boxshape@rounded}{ |
---|
574 | [rc] \baposter@box@boxshape@rectangle% |
---|
575 | } |
---|
576 | \newcommand{\baposter@box@boxshape@roundedsmall}{ |
---|
577 | [src] \baposter@box@boxshape@rectangle |
---|
578 | } |
---|
579 | \newcommand{\baposter@box@boxshape@roundedleft}{ |
---|
580 | (\baposter@box@name tnw) {[rc]-- (\baposter@box@name sw)} -- % |
---|
581 | (\baposter@box@name se) -- (\baposter@box@name tne)% |
---|
582 | } |
---|
583 | \newcommand{\baposter@box@boxshape@roundedright}{ |
---|
584 | (\baposter@box@name tnw) -- (\baposter@box@name sw) {[rc]-- % |
---|
585 | (\baposter@box@name se)} -- (\baposter@box@name tne)% |
---|
586 | } |
---|
587 | |
---|
588 | |
---|
589 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
590 | %%% Draw box background (one function for each possible value) |
---|
591 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
592 | |
---|
593 | % These functions take no arguments |
---|
594 | \newcommand{\baposter@box@drawbackground@none}[2]{ |
---|
595 | \tikzstyle{box colors}=[] |
---|
596 | } |
---|
597 | \newcommand{\baposter@box@drawbackground@plain}[2]{ |
---|
598 | \tikzstyle{box colors}=[fill=#1] |
---|
599 | \fill[box colors] \baposterBoxGetShape; |
---|
600 | } |
---|
601 | \newcommand{\baposter@box@drawbackground@shadelr}[2]{ |
---|
602 | \tikzstyle{box colors}=[shading=axis, left color=#1, right color=#2]% |
---|
603 | \fill[box colors] \baposterBoxGetShape; |
---|
604 | } |
---|
605 | \newcommand{\baposter@box@drawbackground@shadetb}[2]{ |
---|
606 | \tikzstyle{box colors}=[shading=axis, top color=#1, bottom color=#2]% |
---|
607 | \fill[box colors] \baposterBoxGetShape; |
---|
608 | } |
---|
609 | |
---|
610 | |
---|
611 | |
---|
612 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
613 | %%% Draw box border |
---|
614 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
615 | |
---|
616 | % These functions take two arguments: borderColor |
---|
617 | \newcommand{\baposter@box@drawborder@none}[1]{} |
---|
618 | \newcommand{\baposter@box@drawborder@bars}[1]{ |
---|
619 | \draw[color=#1] \baposterBoxGetShape;% |
---|
620 | } |
---|
621 | \newcommand{\baposter@box@drawborder@coils}[1]{ |
---|
622 | \draw[color=#1,segment amplitude=0.35em,segment length=0.4em,snake=coil] \baposterBoxGetShape;% |
---|
623 | } |
---|
624 | \newcommand{\baposter@box@drawborder@triangles}[1]{ |
---|
625 | \draw[color=#1,segment amplitude=0.2em,segment length=0.4em,snake=triangles] \baposterBoxGetShape;% |
---|
626 | } |
---|
627 | \newcommand{\baposter@box@drawborder@rectangle}[1]{ |
---|
628 | \draw[color=#1] \baposterBoxGetShape;% |
---|
629 | } |
---|
630 | \newcommand{\baposter@box@drawborder@rounded}[1]{ |
---|
631 | \draw[color=#1] \baposterBoxGetShape;% |
---|
632 | } |
---|
633 | \newcommand{\baposter@box@drawborder@roundedleft}[1]{ |
---|
634 | \draw[color=#1] \baposterBoxGetShape;% |
---|
635 | } |
---|
636 | \newcommand{\baposter@box@drawborder@roundedright}[1]{ |
---|
637 | \draw[color=#1] \baposterBoxGetShape;% |
---|
638 | } |
---|
639 | \newcommand{\baposter@box@drawborder@faded}[1]{ |
---|
640 | % This is the right way to do it, but it does not work with evince, and has problems during printing, so instead we do |
---|
641 | %\draw[color=#1,path fading=south] \baposterBoxGetShape;% |
---|
642 | % this |
---|
643 | \foreach \x in {0,1,...,90} \draw[color=#1!\x] ($(\baposter@box@name tnw)!{(100-\x)/100}!(\baposter@box@name sw)$) -- ($(\baposter@box@name tnw)!{(100-(\x+10))/100}!(\baposter@box@name sw)$);% |
---|
644 | \foreach \x in {0,1,...,90} \draw[color=#1!\x] ($(\baposter@box@name tne)!{(100-\x)/100}!(\baposter@box@name se)$) -- ($(\baposter@box@name tne)!{(100-(\x+10))/100}!(\baposter@box@name se)$);% |
---|
645 | } |
---|
646 | \newcommand{\baposter@box@drawborder@roundedsmall}[1]{ |
---|
647 | \draw[color=#1] \baposterBoxGetShape;% |
---|
648 | } |
---|
649 | |
---|
650 | |
---|
651 | |
---|
652 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
653 | %%% Return shape path of text box (depending on the box shape) |
---|
654 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
655 | |
---|
656 | % These functions take no arguments |
---|
657 | % TODO: For headerborder==none, use (\baposter@box@name outer tnw) instead! |
---|
658 | \newcommand{\baposter@box@headershape@rectangle}{% |
---|
659 | (\baposter@box@name tnw) -- (\baposter@box@name nw) -- % |
---|
660 | (\baposter@box@name ne) -- (\baposter@box@name tne)% |
---|
661 | } |
---|
662 | \newcommand{\baposter@box@headershape@smallrounded}{% |
---|
663 | (\baposter@box@name tnw) {[src] -- (\baposter@box@name nw) -- % |
---|
664 | (\baposter@box@name ne)} -- (\baposter@box@name tne)% |
---|
665 | } |
---|
666 | \newcommand{\baposter@box@headershape@roundedright}{% |
---|
667 | (\baposter@box@name tnw) -- (\baposter@box@name nw) {[rc] -- % |
---|
668 | (\baposter@box@name ne)} -- (\baposter@box@name tne)% |
---|
669 | } |
---|
670 | \newcommand{\baposter@box@headershape@roundedleft}{% |
---|
671 | (\baposter@box@name tnw) {[rc]-- (\baposter@box@name nw)} -- % |
---|
672 | (\baposter@box@name ne) -- (\baposter@box@name tne)% |
---|
673 | } |
---|
674 | \newcommand{\baposter@box@headershape@rounded}{% |
---|
675 | (\baposter@box@name tnw) {[rc] -- (\baposter@box@name nw) -- % |
---|
676 | (\baposter@box@name ne) } -- (\baposter@box@name tne)% |
---|
677 | } |
---|
678 | |
---|
679 | |
---|
680 | |
---|
681 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
682 | %%% Header text drawing (one function for each possible value of headershape) |
---|
683 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
684 | |
---|
685 | % These functions take one argument: the header text |
---|
686 | \newcommand{\baposter@box@headerdrawtext@rectangle}[1]{ |
---|
687 | \path (\baposter@box@name nw) +(0em,-0.5\baposter@box@@boxheaderheight) node[anchor=west,inner sep=0.4em] {#1};% |
---|
688 | } |
---|
689 | \newcommand{\baposter@box@headerdrawtext@smallrounded}[1]{ |
---|
690 | \path (\baposter@box@name nw) +(0.5\boxwidth,-0.5\baposter@box@@boxheaderheight) node[anchor=center] {#1};% |
---|
691 | } |
---|
692 | \newcommand{\baposter@box@headerdrawtext@roundedright}[1]{ |
---|
693 | \path (\baposter@box@name nw) +(0em,-0.5\baposter@box@@boxheaderheight)% |
---|
694 | node[anchor=west,inner sep=0.4em,text depth=0.0em] {#1};% |
---|
695 | } |
---|
696 | \newcommand{\baposter@box@headerdrawtext@roundedleft}[1]{ |
---|
697 | \path (\baposter@box@name nw) +(0em,-0.5\baposter@box@@boxheaderheight)% |
---|
698 | node[anchor=west,inner sep=0.4em] {#1};% |
---|
699 | } |
---|
700 | \newcommand{\baposter@box@headerdrawtext@rounded}[1]{ |
---|
701 | \path (\baposter@box@name nw) +(0.5\boxwidth,-0.5\baposter@box@@boxheaderheight) node[anchor=center] {#1};% |
---|
702 | } |
---|
703 | |
---|
704 | |
---|
705 | |
---|
706 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
707 | %%% Header shade options and functions (one function for each possible value) |
---|
708 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
709 | |
---|
710 | % These functions take two arguments: , headerColorTwo and borderColor |
---|
711 | \newcommand{\baposter@box@headershade@shadelr}[3]{ |
---|
712 | \debug{Header-Shade: Shade Left - Right} |
---|
713 | \tikzstyle{header colors}=[% |
---|
714 | color=#3,% |
---|
715 | shading=axis,% |
---|
716 | left color=#1,% |
---|
717 | right color=#2% |
---|
718 | ]% |
---|
719 | } |
---|
720 | \newcommand{\baposter@box@headershade@shadetb}[3]{ |
---|
721 | \debug{Header-Shade: Shade Top - Bottom} |
---|
722 | \tikzstyle{header colors}=[% |
---|
723 | color=#3,% |
---|
724 | shading=axis,% |
---|
725 | top color=#1,% |
---|
726 | bottom color=#2% |
---|
727 | ]% |
---|
728 | } |
---|
729 | \newcommand{\baposter@box@headershade@shadetbinverse}[3]{ |
---|
730 | \tikzstyle{header colors}=[% |
---|
731 | top color=#1!75!#2,% |
---|
732 | bottom color=#2!100!#1,% |
---|
733 | shading angle=20% |
---|
734 | ]% |
---|
735 | \colorlet{baposterHeaderFontColor}{white}% |
---|
736 | } |
---|
737 | \newcommand{\baposter@box@headershade@plain}[3]{ |
---|
738 | \debug{Header-Shade: Plain} |
---|
739 | \tikzstyle{header colors}=[% |
---|
740 | color=#3,% |
---|
741 | fill=#1% |
---|
742 | ]% |
---|
743 | } |
---|
744 | \newcommand{\baposter@box@headershade@none}[3]{ |
---|
745 | \debug{Header-Shade: none} |
---|
746 | \tikzstyle{header colors}=[] |
---|
747 | } |
---|
748 | |
---|
749 | |
---|
750 | |
---|
751 | |
---|
752 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
753 | %%% The main poster environment |
---|
754 | %%% \begin{baposter}{settings}{Eye Catcher}{Title}{Author}{University Logo} |
---|
755 | %%%----------------------------------------------------------------------------- |
---|
756 | %%% The settings are |
---|
757 | %%% - grid=true,[false]:Show grid to help with alignment |
---|
758 | %%% - colspacing=0.7em: Column spacing |
---|
759 | %%% - columns=4: number of columns (default 4 in landscape and 3 in portrait format) (maximum number is 6) |
---|
760 | %%% - color=[orange]: xcolor color definition used as the main color of the poster |
---|
761 | %%% - colortwo=[white]: The other color for gradient based layouts |
---|
762 | %%% - textborder=none,bars,coils,triangles,rectangle,rounded,roundedsmall,roundedleft,roundedright,[faded] |
---|
763 | %%% The style of the box around the text area |
---|
764 | %%% - headerborder=none,closed,open |
---|
765 | %%% No extra border around box header, full border around box header or border that is open below. |
---|
766 | %%% - headershape=rectangle,rounded,roundedleft,roundedright |
---|
767 | %%% Shape of the box-header region |
---|
768 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
769 | \newenvironment{poster}[5]{% |
---|
770 | \thispagestyle{empty}% Suppress Page Number |
---|
771 | \debug{Poster Starts}% |
---|
772 | % This setkeys call parses all provided options and depending on the option |
---|
773 | % value, assigns different handler functions to the \baposter(Box|Header)* |
---|
774 | % functions. Once that is done, we don't have to care about particular |
---|
775 | % values for border, shading, etc. All we have to do is call the |
---|
776 | % handler functions and let them do their job. |
---|
777 | % This also allows the user to override the poster-wide defaults on a per-box |
---|
778 | % basis. |
---|
779 | \setkeys[ba]{posterbox,poster}{#1}% |
---|
780 | % |
---|
781 | % TODO: Move all those assignments to the key macros! |
---|
782 | % Parse Keys% |
---|
783 | \colorlet{bgColorOne}{\baposter@bgColorOne} |
---|
784 | \colorlet{bgColorTwo}{\baposter@bgColorTwo} |
---|
785 | % |
---|
786 | %% Boxes% |
---|
787 | \setlength{\headerheight}{\baposter@headerheight}% |
---|
788 | \setlength{\colheight}{\textheight-\baposter@headerheight}% |
---|
789 | \renewcommand{\@@previousbox}{notset} |
---|
790 | |
---|
791 | \debug{Format}% |
---|
792 | % Set default for columns if unset (4 for landscape, 3 for portrait) |
---|
793 | \ifthenelse{\equal{\baposter@columns}{}}{% |
---|
794 | \renewcommand{\baposter@columns}{\if@landscape4\else3\fi}% |
---|
795 | }{} |
---|
796 | % |
---|
797 | \debug{Columns: \baposter@columns}% |
---|
798 | \setlength{\baposter@@colspacing}{\baposter@colspacing}% |
---|
799 | \setlength{\colwidth}{\textwidth}% |
---|
800 | \addtolength{\colwidth}{\baposter@@colspacing*(1-\baposter@columns)}% |
---|
801 | \ifcase\baposter@columns\relax |
---|
802 | \error{You need to have at least one column!} |
---|
803 | \or % 1 |
---|
804 | \setlength{\colwidth}{\colwidth}% |
---|
805 | \or % 2 |
---|
806 | \setlength{\colwidth}{0.5\colwidth}% |
---|
807 | \or % 3 |
---|
808 | \setlength{\colwidth}{0.3333333333333\colwidth}% |
---|
809 | \or % 4 |
---|
810 | \setlength{\colwidth}{0.25\colwidth}% |
---|
811 | \or % 5 |
---|
812 | \setlength{\colwidth}{0.2\colwidth}% |
---|
813 | \or % 6 |
---|
814 | \setlength{\colwidth}{0.16666666666\colwidth}% |
---|
815 | \else % >6 |
---|
816 | \error{You do not want so many columns} |
---|
817 | \fi |
---|
818 | % |
---|
819 | \newcommand{\baposter@reference}{north west}% |
---|
820 | % |
---|
821 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
822 | % A box with a header and some content. The basic unit of the poster% |
---|
823 | %---------------------------------------------------------------------------% |
---|
824 | % Each box has a name and can be placed absolutely or relatively.% |
---|
825 | % The only inconvenience is that you can only specify a relative position % |
---|
826 | % towards an already declared box. So if you have a box attached to the % |
---|
827 | % bottom, one to the top and a third one which should be inbetween, you % |
---|
828 | % have to specify the top and bottom boxes before you specify the middle % |
---|
829 | % box.% |
---|
830 | %% |
---|
831 | % below= name of other node% |
---|
832 | % above= name of other node% |
---|
833 | % aligned=name of other node% |
---|
834 | % bottomaligned=name of other node% |
---|
835 | % column= [0] % |
---|
836 | % row= [0] % |
---|
837 | % span= [1] % |
---|
838 | % height= <size in percent of column height>,[auto]% |
---|
839 | % name= [noname]% |
---|
840 | %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% |
---|
841 | |
---|
842 | % Backward-compatibility definition (\headerbox command uses posterbox env): |
---|
843 | \newcommand{\headerbox}[3]{% |
---|
844 | \begin{posterbox}[##2]{##1} |
---|
845 | ##3 |
---|
846 | \end{posterbox} |
---|
847 | } |
---|
848 | |
---|
849 | \newenvironment{posterbox}[2][]{% |
---|
850 | \debug{Poster box options: ##1}% |
---|
851 | % Override the poster-wide defaults on a per-box basis |
---|
852 | \setkeys[ba]{posterbox}{##1}% |
---|
853 | % |
---|
854 | \def\baposter@box@title{##2} |
---|
855 | % |
---|
856 | \colorlet{borderColor}{\baposter@box@borderColor} |
---|
857 | \colorlet{headerColorOne}{\baposter@box@headerColorOne} |
---|
858 | \colorlet{headerColorTwo}{\baposter@box@headerColorTwo} |
---|
859 | \colorlet{headerFontColor}{\baposter@box@headerFontColor} |
---|
860 | \colorlet{boxColorOne}{\baposter@box@boxColorOne} |
---|
861 | \colorlet{boxColorTwo}{\baposter@box@boxColorTwo} |
---|
862 | % |
---|
863 | \setlength{\baposter@box@@cornerradius}{\baposter@box@cornerradius}% |
---|
864 | \setlength{\baposter@box@@boxheaderheight}{\baposter@box@boxheaderheight}% |
---|
865 | \setlength{\baposter@box@@boxpadding}{\baposter@box@boxpadding}% |
---|
866 | |
---|
867 | |
---|
868 | %% The columns is always given absolute |
---|
869 | % boxstartx = column * colwidth + column * colspacing |
---|
870 | \setlength{\boxstartx}{(\colwidth+\baposter@@colspacing)*\baposter@box@column}% |
---|
871 | % |
---|
872 | %% The width is gvien absolute |
---|
873 | % Box Width = span * colwidth + (span-1) * colspacing |
---|
874 | \setlength{\boxwidth}{\baposter@box@span\colwidth} % |
---|
875 | \addtolength{\boxwidth}{\baposter@@colspacing*(\baposter@box@span-1)}% |
---|
876 | % |
---|
877 | %% Measure the content of the box% |
---|
878 | \setbox\baposter@box@content=\hbox\bgroup% |
---|
879 | \begin{pgfinterruptpicture}% |
---|
880 | \begin{minipage}[t]{\boxwidth-\baposter@box@@boxpadding*2}% |
---|
881 | \baposter@box@textfont\bgroup% |
---|
882 | }% End of posterbox preamble |
---|
883 | %%% HERE COME THE ACTUAL CONTENTS OF THE HEADERBOX ENVIRONMENT |
---|
884 | {% posterbox handling after contents (i.e. drawing everything) |
---|
885 | \egroup% |
---|
886 | \end{minipage}% |
---|
887 | \end{pgfinterruptpicture}% |
---|
888 | \egroup% |
---|
889 | \setlength{\boxheight}{\ht\baposter@box@content}% |
---|
890 | \addtolength{\boxheight}{\dp\baposter@box@content}% |
---|
891 | \addtolength{\boxheight}{\baposter@box@@boxheaderheight} % Header% |
---|
892 | \addtolength{\boxheight}{2\baposter@box@@boxpadding} % Inner Sep |
---|
893 | % |
---|
894 | \ifthenelse{\equal{\baposter@box@height}{bottom}}{% |
---|
895 | }{\ifthenelse{\equal{\baposter@box@height}{auto}}{% |
---|
896 | }{ % Neither auto nor bottom% |
---|
897 | \setlength{\boxheight}{\baposter@box@height\colheight}% |
---|
898 | }}% |
---|
899 | % |
---|
900 | %% Determine the box position% |
---|
901 | \debug{Setting Coordinates}% |
---|
902 | \debug{Upper Right}% |
---|
903 | \debug{\baposter@box@name}% |
---|
904 | % |
---|
905 | %%% Upper Right Corner% |
---|
906 | % if below=auto, set it to the previous box |
---|
907 | % TODO: We should generalize this to the previous box of the used column, |
---|
908 | % currently we use the previous box, which might be in a different column |
---|
909 | \ifthenelse{\equal{\baposter@box@below}{auto}}{% |
---|
910 | \edef\baposter@box@below{\@@previousbox} |
---|
911 | \debug{Box \baposter@box@name has below=auto, placing it below box \baposter@box@below.} |
---|
912 | }{} |
---|
913 | \xdef\@@previousbox{\baposter@box@name} |
---|
914 | |
---|
915 | \ifthenelse{\not\equal{\baposter@box@below}{notset} }{% |
---|
916 | %% Below% |
---|
917 | \debug{Below}% |
---|
918 | \path[shape=coordinate] (\boxstartx,0pt |- \baposter@box@below se) ++(0pt,-\baposter@@colspacing) coordinate(\baposter@box@name nw);% |
---|
919 | }{% |
---|
920 | \ifthenelse{\not\equal{\baposter@box@aligned}{notset} }{% |
---|
921 | %% Aligned% |
---|
922 | \debug{Aligned: \baposter@box@aligned}% |
---|
923 | \path[shape=coordinate] (\boxstartx,0pt |- \baposter@box@aligned nw) coordinate(\baposter@box@name nw);% |
---|
924 | }{% |
---|
925 | %% Fixed% |
---|
926 | \debug{Fixed}% |
---|
927 | \setlength{\boxstarty}{\baposter@box@row\colheight}% |
---|
928 | \path[shape=coordinate] (\boxstartx,\colheight-\boxstarty) coordinate(\baposter@box@name nw);% |
---|
929 | }}% |
---|
930 | % |
---|
931 | %% Lower Left Corner% |
---|
932 | \debug{Lower Left}% |
---|
933 | \ifthenelse{\equal{\baposter@box@above}{bottom}}{% |
---|
934 | %% Above = Bottom% |
---|
935 | \debug{Above bottom}% |
---|
936 | \ifthenelse{\equal{\baposter@box@below}{notset} \and \equal{\baposter@box@aligned}{notset}}{% |
---|
937 | \path[shape=coordinate] (\boxstartx,\boxheight) coordinate(\baposter@box@name nw);% |
---|
938 | }{}% |
---|
939 | \path[shape=coordinate] (\boxstartx+\boxwidth,0pt) coordinate(\baposter@box@name se);% |
---|
940 | }{\ifthenelse{\not \equal{\baposter@box@bottomaligned}{notset}}{% |
---|
941 | \path[shape=coordinate] (\boxstartx+\boxwidth,0pt |- \baposter@box@bottomaligned se) coordinate(\baposter@box@name se);% |
---|
942 | }{{\ifthenelse{\not \equal{\baposter@box@above}{notset}}{% |
---|
943 | %% Above = Node% |
---|
944 | \path[shape=coordinate] (\boxstartx+\boxwidth,0pt |- \baposter@box@above nw) +(0pt,\baposter@@colspacing) coordinate(\baposter@box@name se);% |
---|
945 | }{% |
---|
946 | %% Above = notset% |
---|
947 | \debug{Above=not set}% |
---|
948 | \ifthenelse{\equal{\baposter@box@height}{bottom}}{% |
---|
949 | %% height=bottom% |
---|
950 | \debug{height=bottom}% |
---|
951 | \path[shape=coordinate] (\boxstartx+\boxwidth,0pt) coordinate(\baposter@box@name se);% |
---|
952 | }{ %% height=auto or fixed% |
---|
953 | \debug{height=auto or fixed}% |
---|
954 | \path[shape=coordinate] (\baposter@box@name nw) ++(\boxwidth,-\boxheight) coordinate(\baposter@box@name se);% |
---|
955 | }}}}}% |
---|
956 | % |
---|
957 | % |
---|
958 | % Set coordinates relative to nw,se% |
---|
959 | \debug{Fixing Coordinates}% |
---|
960 | \path[shape=coordinate]% |
---|
961 | (\baposter@box@name nw) +(0pt,-\baposter@box@@boxheaderheight) coordinate(\baposter@box@name tnw)% |
---|
962 | (\baposter@box@name nw |- \baposter@box@name se) coordinate(\baposter@box@name sw)% |
---|
963 | (\baposter@box@name se |- \baposter@box@name nw) coordinate(\baposter@box@name ne)% |
---|
964 | (\baposter@box@name ne) +(0pt,-\baposter@box@@boxheaderheight) coordinate(\baposter@box@name tne)% |
---|
965 | % |
---|
966 | (\baposter@box@name nw) +(-0.025em,0pt) coordinate(\baposter@box@name outer nw)% |
---|
967 | (\baposter@box@name tnw) +(-0.025em,0pt) coordinate(\baposter@box@name outer tnw)% |
---|
968 | (\baposter@box@name sw) +(-0.025em,0pt) coordinate(\baposter@box@name outer sw)% |
---|
969 | % |
---|
970 | (\baposter@box@name ne) +( 0.025em,0pt) coordinate(\baposter@box@name outer ne)% |
---|
971 | (\baposter@box@name tne) +( 0.025em,0pt) coordinate(\baposter@box@name outer tne)% |
---|
972 | (\baposter@box@name se) +( 0.025em,0pt) coordinate(\baposter@box@name outer se);% |
---|
973 | % |
---|
974 | %% Setting the bg colors of the box header |
---|
975 | \baposterHeaderSetShade{headerColorOne}{headerColorTwo}{borderColor} |
---|
976 | % |
---|
977 | \tikzstyle{rc}=[rounded corners=\baposter@box@@cornerradius];% |
---|
978 | \tikzstyle{src}=[rounded corners=0.5em];% |
---|
979 | % |
---|
980 | |
---|
981 | %% Now that everything is set up, draw the actual box, with bg and header |
---|
982 | \begin{scope}[line width=\baposter@box@linewidth] |
---|
983 | %% Header% |
---|
984 | \debug{Header}% |
---|
985 | \debug{Header-Shape: \baposter@box@headershape, header-border: \baposter@box@headerborder (\baposter@box@headerbordernr)}% |
---|
986 | % TODO: Also turn this last ifcase construct into a handler function |
---|
987 | % We only need to determine (fill|shade)(draw|)... |
---|
988 | % \baposterHeaderDrawBackground{bgColorOne}{bgColorTwo}{borderColor} |
---|
989 | % \baposterHeaderDrawBorder{borderColor} |
---|
990 | \ifcase\baposter@box@headerbordernr\relax% |
---|
991 | % open |
---|
992 | \ifthenelse{\equal{\baposter@box@headershade}{plain}}{ |
---|
993 | \filldraw [style=header colors] \baposterHeaderGetShape;% |
---|
994 | }{ |
---|
995 | \shadedraw [style=header colors] \baposterHeaderGetShape;% |
---|
996 | } |
---|
997 | \or |
---|
998 | % closed |
---|
999 | \ifthenelse{\equal{\baposter@box@headershade}{plain}}{ |
---|
1000 | \filldraw [style=header colors] \baposterHeaderGetShape -- cycle;% |
---|
1001 | }{ |
---|
1002 | \shadedraw [style=header colors] \baposterHeaderGetShape -- cycle;% |
---|
1003 | } |
---|
1004 | \or |
---|
1005 | % none |
---|
1006 | \ifthenelse{\equal{\baposter@box@headershade}{plain}}{ |
---|
1007 | \fill [style=header colors] \baposterHeaderGetShape;% |
---|
1008 | }{ |
---|
1009 | \shade [style=header colors] \baposterHeaderGetShape;% |
---|
1010 | } |
---|
1011 | \fi |
---|
1012 | % |
---|
1013 | %% Draw the text inside the box header: |
---|
1014 | \baposterHeaderDrawText{\color{headerFontColor}\baposter@box@headerfont{\baposter@box@title}};% |
---|
1015 | % |
---|
1016 | %% Text borders (border around boxes) |
---|
1017 | \debug{Poster boxes}% |
---|
1018 | % First set box shade |
---|
1019 | \baposterBoxDrawBackground{boxColorOne}{boxColorTwo} |
---|
1020 | \baposterBoxDrawBorder{borderColor} |
---|
1021 | %% |
---|
1022 | %% Text Box% |
---|
1023 | \debug{Drawing Text}% |
---|
1024 | \path (\baposter@box@name tnw) node(text) [anchor=north west, |
---|
1025 | outer sep=-0.000em,text width=\boxwidth-2\baposter@box@@boxpadding,inner sep=\baposter@box@@boxpadding, |
---|
1026 | text justified] {\usebox{\baposter@box@content}};% |
---|
1027 | \end{scope} |
---|
1028 | % |
---|
1029 | % Finally store the box name as the previous box for the next call |
---|
1030 | % \xdef\@@previousbox{\baposter@box@name}% |
---|
1031 | }% END of posterbox definition |
---|
1032 | % |
---|
1033 | %% Poster Background% |
---|
1034 | \baposterPosterDrawBackground{bgColorOne}{bgColorTwo}% |
---|
1035 | %% Poster header/title |
---|
1036 | \colorlet{postertitlecolor}{\baposter@box@postertitlecolor} |
---|
1037 | \hspace{-1.5em}% |
---|
1038 | \begin{tikzpicture}[inner sep=0pt,outer sep=0pt,line width=0.05em]% |
---|
1039 | \useasboundingbox (0em,0em) rectangle(\textwidth,\textheight);% |
---|
1040 | \path[shape=coordinate]% |
---|
1041 | (0pt,\colheight) coordinate(north west) (\textwidth,\colheight) coordinate(north east)% |
---|
1042 | (0pt,0pt) coordinate(south west) (\textwidth,0pt) coordinate(south east);% |
---|
1043 | % |
---|
1044 | \ifbaposter@eyecatcher% Has eye catcher |
---|
1045 | \debug{Eyecatcher found!} |
---|
1046 | \setbox\baposter@titleimage@left=\hbox{#2}% |
---|
1047 | %\setbox\baposter@title@top=\hbox{#3}% |
---|
1048 | \else% Has no eye catcher% |
---|
1049 | \setbox\baposter@titleimage@left=\hbox{}% |
---|
1050 | \fi% |
---|
1051 | \setlength{\baposter@titleimage@left@width}{\wd\baposter@titleimage@left}% |
---|
1052 | \setbox\baposter@titleimage@right=\hbox{#5}% |
---|
1053 | \setlength{\baposter@titleimage@right@width}{\wd\baposter@titleimage@right}% |
---|
1054 | \setlength{\baposter@titleimage@right@height}{\ht\baposter@titleimage@right}% |
---|
1055 | \setlength{\baposter@titleimage@textwidth}{\textwidth}% |
---|
1056 | \addtolength{\baposter@titleimage@textwidth}{-\baposter@titleimage@left@width}% |
---|
1057 | %\addtolength{\baposter@titleimage@textwidth}{-\baposter@titleimage@right@width}% |
---|
1058 | |
---|
1059 | \debug{#3} |
---|
1060 | % |
---|
1061 | % |
---|
1062 | % % Draw Header% |
---|
1063 | \draw (north west) +(0em,1em+0.5\headerheight) node(image)[anchor=west] { {\usebox{\baposter@titleimage@left }} };% |
---|
1064 | \draw (north east) +(0em,1em+0.5\baposter@titleimage@right@height) node(logo) [anchor=east] { {\usebox{\baposter@titleimage@right}} };% |
---|
1065 | % |
---|
1066 | \ifbaposter@eyecatcher% Has eye catcher% |
---|
1067 | \draw (image.east) node(title)[anchor=west,text width=\baposter@titleimage@textwidth]{% |
---|
1068 | \begin{minipage}{\baposter@titleimage@textwidth}% |
---|
1069 | \begin{center}% |
---|
1070 | \textcolor{postertitlecolor}{\textbf{\Huge #3}}\\% |
---|
1071 | {\raggedright\Large #4}% |
---|
1072 | \end{center}% |
---|
1073 | \end{minipage} |
---|
1074 | };% |
---|
1075 | \else% Has no eye catcher |
---|
1076 | \draw (image.east) node(title)[anchor=west] { {\begin{minipage}{\baposter@titleimage@textwidth} |
---|
1077 | {\textcolor{postertitlecolor}{\bfseries\Huge #3}}\\{\Large #4}\end{minipage}} };% |
---|
1078 | \fi |
---|
1079 | }% END poster begin |
---|
1080 | % The body |
---|
1081 | {% BEGIN poster end |
---|
1082 | % The end, draw gridlines if neccesary |
---|
1083 | \ifbaposter@grid |
---|
1084 | \newdimen{\gridpos} |
---|
1085 | \pgfmathsetmacro{\z}{\baposter@columns-1} |
---|
1086 | \foreach \y in {0,...,\z} |
---|
1087 | { |
---|
1088 | \setlength{\gridpos}{\y\colwidth+\y\baposter@@colspacing} |
---|
1089 | \draw[draw=green,draw opacity=0.7] (\gridpos,0pt) -- (\gridpos,\colheight) |
---|
1090 | (\gridpos+\colwidth,0pt) -- (\gridpos+\colwidth,\colheight);% |
---|
1091 | } |
---|
1092 | % Horizontal lines, every 0.1: |
---|
1093 | %% Explicitly list all percentages, because with {0.0, 0.1, ..., 1.0} we |
---|
1094 | %% get rounding errors in the displayed numbers! |
---|
1095 | \foreach \y in {0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 1.0} |
---|
1096 | \draw[draw=green,draw opacity=0.7] (0pt,\colheight-\y\colheight) -- |
---|
1097 | (\textwidth,\colheight-\y\colheight) node[anchor=west] {\y};% |
---|
1098 | \fi% |
---|
1099 | \end{tikzpicture}% |
---|
1100 | % \xkvview{} |
---|
1101 | \par |
---|
1102 | }% END poster end |
---|