From: Jeff R. <je...@jr...> - 2007-03-14 00:29:27
|
Hi Everyone I modified my latex file to print cheques in the new format required starting this spring in Canada. Everything seems to work as long as I am only paying one invoice. If I pay two or three invoices the extra lines printed in the top third of the page push the information down in the cheque body. If I pay one invoice everything lines up, if i pay two then the cheque body is down a line, by the time i try to pay three cheques all at once the cheque information is totally out of place. I tried to find out how to correct this by reading my copy of "The not so short introduction to Latex" but couldn't figure it out. I think it may have to do with boxes? Here is my cheque code: /*\documentclass{scrartcl} \usepackage[latin1]{inputenc} \usepackage{tabularx} \usepackage[letterpaper,top=2cm,bottom=-3cm,left=2.25cm,right=2cm]{geometry} \usepackage{graphicx} \begin{document} \pagestyle{myheadings} \thispagestyle{empty} \fontfamily{cmss}\fontsize{12pt}{12pt}\selectfont <%company%> \vspace{0.5cm} <%name%> \hfill <%datepaid%> \hfill <%source%> \vspace{0.5cm} \begin{tabularx}{\textwidth}{lXrr@{}} \textbf{Invoice \#} & \textbf{Invoice Date} & \textbf{Amount Due} & \textbf{Applied} \\ <%foreach invnumber%> <%invnumber%> & <%invdate%> \dotfill & <%due%> & <%paid%> \\ <%end invnumber%> \end{tabularx} \vspace{1cm} \text{Memo: } \ <%memo%> \vspace*{3.5cm} \hfill <%source%> \vspace*{.75cm} \hfill <%datepaid%> \vspace*{1.75cm} <%text_amount%> \dotfill <%decimal%>/100 \makebox[4cm]{\hfill} % \hfill <%datepaid%> \makebox[2cm]{\hfill} <%amount%> \hfill <%amount%> \makebox[1cm]{\hfill} % different date format for datepaid % <%DD%><%MM%><%YYYY%> %\vspace{0.25cm} <%name%> <%address1%> <%address2%> <%city%> <%if state%> \hspace{-0.1cm}, <%state%> <%end state%> <%zipcode%> <%country%> \vspace{0.25cm} <%memo%> \vfill \end{document} */ Thanks in advance Jeff Roberts /* */ |
From: C. D. H. <Du...@Du...> - 2007-03-14 03:02:58
|
Jeff Roberts wrote: > Hi Everyone > > I modified my latex file to print cheques in the new format required > starting this spring in Canada. Everything seems to work as long as I am > only paying one invoice. If I pay two or three invoices the extra lines > printed in the top third of the page push the information down in the > cheque body. If I pay one invoice everything lines up, if i pay two then > the cheque body is down a line, by the time i try to pay three cheques > all at once the cheque information is totally out of place. > > I tried to find out how to correct this by reading my copy of "The not > so short introduction to Latex" but couldn't figure it out. I think it > may have to do with boxes? > > Here is my cheque code: > > /*\documentclass{scrartcl} > \usepackage[latin1]{inputenc} > \usepackage{tabularx} > \usepackage[letterpaper,top=2cm,bottom=-3cm,left=2.25cm,right=2cm]{geometry} > \usepackage{graphicx} > > \begin{document} > > \pagestyle{myheadings} > \thispagestyle{empty} > > \fontfamily{cmss}\fontsize{12pt}{12pt}\selectfont > > <%company%> > > \vspace{0.5cm} > > <%name%> \hfill <%datepaid%> \hfill <%source%> > > \vspace{0.5cm} > \begin{tabularx}{\textwidth}{lXrr@{}} > \textbf{Invoice \#} & \textbf{Invoice Date} > & \textbf{Amount Due} & \textbf{Applied} \\ > <%foreach invnumber%> > <%invnumber%> & <%invdate%> \dotfill > & <%due%> & <%paid%> \\ > <%end invnumber%> > \end{tabularx} > > \vspace{1cm} > > \text{Memo: } \ > <%memo%> > > \vspace*{3.5cm} > > \hfill <%source%> > > \vspace*{.75cm} > > \hfill <%datepaid%> > > \vspace*{1.75cm} > > <%text_amount%> \dotfill <%decimal%>/100 \makebox[4cm]{\hfill} > > % \hfill <%datepaid%> \makebox[2cm]{\hfill} <%amount%> > > \hfill <%amount%> \makebox[1cm]{\hfill} > > % different date format for datepaid > % <%DD%><%MM%><%YYYY%> > > %\vspace{0.25cm} > > <%name%> > > <%address1%> > <%address2%> > > <%city%> > <%if state%> > \hspace{-0.1cm}, <%state%> > <%end state%> > <%zipcode%> > > <%country%> > > \vspace{0.25cm} > > <%memo%> > > \vfill > > \end{document} > */ > Thanks in advance > > Jeff Roberts > Jeff - There's always a million ways to skin a cat, but we found the easiest way to handle this specific problem was with the Latex tabularx package. We use 3 part checks, with the actual check in the middle. We're limited to 20 invoices / check, but other then that it works like a charm. Drop me a line off list if you'd like to take a look at what we did. Dunc |
From: Jigme D. <jig...@gm...> - 2007-03-14 04:17:45
|
> I think it > may have to do with boxes? I think it's due to using a fixed /vspace instead of flexible vglue. I think what you want to do (and this may take some playing around) is figure out how far *up* the page you want the bottom of your cheque, and put a \vfill between the top of the cheque, and the bottom of the summary, and then at the bottom put the \vspace that you want from the bottom of your cheque. Now I'm not sure that this gives the answer that you are looking for. It would depend on how you want to lay this all out. The way that you have it laid out you have the invoice information at the top, then the cheque below that, and it appears that it is just a little bit below it. So what you want to do if you want to maintain the same format is to make sure that {tabularx} is the same size, and I'm not familiar enough with LaTeX to know if that is a text box, or if it's just a lexical boundary. If it is a textbox then you should be able to define the hsize and vsize of the box. If it's simply lexical (has no direct effect on how things are laid out on the page), then you will have to find a way to put the cheque on the page where you want (and that's crutial). I would suggest trying to place the cheque either on the top of the printed page of "letterpaper". That may be easily said, but much more difficult to produce with the cheque paper that you are using. Jigme Datse |
From: Jeff R. <je...@jr...> - 2007-03-14 16:52:36
|
Hi Jim > figure out how far *up* the page you want the bottom of your cheque, > and put a \vfill between the top of the cheque, and the bottom of the > summary, and then at the bottom put the \vspace that you want from the > bottom of your cheque. that may work, I'll give it a try tonight. Thanks Jeff Jigme Datse wrote: >> I think it >> may have to do with boxes? >> > > I think it's due to using a fixed /vspace instead of flexible vglue. > I think what you want to do (and this may take some playing around) is > figure out how far *up* the page you want the bottom of your cheque, > and put a \vfill between the top of the cheque, and the bottom of the > summary, and then at the bottom put the \vspace that you want from the > bottom of your cheque. Now I'm not sure that this gives the answer > that you are looking for. It would depend on how you want to lay this > all out. The way that you have it laid out you have the invoice > information at the top, then the cheque below that, and it appears > that it is just a little bit below it. So what you want to do if you > want to maintain the same format is to make sure that {tabularx} is > the same size, and I'm not familiar enough with LaTeX to know if that > is a text box, or if it's just a lexical boundary. If it is a textbox > then you should be able to define the hsize and vsize of the box. If > it's simply lexical (has no direct effect on how things are laid out > on the page), then you will have to find a way to put the cheque on > the page where you want (and that's crutial). I would suggest trying > to place the cheque either on the top of the printed page of > "letterpaper". That may be easily said, but much more difficult to > produce with the cheque paper that you are using. > > Jigme Datse > > ------------------------------------------------------------------------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the chance to share your > opinions on IT & business topics through brief surveys-and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV > _______________________________________________ > sql-ledger-users mailing list > sql...@li... > https://lists.sourceforge.net/lists/listinfo/sql-ledger-users > > > |