25674c26838edf0a577e53f168789aa3ec6f7fb3
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py  1) 
src/rechnung/Invoice/metrics.py  2) def setup():
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py  3)     from reportlab.lib.pagesizes import A4
src/rechnung/Invoice/metrics.py  4)     from reportlab.lib.units import cm
src/rechnung/Invoice/metrics.py  5)     from reportlab.pdfbase.ttfonts import TTFont
src/rechnung/Invoice/metrics.py  6)     from reportlab.pdfbase import pdfmetrics
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py  7) 
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py  8)     if 'DejaVuSans' not in pdfmetrics._fonts:
src/rechnung/Invoice/metrics.py  9)         pdfmetrics.registerFont(TTFont("DejaVuSans", "DejaVuSans.ttf"))
src/rechnung/Invoice/metrics.py 10)         pdfmetrics.registerFont(TTFont("DejaVuSans-Bold", "DejaVuSans-Bold.ttf"))
src/rechnung/Invoice/metrics.py 11)         pdfmetrics.registerFont(TTFont("DejaVuSans-Oblique", "DejaVuSans-Oblique.ttf"))
src/rechnung/Invoice/metrics.py 12)         pdfmetrics.registerFont(TTFont("DejaVuSans-BoldOblique", "DejaVuSans-BoldOblique.ttf"))
src/rechnung/Invoice/metrics.py 13) 
src/rechnung/Invoice/metrics.py 14)     return (cm, A4)
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 15) 
src/rechnung/Invoice/metrics.py 16) 
src/rechnung/Invoice/metrics.py 17) (cm, A4) = setup()
src/rechnung/Invoice/metrics.py 18) 
src/rechnung/Invoice/metrics.py 19) (page_width, page_height) = A4
Bernd Wurst Umstellung von Bitstream Ve...

Bernd Wurst authored 7 years ago

src/rechnung/Invoice/metrics.py 20) font = 'DejaVuSans'
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 21) # Set default font size
Bernd Wurst Default-Schriftgröße kleine...

Bernd Wurst authored 15 years ago

src/rechnung/Invoice/metrics.py 22) default_font_size = 8
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 23) 
src/rechnung/Invoice/metrics.py 24) 
src/rechnung/Invoice/metrics.py 25) # set margins
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py 26) topmargin = 2 * cm
src/rechnung/Invoice/metrics.py 27) bottommargin = 2.5 * cm
src/rechnung/Invoice/metrics.py 28) leftmargin = 2 * cm
src/rechnung/Invoice/metrics.py 29) rightmargin = 2 * cm
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 30) 
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py 31) topcontent = page_height - topmargin
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 32) leftcontent = leftmargin
src/rechnung/Invoice/metrics.py 33) rightcontent = page_width - rightmargin
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py 34) bottomcontent = bottommargin
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 35) 
Bernd Wurst automatische code-style-fixes

Bernd Wurst authored 5 years ago

src/rechnung/Invoice/metrics.py 36) rightcolumn = 13 * cm
Bernd Wurst Trennung von Firmen-spezifi...

Bernd Wurst authored 16 years ago

src/rechnung/Invoice/metrics.py 37)