Sha256: fae39b2829aad4fdd22aa377ea911a6beb92d4ebf50a376a0abbffa7d100cd5b
Contents?: true
Size: 877 Bytes
Versions: 3
Compression:
Stored size: 877 Bytes
Contents
require 'curses' require 'daigaku/views/top_bar' module Daigaku module Views include Curses def reset_menu_position @position = 0 end private def default_window(height = nil, width = nil, top = 0, left = 0) init_screen noecho crmode curs_set(0) # invisible cursor height ||= lines width ||= cols + 1 window = Daigaku::Window.new(height, width, top, left) Curses.lines.times do |line| window.setpos(line, 0) window.clear_line end window.keypad(true) window.scrollok(true) window.refresh window end def sub_window_below_top_bar(window, top_bar) top_bar.show top = top_bar.height sub_window = window.subwin(window.maxy - top, window.maxx, top, 0) sub_window.keypad(true) sub_window end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
daigaku-1.0.0 | lib/daigaku/views.rb |
daigaku-0.6.0 | lib/daigaku/views.rb |
daigaku-0.5.0 | lib/daigaku/views.rb |