新規作成  編集  Ruby-GNOME2 Project Website  ページ一覧  検索  更新履歴  編集履歴  RSS  ログイン

Gtk::MenuToolButton

Gtk::MenuToolButton クラス

A Gtk::MenuToolButton is a Gtk::ToolItem that contains a button and a small additional button with an arrow. When clicked, the arrow button pops up a dropdown menu.

Use Gtk::MenuToolButton.new to create a new Gtk::MenuToolButton. Use Gtk::MenuToolButton.new to create a new Gtk::MenuToolButton containing a stock item.

インクルードされているモジュール

  • Gtk::Buildable?
  • Atk::Implementor
  • GLib::Interface?

クラスメソッド

Gtk::MenuToolButton.new(icon_widget = nil, label = nil)
Creates a new Gtk::MenuToolButton using icon_widget as icon and label as label. Since 2.6
  • icon_widget: a widget that will be used as icon widget, or nil
  • label: a string that will be used as label, or nil
  • Returns: the new Gtk::MenuToolButton
Gtk::MenuToolButton.new(stock_id)
Creates a new Gtk::MenuToolButton. The new Gtk::MenuToolButton will contain an icon and label from the stock item indicated by stock_id. Since 2.6

インスタンスメソッド

menu
Gets the Gtk::Menu associated with Gtk::MenuToolButton. Since 2.6
menu=(menu)
Sets the Gtk::Menu that is popped up when the user clicks on the arrow. If menu is nil, the arrow button becomes insensitive. Since 2.6
set_menu(menu)
Same as Gtk::MenuToolButton#menu=. Since 2.6
set_arrow_tooltip(tooltips, tip_text = nil, tip_private = nil)
Sets the Gtk::Tooltips object to be used for arrow button which pops up the menu. See Gtk::ToolItem#set_tooltip for setting a tooltip on the whole Gtk::MenuToolButton. Since 2.6
  • tooltips: the Gtk::Tooltips object to be used
  • tip_text: text to be used as tooltip text for tool_item or nil
  • tip_private: text to be used as private tooltip text or nil
  • Returns: self

プロパティ

menu: Gtk::Menu (Read/Write)
The dropdown menu Since 2.6

関連ページ

Gtk::Toolbar, Gtk::ToolButton

The toolbar widget

The parent class of Gtk::MenuToolButton. The properties "label_widget", "label", "icon_widget", and "stock_id" on Gtk::ToolButton determine the label and icon used on Gtk::MenuToolButtons?.

更新履歴

  • 2014-06-16 インクルードされているモジュールの項目を追加。 - きたがわ
  • 2005-05-06 Added - Masao?
更新日時:2014/06/16 15:41:39
キーワード:
参照:[Ruby/GTK] [Gtk::MenuToolButton] [Gtk::ToolButton] [Ruby/GTK Object Hierarchy]