class HexaPDF:: Type:: Resources
Parent | HexaPDF::Dictionary |
---|
Represents the resources needed by a content stream.
See: PDF2.0 s7.8.3
Field Definitions
Name | Type/Allowed Values | Required | Default Value |
---|---|---|---|
ExtGState | HexaPDF::Dictionary or Hash | false | nil |
ColorSpace | HexaPDF::Dictionary or Hash | false | nil |
Pattern | HexaPDF::Dictionary or Hash | false | nil |
Shading | HexaPDF::Dictionary or Hash | false | nil |
XObject | HexaPDF::Dictionary or Hash | false | nil |
Font | HexaPDF::Dictionary or Hash | false | nil |
ProcSet | HexaPDF::PDFArray or Array | false | nil |
Properties | HexaPDF::Dictionary or Hash | false | nil |
Public Instance Methods
Adds the color space to the resources and returns the name under which it is stored.
If there already exists a color space with the same definition, it is reused. The device color spaces :DeviceGray
, :DeviceRGB
and :DeviceCMYK
are never stored, their respective name is just returned.
Adds the graphics state parameter dictionary to the resources and returns the name under which it is stored.
If there already exists a name for the given dictionary, it is just returned.
Adds the font dictionary to the resources and returns the name under which it is stored.
If there already exists a name for the given dictionary, it is just returned.
Adds the pattern dictionary to the resources and returns the name under which it is stored.
If there already exists a name for the given dictionary, it is just returned.
Adds the property list to the resources and returns the name under which it is stored.
If there already exists a name for the given property list, it is just returned.
Adds the XObject to the resources and returns the name under which it is stored.
If there already exists a name for the given XObject, it is just returned.
Returns the color space stored under the given name.
If the color space is not found, an error is raised.
Note: The color spaces :DeviceGray, :DeviceRGB and :DeviceCMYK are returned without a lookup since they are fixed.
Returns the graphics state parameter dictionary (see Type::GraphicsStateParameter
) stored under the given name.
If the dictionary is not found, an error is raised.
Returns the font dictionary stored under the given name.
If the dictionary is not found, an error is raised.
Returns the pattern dictionary stored under the given name.
If the dictionary is not found, an error is raised.
Returns the property list stored under the given name.
If the property list is not found, an error is raised.
Returns the XObject stored under the given name.
If the XObject is not found, an error is raised.