Class: TTFunk::Table::Dsig
- Inherits:
-
TTFunk::Table
- Object
- TTFunk::Table
- TTFunk::Table::Dsig
- Defined in:
- lib/ttfunk/table/dsig.rb
Overview
Digital Signature (DSIG
) table.
Defined Under Namespace
Classes: SignatureRecord
Constant Summary collapse
- TAG =
Table tag.
'DSIG'
Instance Attribute Summary collapse
-
#flags ⇒ Integer
readonly
Permission flags.
-
#signatures ⇒ Array<SignatureRecord>
readonly
Signature records.
-
#version ⇒ Integer
readonly
Version umber of this table.
Attributes inherited from TTFunk::Table
Class Method Summary collapse
-
.encode(dsig) ⇒ String
Encode table.
Instance Method Summary collapse
-
#tag ⇒ String
Table tag.
Methods inherited from TTFunk::Table
Constructor Details
This class inherits a constructor from TTFunk::Table
Instance Attribute Details
#flags ⇒ Integer (readonly)
Permission flags.
Source Code
lib/ttfunk/table/dsig.rb, line 43
43 | def flags |
44 | @flags
|
45 | end
|
#signatures ⇒ Array<SignatureRecord> (readonly)
Signature records.
Source Code
lib/ttfunk/table/dsig.rb, line 47
47 | def signatures |
48 | @signatures
|
49 | end
|
#version ⇒ Integer (readonly)
Version umber of this table.
Source Code
lib/ttfunk/table/dsig.rb, line 39
39 | def version |
40 | @version
|
41 | end
|
Class Method Details
.encode(dsig) ⇒ String
Encode table.
Note: all signatures will be lost. This encodes an empty table regardless whether the supplied table contains any signtaures or not.
Source Code
lib/ttfunk/table/dsig.rb, line 59
59 | def self.encode(dsig) |
60 | return unless dsig |
61 | |
62 | # Don't attempt to re-sign or anything - just use dummy values.
|
63 | # Since we're subsetting that should be permissible.
|
64 | [dsig.version, 0, 0].pack('Nnn') |
65 | end
|
Instance Method Details
#tag ⇒ String
Table tag.
Source Code
lib/ttfunk/table/dsig.rb, line 70
70 | def tag |
71 | TAG
|
72 | end
|