module Omglog
Constants
- VERSION
Public Class Methods
on_terminal_resize() { || ... }
click to toggle source
# File lib/omglog.rb, line 13 def on_terminal_resize &block rendering = true trap("WINCH") { # A dragging resize fires lots of WINCH events; this throttles the redraw # and should cause it to (usually) line up with the final dimensions. if rendering rendering = false sleep 0.5 yield rendering = true end } end
run_on(system)
click to toggle source
# File lib/omglog.rb, line 6 def run_on system Omglog::Base.run on_terminal_resize { Omglog::Base.run } system.on_change { Omglog::Base.run } end
Private Instance Methods
on_terminal_resize() { || ... }
click to toggle source
# File lib/omglog.rb, line 13 def on_terminal_resize &block rendering = true trap("WINCH") { # A dragging resize fires lots of WINCH events; this throttles the redraw # and should cause it to (usually) line up with the final dimensions. if rendering rendering = false sleep 0.5 yield rendering = true end } end
run_on(system)
click to toggle source
# File lib/omglog.rb, line 6 def run_on system Omglog::Base.run on_terminal_resize { Omglog::Base.run } system.on_change { Omglog::Base.run } end