Class: PDF::Writer::Object::Procset
- Inherits:
-
PDF::Writer::Object
- Object
- PDF::Writer::Object
- PDF::Writer::Object::Procset
- Defined in:
- lib/pdf/writer/object/procset.rb
Overview
The document Procedure Set. Not necessary in PDF 1.4 or later, but producing applications are recommended to provide the /ProcSet /Resource in any case for older viewers. Viewing applications are not recommended to rely on this information being correct.
These procedure sets are used only when the content stream is printed to a PostScript output device; the names identify PostScript procedure sets that must be sent to the device to interpret the PDF operators in the content stream. Each element of this array must be one of the following predefined names: ‘PDF’, ‘Text’, ‘ImageB’, ‘ImageC’, and ‘ImageI’. See also Appendix H note 102.
Instance Attribute Summary
Attributes inherited from PDF::Writer::Object
Instance Method Summary collapse
-
#<<(p) ⇒ Object
This is to add new items to the procset list, despite the fact that this is considered obselete, the items are required for printing to some PostsCript printers.
-
#initialize(parent) ⇒ Procset
constructor
A new instance of Procset.
- #to_s ⇒ Object
Constructor Details
#initialize(parent) ⇒ Procset
Returns a new instance of Procset.
23 24 25 26 27 28 29 |
# File 'lib/pdf/writer/object/procset.rb', line 23 def initialize(parent) super @info = ["PDF", "Text"] @parent.pages.procset = self @parent.procset = self end |
Instance Method Details
#<<(p) ⇒ Object
This is to add new items to the procset list, despite the fact that this is considered obselete, the items are required for printing to some PostsCript printers.
p
may be ‘ImageB’, ‘ImageC’, or ‘ImageI’.
36 37 38 |
# File 'lib/pdf/writer/object/procset.rb', line 36 def <<(p) @info << p end |
#to_s ⇒ Object
40 41 42 43 44 45 |
# File 'lib/pdf/writer/object/procset.rb', line 40 def to_s info = @info.uniq res = "\n#{@oid} 0 obj\n[" @info.each { |k| res << "/#{k} " } res << "]\nendobj" end |