class Caracal::Core::Models::PageBreakModel

This class encapsulates the logic needed to store and manipulate page break data.

The :wrap option is not described in the project's README because it exists purely as an internal Caracal concern. Page breaks at the document level must be wrapped in a paragraph node; page breaks within paragraph-like container simply add a run. There's no need to trouble end users with this issue.

Attributes

page_break_wrap[R]

accessors

Public Class Methods

new(options={}, &block) click to toggle source

initialization

Calls superclass method Caracal::Core::Models::BaseModel::new
# File lib/caracal/core/models/page_break_model.rb, line 30
def initialize(options={}, &block)
  @page_break_wrap = DEFAULT_PAGE_BREAK_WRAP

  super options, &block
end

Public Instance Methods

wrap(value) click to toggle source
SETTERS ==============================
# File lib/caracal/core/models/page_break_model.rb, line 43
def wrap(value)
  @page_break_wrap = !!value
end

Private Instance Methods

option_keys() click to toggle source
# File lib/caracal/core/models/page_break_model.rb, line 53
def option_keys
  [:wrap]
end