54 self.font = 0 |
54 self.font = 0 |
55 |
55 |
56 |
56 |
57 class PDFObjectTracker(object): |
57 class PDFObjectTracker(object): |
58 """ |
58 """ |
59 Class to conveniently handle the tracking of PDF objects |
59 Class to conveniently handle the tracking of PDF objects so that the |
60 so that the cross-reference table can be built (PDF1.4Ref(p39)) |
60 cross-reference table can be built (PDF1.4Ref(p39)). |
|
61 |
61 All writes to the file are passed through a PDFObjectTracker object. |
62 All writes to the file are passed through a PDFObjectTracker object. |
62 """ |
63 """ |
63 def __init__(self, file): |
64 def __init__(self, file): |
64 """ |
65 """ |
65 Constructor |
66 Constructor |
153 |
154 |
154 def fontToPoints(self, thousandths): |
155 def fontToPoints(self, thousandths): |
155 """ |
156 """ |
156 Public method to convert the font size to points. |
157 Public method to convert the font size to points. |
157 |
158 |
|
159 @param thousandths font size (integer) |
158 @return point size of the font (integer) |
160 @return point size of the font (integer) |
159 """ |
161 """ |
160 return self.fontSize * thousandths / 1000.0 |
162 return self.fontSize * thousandths / 1000.0 |
161 |
163 |
162 def setStyle(self, style_): |
164 def setStyle(self, style_): |