# class Gtk::Button

### Public Class Methods

new(options={}) click to toggle source

    # File lib/gtk3/button.rb, line 20
    def initialize(options={})
      label = options[:label]
      use_underline = options[:use_underline]
      if use_underline.nil?
        mnemonic = options[:mnemonic]
        if mnemonic
          label = mnemonic
          use_underline = true
        end
      end
      stock = options[:stock_id]
      icon_name = options[:icon_name]
      icon_size = options[:icon_size] || :button

      if label
        if use_underline
          initialize_new_with_mnemonic(label)
        else
          initialize_new_with_label(label)
        end
      elsif stock
        initialize_new_from_stock(stock)
      elsif icon_name
        case icon_size
        when Symbol, String
          icon_size = IconSize.new(icon_size.to_s)
        end
        initialize_new_from_icon_name(icon_name, icon_size)
      else
        initialize_raw
      end
    end

Also aliased as: initialize_raw

### Public Instance Methods

initialize_raw(options={})
Alias for: new