Class: Docxtor2::Package::Document::PageBreak

Inherits:
Element show all
Defined in:
lib/docxtor2/package/document/page_break.rb

Instance Method Summary collapse

Methods included from ObjectUtils

#find_argument

Methods included from BlockEvaluator

#evaluate

Methods inherited from ElementList

map

Constructor Details

#initialize(*args, &block) ⇒ PageBreak

Returns a new instance of PageBreak.



3
4
5
# File 'lib/docxtor2/package/document/page_break.rb', line 3

def initialize(*args, &block)
  super(*args, &block)
end

Instance Method Details

#render(xml) ⇒ Object



7
8
9
10
11
12
13
14
# File 'lib/docxtor2/package/document/page_break.rb', line 7

def render(xml)
  super(xml)
  write_element(:p) do
    write_element(:r) do
      @xml.w :br, 'w:type' => 'page'
    end
  end
end