Class: Preflight::Rules::NoRegistrationBlack
- Inherits:
-
Object
- Object
- Preflight::Rules::NoRegistrationBlack
- Extended by:
- Forwardable
- Defined in:
- lib/preflight/rules/no_registration_black.rb
Overview
Instance Attribute Summary collapse
-
#issues ⇒ Object
readonly
Returns the value of attribute issues.
Instance Method Summary collapse
-
#invoke_xobject(label) ⇒ Object
descend into nested form xobjects.
-
#page=(page) ⇒ Object
we’re about to start a new page, reset state.
- #set_cmyk_color_for_nonstroking(c, m, y, k) ⇒ Object
- #set_cmyk_color_for_stroking(c, m, y, k) ⇒ Object
- #set_nonstroke_color_space(label) ⇒ Object
- #set_stroke_color_space(label) ⇒ Object
Instance Attribute Details
#issues ⇒ Object (readonly)
Returns the value of attribute issues.
29 30 31 |
# File 'lib/preflight/rules/no_registration_black.rb', line 29 def issues @issues end |
Instance Method Details
#invoke_xobject(label) ⇒ Object
descend into nested form xobjects
42 43 44 45 46 47 48 49 |
# File 'lib/preflight/rules/no_registration_black.rb', line 42 def invoke_xobject(label) @state.invoke_xobject(label) do |xobj| case xobj when PDF::Reader::FormXObject then xobj.walk(self) end end end |
#page=(page) ⇒ Object
we’re about to start a new page, reset state
33 34 35 36 37 38 |
# File 'lib/preflight/rules/no_registration_black.rb', line 33 def page=(page) @page = page @state = PDF::Reader::PageState.new(page) @issues = [] @resource_labels_seen = [] end |
#set_cmyk_color_for_nonstroking(c, m, y, k) ⇒ Object
55 56 57 |
# File 'lib/preflight/rules/no_registration_black.rb', line 55 def set_cmyk_color_for_nonstroking(c, m, y, k) reg_black_detected(c, m, y, k) if registration_black?(c, m, y, k) end |
#set_cmyk_color_for_stroking(c, m, y, k) ⇒ Object
51 52 53 |
# File 'lib/preflight/rules/no_registration_black.rb', line 51 def set_cmyk_color_for_stroking(c, m, y, k) reg_black_detected(c, m, y, k) if registration_black?(c, m, y, k) end |
#set_nonstroke_color_space(label) ⇒ Object
63 64 65 |
# File 'lib/preflight/rules/no_registration_black.rb', line 63 def set_nonstroke_color_space(label) check_color_space(label) end |
#set_stroke_color_space(label) ⇒ Object
59 60 61 |
# File 'lib/preflight/rules/no_registration_black.rb', line 59 def set_stroke_color_space(label) check_color_space(label) end |