gtk.InfoBar

gtk.InfoBar

Synopsis

class gtk.InfoBar(gtk.HBox):
    gtk.InfoBar()
def get_action_area()
def get_content_area()
def add_action_widget(child, response_id)
def add_button(button_text, response_id)
def add_buttons(first_button_text)
def set_response_sensitive(response_id, setting)
def set_default_response(response_id)
def response(response_id)
def set_message_type(message_type)
def get_message_type()

Ancestry

+-- GObject
  +-- gtk.Object
    +-- gtk.Widget
      +-- gtk.Container
        +-- gtk.Box
          +-- gtk.HBox
            +-- gtk.InfoBar

Constructor

          gtk.InfoBar()
    

Returns :

a new gtk.InfoBar object

Note

This constructor is available in PyGTK 2.18 and above.

Creates a new gtk.InfoBar object.

Methods

gtk.InfoBar.get_action_area

            def get_action_area()
      

Returns :

the action area

Note

This method is available in PyGTK 2.18 and above.

The get_action_area() method returns the action area of info_bar.

gtk.InfoBar.get_content_area

            def get_content_area()
      

Returns :

the content area

Note

This method is available in PyGTK 2.18 and above.

The get_content_area() method returns the content area of info_bar.

gtk.InfoBar.add_action_widget

            def add_action_widget(child, response_id)
      

child :

an activatable widget

response_id :

response ID for child

Note

This method is available in PyGTK 2.18 and above.

Add an activatable widget to the action area of a gtk.InfoBar, connecting a signal handler that will emit the gtk.InfoBar::response signal on the message area when the widget is activated. The widget is appended to the end of the message areas action area.

gtk.InfoBar.add_button

            def add_button(button_text, response_id)
      

button_text :

text of button, or stock ID

response_id :

response ID for the button

Returns :

the button widget that was added

Note

This method is available in PyGTK 2.18 and above.

Adds a button with the given text (or a stock button, if button_text is a stock ID) and sets things up so that clicking the button will emit the "response" signal with the given response_id. The button is appended to the end of the info bars's action area. The button widget is returned, but usually you don't need it.

gtk.InfoBar.add_buttons

            def add_buttons(first_button_text)
      

first_button_text :

button text or stock ID

Note

This method is available in PyGTK 2.18 and above.

Adds more buttons, same as calling gtk.InfoBar.add_button repeatedly. The variable argument list should be NULL-terminated as with gtk_info_bar_new_with_buttons(). Each button must have both text and response ID.

gtk.InfoBar.set_response_sensitive

            def set_response_sensitive(response_id, setting)
      

response_id :

a response ID

setting :

TRUE for sensitive

Note

This method is available in PyGTK 2.18 and above.

Calls gtk_widget_set_sensitive (widget, setting) for each widget in the info bars's action area with the given response_id. A convenient way to sensitize/desensitize dialog buttons.

gtk.InfoBar.set_default_response

            def set_default_response(response_id)
      

response_id :

a response ID

Note

This method is available in PyGTK 2.18 and above.

The set_default_response() method sets the last widget in the info bar's action area with the given response_id as the default widget for the dialog. Pressing "Enter" normally activates the default widget.

Note that this function currently requires info_bar to be added to a widget hierarchy.

gtk.InfoBar.response

            def response(response_id)
      

response_id :

a response ID

Note

This method is available in PyGTK 2.18 and above.

Emits the 'response' signal with the given response_id.

gtk.InfoBar.set_message_type

            def set_message_type(message_type)
      

message_type :

a GtkMessageType

Note

This method is available in PyGTK 2.18 and above.

The set_message_type() method sets the message type of the message area. GTK+ uses this type to determine what color to use when drawing the message area.

gtk.InfoBar.get_message_type

            def get_message_type()
      

Returns :

the message type of the message area.

Note

This method is available in PyGTK 2.18 and above.

The get_message_type() method returns the message type of the message area.