% datcard.sty: LaTeX style file for printing DAT J-cards. % % Written by: Kurt Swanson (kurt@dna.lth.se) % Requires: LaTeX epic and eepic styles. % Version: 1.0, February 25, 1994 % Completely uncopyrighted. Just try & make money off it! % % Defines a LaTeX picture environment "dat-card" that accepts macros % for tape title and list of songs. Self-explanatory - see example at % the end of this file. \typeout{Datcard macros - Released 25 February 1994} % Define the standard 3 fonts. See exmaple to use other fonts. \font\dfsml=cmr8 \font\dfmed=cmr10 \font\dfbig=cmr12 % Internal macros % --------------- % How to number \def\dnum#1{\makebox[3ex][r]{#1.}} % How to write time codes \def\dtime#1#2{\put(70,#1){\dfsml\hspace{-7ex}\makebox[7ex][r]{#2}}} % Where to put text lines \def\dtextline#1{\ifcase#1\or 103.8\or 100.2\or 96.6\or 93.0\or 89.4\or 85.8\or 82.2\or 78.6\or 75.0\or 71.4\or 67.8\or 64.2\or 60.6\or 57.0\or 53.4\or 50.0\or 46.4\or 42.8\or 39.2\or 35.6\or 32.0\or 28.4\or 24.8\or 21.2\or 17.6\or 14.0\or 10.4\or 6.8\or 3.2\or 0.4\or -3.2\or -6.8\or -10.4\or -14.0\or -17.6\or -21.2\or -24.8\or -28.4\or -32.0\or -35.6\or -39.2\or -42.8\or -46.4\or -50\or 129.3\or 125.7\or 122.1\or 119.4\fi} % External macros % --------------- % Tape title, two lines \def\twotitle#1#2{\dottedline{1}(-1,113)(70,113) \put(.5,114.2){\dfbig #1} \put(.5,108.2){\dfbig #2}} % Tape title, three lines \def\threetitle#1#2#3{\dottedline{1}(-1,111)(70,111) \dottedline{1}(-1,115)(70,115) \put(.5,115.6){\dfmed #1} \put(.5,111.6){\dfmed #2} \put(.5,107.6){\dfmed #3}} % Unadorned song \def\song#1#2{\put(.5,\dtextline{#1}){\dfsml #2}} % Numbered song \def\numsong#1#2{\put(.5,\dtextline{#1}){\dfsml \dnum{#1} #2}} % Song with timestamp \def\timesong#1#2#3{\put(.5,\dtextline{#1}){\dfsml #2}\dtime{\dtextline{#1}}{#3}} % Numbered song with timestamp \def\numtimesong#1#2#3{\put(.5,\dtextline{#1}){\dfsml \dnum{#1} #2}\dtime{\dtextline{#1}}{#3}} % LaTeX environment, draws all lines. \newenvironment{dat-card}{\setlength{\unitlength}{1mm} \begin{picture}(72,184)(0,-52) \thinlines \path(72,-52)(72,132)(0,132)(0,-52)(72,-52) \path(0,119)(72,119) \path(0,107)(72,107) \path(0,53)(72,53) \path(0,0)(72,0) \allinethickness{.1pt} % "Page" 1 Lines \dottedline{1}(-1,103.6)(70,103.6) \dottedline{1}(-1,100.0)(70,100.0) \dottedline{1}(-1,96.4)(70,96.4) \dottedline{1}(-1,92.8)(70,92.8) \dottedline{1}(-1,89.2)(70,89.2) \dottedline{1}(-1,85.6)(70,85.6) \dottedline{1}(-1,82.0)(70,82.0) \dottedline{1}(-1,78.4)(70,78.4) \dottedline{1}(-1,74.8)(70,74.8) \dottedline{1}(-1,71.2)(70,71.2) \dottedline{1}(-1,67.6)(70,67.6) \dottedline{1}(-1,64.0)(70,64.0) \dottedline{1}(-1,60.4)(70,60.4) \dottedline{1}(-1,56.8)(70,56.8) % "Page" 2 Lines \dottedline{1}(-1,49.8)(70,49.8) \dottedline{1}(-1,46.2)(70,46.2) \dottedline{1}(-1,42.6)(70,42.6) \dottedline{1}(-1,39.0)(70,39.0) \dottedline{1}(-1,35.4)(70,35.4) \dottedline{1}(-1,31.8)(70,31.8) \dottedline{1}(-1,28.2)(70,28.2) \dottedline{1}(-1,24.6)(70,24.6) \dottedline{1}(-1,21.0)(70,21.0) \dottedline{1}(-1,17.4)(70,17.4) \dottedline{1}(-1,13.8)(70,13.8) \dottedline{1}(-1,10.2)(70,10.2) \dottedline{1}(-1,6.6)(70,6.6) \dottedline{1}(-1,3.0)(70,3.0) % "Page" 3 Lines \dottedline{1}(-1,-3.4)(70,-3.4) \dottedline{1}(-1,-7.0)(70,-7.0) \dottedline{1}(-1,-10.6)(70,-10.6) \dottedline{1}(-1,-14.2)(70,-14.2) \dottedline{1}(-1,-17.8)(70,-17.8) \dottedline{1}(-1,-21.4)(70,-21.4) \dottedline{1}(-1,-25.0)(70,-25.0) \dottedline{1}(-1,-28.6)(70,-28.6) \dottedline{1}(-1,-32.2)(70,-32.2) \dottedline{1}(-1,-35.8)(70,-35.8) \dottedline{1}(-1,-39.4)(70,-39.4) \dottedline{1}(-1,-43.0)(70,-43.0) \dottedline{1}(-1,-46.6)(70,-46.6) % "Page" Short Lines \dottedline{1}(-1,129.1)(70,129.1) \dottedline{1}(-1,125.5)(70,125.5) \dottedline{1}(-1,121.9)(70,121.9) }{\end{picture}} % Example %\documentstyle[epic,eepic,datcard]{article} %% Don't like cmr use Postscript Weiss instead. %\font\dfsml=pwsr at 8pt %\font\dfmed=pwsr at 10pt %\font\dfbig=pwsr at 12pt % %\begin{document} %\begin{dat-card} % \twotitle{The DAT-Boys}{~~~Copyright Violations} % \song{1}{Scms blues} % \numsong{2}{SPDIF Shuffle} % \timesong{3}{The Start-ID Swing}{12:15} % \numtimesong{24}{Num-Time-song 24}{2:23:34} %\end{dat-card} %\end{document}