Sha256: 45689433762b03a7e27f8929840d15e335b7cbcca52d97d841924f0fd02744e0

Contents?: true

Size: 334 Bytes

Versions: 1

Compression:

Stored size: 334 Bytes

Contents

module Terminal
  class Table
    class Cell

      def align(val, position, length)
        # positions = { :left => :ljust, :right => :rjust, :center => :center }
        positions = { :left => :mb_ljust, :right => :mb_rjust, :center => :mb_center }
        val.public_send(positions[position], length)
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
terminal-table-unicode-0.1.0 lib/terminal/table/cell.rb