class Glimmer::LibUI::ControlProxy::AreaProxy::ScrollingAreaProxy

Proxy for LibUI scrolling area objects

Follows the Proxy Design Pattern

Public Instance Methods

build_control() click to toggle source
# File lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb, line 32
def build_control
  @area_handler = ::LibUI::FFI::AreaHandler.malloc
  @args[0] ||= Glimmer::LibUI::ControlProxy.main_window_proxy.width
  @args[1] ||= Glimmer::LibUI::ControlProxy.main_window_proxy.height
  @libui    = ::LibUI.new_scrolling_area(@area_handler, *@args)
end
height(value = nil) click to toggle source
# File lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb, line 50
def height(value = nil)
  if value.nil?
    @args[1]
  else
    @args[1] = value
    set_size(width, height)
  end
end
Also aliased as: height=, set_height
height=(value = nil)
Alias for: height
scroll_to(scroll_x, scroll_y, scroll_width = nil, scroll_height = nil) click to toggle source
Calls superclass method
# File lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb, line 67
def scroll_to(scroll_x, scroll_y, scroll_width = nil, scroll_height = nil)
  scroll_width, scroll_height = Glimmer::LibUI::ControlProxy.main_window_proxy.content_size
  super(scroll_x, scroll_y, scroll_width, scroll_height)
end
set_height(value = nil)
Alias for: height
set_size(width, height) click to toggle source
Calls superclass method
# File lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb, line 61
def set_size(width, height)
  @args[0] = width
  @args[1] = height
  super(width, height)
end
set_width(value = nil)
Alias for: width
width(value = nil) click to toggle source
# File lib/glimmer/libui/control_proxy/area_proxy/scrolling_area_proxy.rb, line 39
def width(value = nil)
  if value.nil?
    @args[0]
  else
    @args[0] = value
    set_size(width, height)
  end
end
Also aliased as: width=, set_width
width=(value = nil)
Alias for: width