Class: WindowTerminal::Line

Inherits:
Object
  • Object
show all
Defined in:
lib/accu-window.rb

Overview

A class which renders a simple horizontal line on a Window.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(y) ⇒ Line

Initializes a Line object.



349
350
351
# File 'lib/accu-window.rb', line 349

def initialize(y)
	@y = y
end

Instance Attribute Details

#yObject (readonly)

Returns the value of attribute y.



346
347
348
# File 'lib/accu-window.rb', line 346

def y
  @y
end

Instance Method Details

#render_line(line, width, *args) ⇒ Object

Renders on the passed line and returns the modified line.



355
356
357
# File 'lib/accu-window.rb', line 355

def render_line(line,width,*args)
	line.gsub(" ","-")
end