aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Vilcans <martin@librador.com>2012-02-19 22:31:57 +0100
committerMartin Vilcans <martin@librador.com>2012-02-19 22:31:57 +0100
commit5a35f33af12f012ef466452cb4f8312103739ccf (patch)
tree57dd5c8a7fb9bec0b934d4981a54925ad2d26b92
parent5883c35785b03f1823fcbdea82a00b76aaa3f785 (diff)
downloadscreenplain-5a35f33af12f012ef466452cb4f8312103739ccf.tar.gz
Removed pdf and text modules as they aren't supported yet anyway.
-rw-r--r--screenplain/export/pdf.py28
-rw-r--r--screenplain/export/text.py17
2 files changed, 0 insertions, 45 deletions
diff --git a/screenplain/export/pdf.py b/screenplain/export/pdf.py
deleted file mode 100644
index 4e29f6d..0000000
--- a/screenplain/export/pdf.py
+++ /dev/null
@@ -1,28 +0,0 @@
-# Copyright (c) 2011 Martin Vilcans
-# Licensed under the MIT license:
-# http://www.opensource.org/licenses/mit-license.php
-
-import fileinput
-from reportlab.pdfgen import canvas
-from reportlab.lib import pagesizes
-
-from screenplain.format import get_pages
-
-
-def to_pdf(screenplay, output_file):
- # pagesizes.letter, pagesizes.A4
- page_width, page_height = pagesizes.A4
- c = canvas.Canvas(output_file, pagesize=pagesizes.A4)
- c.setFont('Courier', 12)
-
- for page_no, page in enumerate(get_pages(screenplay)):
- # page numbers are 0-based
- if page_no != 0:
- c.showPage()
- c.setFont('Courier', 12)
- for line_no, line in enumerate(page):
- c.drawString(0, page_height - 12 - 12 * line_no, line)
- c.save()
-
-if __name__ == '__main__':
- to_pdf(fileinput.input())
diff --git a/screenplain/export/text.py b/screenplain/export/text.py
deleted file mode 100644
index fe3bcb3..0000000
--- a/screenplain/export/text.py
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright (c) 2011 Martin Vilcans
-# Licensed under the MIT license:
-# http://www.opensource.org/licenses/mit-license.php
-
-import sys
-import codecs
-from screenplain.format import get_pages
-
-
-def to_text(screenplay, out):
- for page_no, page in enumerate(get_pages(screenplay)):
- # page_no is 0-based
- if page_no != 0:
- out.write('\f')
- for line in page:
- out.write(line)
- out.write('\n')