Class: MarsBase10::VariableHeightPane

Inherits:
Pane
  • Object
show all
Defined in:
lib/mars_base_10/pane.rb

Instance Attribute Summary

Attributes inherited from Pane

#cur_draw_col, #cur_draw_row, #extended_lines, #height_pct, #highlight, #index, #latch, #left_edge_col, #subject, #top_row, #viewport, #width_pct

Instance Method Summary collapse

Methods inherited from Pane

#active?, #clear, #current_item_index, #current_subject_index, #draw, #draw_border, #draw_line, #draw_title, #first_drawable_col, #first_drawable_row, #gutter_width, #initialize, #last_drawable_row, #last_visible_row, #latched?, #max_contents_rows, #min_column_width, #prepare_for_writing_contents, #process, #reset, #right_pad, #scroll_to_row, #set_row, #view, #visible_content_range, #visible_content_shift, #window

Constructor Details

This class inherits a constructor from MarsBase10::Pane

Instance Method Details

#last_colObject



288
289
290
# File 'lib/mars_base_10/pane.rb', line 288

def last_col
  (self.viewport.max_cols * self.width_pct).floor
end

#last_rowObject



292
293
294
# File 'lib/mars_base_10/pane.rb', line 292

def last_row
  self.viewport.max_rows - self.top_row
end