Class: Pdfrb::Action::Launch

Inherits:
Base
  • Object
show all
Defined in:
lib/pdfrb/action/types.rb

Overview

Launch — launch an external application. §12.6.4.5

Class Method Summary collapse

Methods inherited from Base

register_as

Class Method Details

.action_typeObject



35
# File 'lib/pdfrb/action/types.rb', line 35

def action_type; :Launch; end

.to_pdf(file_spec:, new_window: nil) ⇒ Object



37
38
39
40
41
# File 'lib/pdfrb/action/types.rb', line 37

def to_pdf(file_spec:, new_window: nil)
  payload = { S: :Launch, F: file_spec }
  payload[:NewWindow] = new_window unless new_window.nil?
  payload
end