Class: Basher::UI::ProgressView
- Defined in:
- lib/basher/ui/progress_view.rb
Instance Attribute Summary collapse
-
#game ⇒ Object
Returns the value of attribute game.
Attributes inherited from BaseView
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from BaseView
#clear, #initialize, #resize_and_reposition, #will_resize!
Constructor Details
This class inherits a constructor from Basher::UI::BaseView
Instance Attribute Details
#game ⇒ Object
Returns the value of attribute game.
4 5 6 |
# File 'lib/basher/ui/progress_view.rb', line 4 def game @game end |
Class Method Details
.lines ⇒ Object
6 7 8 |
# File 'lib/basher/ui/progress_view.rb', line 6 def self.lines 1 end |
Instance Method Details
#setup ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'lib/basher/ui/progress_view.rb', line 10 def setup clear render every: 0.1 do clear(false) window.attron(Ncurses::A_BOLD) puts '=' * remaining, h: :left window.attroff(Ncurses::A_BOLD) end end |