struct Termisu::Events::Resize

Overview

Terminal resize event.

Generated when the terminal window size changes (SIGWINCH).

Example:

event = termisu.poll_event
if event.is_a?(Termisu::Events::Resize)
  puts "Terminal resized to #{event.width}x#{event.height}"
  termisu.sync # Force full redraw
end

Defined in:

termisu/events/resize.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(width : Int32, height : Int32) #

[View source]

Instance Method Detail

def height : Int32 #

New terminal height in rows.


[View source]
def width : Int32 #

New terminal width in columns.


[View source]