class CursorsDemo
# Copyright © 2015-2016 Ruby-GNOME2 Project Team # This program is licenced under the same licence as Ruby-GNOME2. #
Cursors¶ ↑
Demonstrates a useful set of available cursors.
Public Class Methods
new(main_window)
click to toggle source
# File gtk3/sample/gtk-demo/cursors.rb, line 10 def initialize(main_window) @window = Gtk::Window.new(:toplevel) @window.screen = main_window.screen @window.title = "Cursors" @window.set_default_size(500, 500) sw = Gtk::ScrolledWindow.new(nil, nil) sw.set_policy(:never, :automatic) @window.add(sw) initialize_box sw.add(@box) add_general_section add_link_and_status_section add_selection_section add_drag_and_drop_section add_resize_and_scrolling_section add_zoom_section end
Public Instance Methods
run()
click to toggle source
# File gtk3/sample/gtk-demo/cursors.rb, line 31 def run if !@window.visible? @window.show_all else @window.destroy end @window end