NAME

Rui::Window - the Rui window


SYNOPSIS

  # using a window
  use Rui::Window;
  $window = Rui::Window->new(
     width       => 200,
     height      => 150,
     isResizable => 1,
     title       => 'Window Title',
  );
  $window->title('New Window Title);
  $window->Label(value => 'foo');
  $window->addListener
     (Close => sub { print "closed: ". shift->source->getWindowId });
  print $window->getWindowId;
  print $window->getWidgetId; # always -1, special id for windows
  $window->destroy;
  # subclassing a window: a hello world window
  package HelloWorldWindow;
  use base 'Rui::Window';
  sub init
  {
     my ($self, %params) = @_;
     $self->SUPER::init(%params);
     $self->Label(value => 'Hello World');
  }


REQUIRES

the Rui::Event manpage, the Rui::Widget::Factory manpage, Rui::Remote::SessionManager


DESCRIPTION

A window is a top level widget, at the root of the widget composition tree. When creating a window you can configure width, height, isResizable, and the window title.

The window delegates all widget calls to its main panel.

The winodw registers/deregisters with a the Rui::Application::Base manpage, and uses it to get the widget factory.