Class: TTYString::CSICode::H

Inherits:
TTYString::CSICode show all
Defined in:
lib/tty_string/csi_code_definitions.rb

Overview

leftovers:allow

Direct Known Subclasses

LowF

Instance Method Summary collapse

Methods inherited from TTYString::CSICode

default_arg, #integer

Methods inherited from TTYString::Code

char, descendants, inherited, #initialize, render

Constructor Details

This class inherits a constructor from TTYString::Code

Instance Method Details

#action(row = '1', col = '1') ⇒ Object



80
81
82
83
84
85
86
87
88
# File 'lib/tty_string/csi_code_definitions.rb', line 80

def action(row = '1', col = '1')
  col = integer(col)
  row = integer(row)
  return unless col && row

  # cursor is zero indexed, arg is 1 indexed
  cursor.row = row - 1
  cursor.col = col - 1
end