[ruby-gnome2-doc-cvs] [Ruby-GNOME2 Project Website] update - tut-gtk2-txtw-scrolledwin

Back to archive index

ruby-****@sourc***** ruby-****@sourc*****
2009年 2月 3日 (火) 22:43:28 JST


-------------------------
REMOTE_ADDR = 74.15.84.244
REMOTE_HOST = 
        URL = http://ruby-gnome2.sourceforge.jp/hiki.cgi?tut-gtk2-txtw-scrolledwin
-------------------------
@@ -18,7 +18,7 @@
     * page_size: the page size. In a Gtk::Scrollbar this is the size of the area which is currently visible.
 
 
-The following listing demonstrates how to use use scrolled windows and viewports. As the scrollbar is moved, the viewport will scroll as well because adjustments are synchronized. New scrolled windows are created with:   Gtk::ScrolledWindow.new(hadjustment = nil, vadjustment = nil), where the two arguments are the scrolled window's adjustments; these will be shared with the scrollbars and the child widget to keep the bars in sync with the child. Though you could supply adjustments you previously created, usually you do not specify any arguments, hence using the default nil(s) instead, which causes the scrolled window to create them for you. In our example the adjustments are used when viewport is created with Gtk::Viewport.new(horizontal, vertical). The viewport adjustments are initialized from with those from the scrolled window, ensuring that both containers will be scrolled at the same time.
+The following listing demonstrates how to use use scrolled windows and viewports. As the scrollbar is moved, the viewport will scroll as well because adjustments are synchronized. New scrolled windows are created with:   Gtk::ScrolledWindow.new(hadjustment = nil, vadjustment = nil), where the two arguments are the scrolled window's adjustments; these will be shared with the scrollbars and the child widget to keep the bars in sync with the child. Though you could supply adjustments you previously created, usually you do not specify any arguments, hence using the default nil(s) instead, which causes the scrolled window to create them for you. In our example the adjustments are used when viewport is created with Gtk::Viewport.new(horizontal, vertical). The viewport adjustments are initialized with those from the scrolled window, ensuring that both containers will be scrolled at the same time.
 
 One of the decisions you have to make when setting up a scrolled window is to specify when the scrollbars will be visible. This is done with the policy arguments, which take one of the values defined in ((<GtkPolicyType|Gtk#GtkPolicyType>)). Though unlikely, another thing you may wish to set is the placement of the scrollbars. For that you have Gtk::Scrollbar#window_placement=(window_placement) method at your disposal. Lok for the correct argument values at ((<GtkCornerType|Gtk#GtkCornerType>)).
 




ruby-gnome2-cvs メーリングリストの案内
Back to archive index