Class: Asciidoctor::PDF::FormattedText::FragmentPositionRenderer
- Defined in:
- lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb
Instance Attribute Summary collapse
-
#bottom ⇒ Object
readonly
Returns the value of attribute bottom.
-
#left ⇒ Object
readonly
Returns the value of attribute left.
-
#page_number ⇒ Object
readonly
Returns the value of attribute page_number.
-
#right ⇒ Object
readonly
Returns the value of attribute right.
-
#top ⇒ Object
readonly
Returns the value of attribute top.
Instance Method Summary collapse
Instance Attribute Details
#bottom ⇒ Object (readonly)
Returns the value of attribute bottom.
7 8 9 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 7 def bottom @bottom end |
#left ⇒ Object (readonly)
Returns the value of attribute left.
8 9 10 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 8 def left @left end |
#page_number ⇒ Object (readonly)
Returns the value of attribute page_number.
9 10 11 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 9 def page_number @page_number end |
#right ⇒ Object (readonly)
Returns the value of attribute right.
6 7 8 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 6 def right @right end |
#top ⇒ Object (readonly)
Returns the value of attribute top.
5 6 7 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 5 def top @top end |
Instance Method Details
#render_behind(fragment) ⇒ Object
11 12 13 14 15 16 |
# File 'lib/asciidoctor/pdf/formatted_text/fragment_position_renderer.rb', line 11 def render_behind fragment @top = fragment.top @right = (@left = fragment.left) + fragment.width @bottom = fragment.bottom @page_number = fragment.document.page_number end |