ruby-****@sourc*****
ruby-****@sourc*****
2012年 9月 5日 (水) 09:36:14 JST
------------------------- REMOTE_ADDR = 70.49.49.99 REMOTE_HOST = URL = http://ruby-gnome2.sourceforge.jp/hiki.cgi?tut-gtk2-txtw-textview ------------------------- @@ -47,7 +47,7 @@ :Short D-tour: - If you are not exactly sure what was just said, following is a short demonstration simulating how Gtk::TextView and Gtk::TextBuffer are implemented, and how you can exploit this design to create some Gtk::TextViews that share the same Gtk::TextBuffer and some that do not: + If you understand the relationship between the two Gtk classes, namely between Gtk::TextView and Gtk::TextBuffer, you will not miss anything by ignoring this D-tour. But if you are not exactly sure what was just said in the above paragraph, then following short demonstration simulating how Gtk::TextView and Gtk::TextBuffer are implemented, may help you understand this relationship and show you how to exploit this design to create some Gtk::TextViews that share the same Gtk::TextBuffer and some that do not: In tv-N-tb-example.rb sample program pay attention to three different ((*tview_instance_#*)) TextView instances. The first one, designated with number zero (0) has its own (not shared) TextBuffer, however, the other two (#1 and #2) share the TextBuffer instance: