Class: Ucode::Glyphs::EmbeddedFonts::ContentStreamCorrelator::Config
- Inherits:
-
Struct
- Object
- Struct
- Ucode::Glyphs::EmbeddedFonts::ContentStreamCorrelator::Config
- Defined in:
- lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb
Overview
Per-font / per-block configuration.
Instance Attribute Summary collapse
-
#label_font_ids ⇒ Object
readonly
Type0 font object IDs whose glyphs print the hex codepoint labels on the page.
-
#page_numbers ⇒ Object
readonly
1-based PDF page numbers whose content streams reference the specimen font.
-
#specimen_font_id ⇒ Object
readonly
Type0 font object ID whose glyphs are the specimens we want to attribute.
Instance Method Summary collapse
-
#x_bucket(value) ⇒ Object
horizontal clustering granularity in PDF points.
-
#y_bucket(value) ⇒ Object
vertical clustering granularity in PDF points.
Instance Attribute Details
#label_font_ids ⇒ Object (readonly)
Type0 font object IDs whose glyphs print the hex codepoint labels on the page.
47 48 49 50 51 52 53 54 |
# File 'lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb', line 47 Config = Struct.new( :label_font_ids, :specimen_font_id, :page_numbers, :y_bucket, :x_bucket, keyword_init: true, ) |
#page_numbers ⇒ Object (readonly)
1-based PDF page numbers whose content streams reference the specimen font.
47 48 49 50 51 52 53 54 |
# File 'lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb', line 47 Config = Struct.new( :label_font_ids, :specimen_font_id, :page_numbers, :y_bucket, :x_bucket, keyword_init: true, ) |
#specimen_font_id ⇒ Object (readonly)
Type0 font object ID whose glyphs are the specimens we want to attribute.
47 48 49 50 51 52 53 54 |
# File 'lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb', line 47 Config = Struct.new( :label_font_ids, :specimen_font_id, :page_numbers, :y_bucket, :x_bucket, keyword_init: true, ) |
Instance Method Details
#x_bucket=(value) ⇒ Object
horizontal clustering granularity in PDF points. Default 50.0 — separates label clusters within a row (labels are ~16pt wide, clusters ~60-160pt apart).
47 48 49 50 51 52 53 54 |
# File 'lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb', line 47 Config = Struct.new( :label_font_ids, :specimen_font_id, :page_numbers, :y_bucket, :x_bucket, keyword_init: true, ) |
#y_bucket=(value) ⇒ Object
vertical clustering granularity in PDF points. Default 1.5 — matches mutool’s text matrix granularity for the row labels.
47 48 49 50 51 52 53 54 |
# File 'lib/ucode/glyphs/embedded_fonts/content_stream_correlator.rb', line 47 Config = Struct.new( :label_font_ids, :specimen_font_id, :page_numbers, :y_bucket, :x_bucket, keyword_init: true, ) |