module VER
module Ncurses
class Panel < Struct.new(:pointer)
extend FFI::Library
# use RUBY_FFI_NCURSES_LIB to specify exactly which lib you want, e.g.
# ncursesw, XCurses (from PDCurses)
if ENV["RUBY_FFI_PANEL_LIB"].to_s != ""
LIB_HANDLE = ffi_lib( ENV["RUBY_FFI_PANEL_LIB"] ).first
else
LIB_HANDLE = ffi_lib( 'panel', 'libpanelw.so.5' ).first
end
functions = [
[:new_panel, [:pointer], :pointer],
[:bottom_panel, [:pointer], :int],
[:top_panel, [:pointer], :int],
[:show_panel, [:pointer], :int],
[:update_panels, [], :void],
[:hide_panel, [:pointer], :int],
This file has been truncated. show original