Class: ThinReports::Core::Shape::List::SectionInternal

Inherits:
Base::Internal show all
Defined in:
lib/thinreports/core/shape/list/section_internal.rb

Instance Attribute Summary collapse

Attributes inherited from Base::Internal

#format, #parent, #states

Instance Method Summary collapse

Methods inherited from Base::Internal

#copy, #initialize, #switch_parent!, #type_of?

Constructor Details

This class inherits a constructor from ThinReports::Core::Shape::Base::Internal

Instance Attribute Details

#section_nameSymbol

Returns:

  • (Symbol)


14
15
16
# File 'lib/thinreports/core/shape/list/section_internal.rb', line 14

def section_name
  @section_name
end

Instance Method Details

#move_top_to(ry) ⇒ Object

Parameters:

  • ry (Numeric)


21
22
23
# File 'lib/thinreports/core/shape/list/section_internal.rb', line 21

def move_top_to(ry)
  states[:relative_top] = ry
end

#relative_positionArray<Numeric>

Returns:



26
27
28
29
# File 'lib/thinreports/core/shape/list/section_internal.rb', line 26

def relative_position
  [relative_left,
   relative_top + (states[:relative_top] || 0)]
end

#styleObject



16
17
18
# File 'lib/thinreports/core/shape/list/section_internal.rb', line 16

def style
  @style ||= Style::Base.new(format)
end