Gtk2::Style(3)

NAME
Gtk2::Style

HIERARCHY
  Glib::Object
  +----Gtk2::Style

METHODS

  style = Gtk2::Style->new

  $style->apply_default_background ($window, $set_bg, $state_type, $area, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Window)
    * $set_bg (boolean)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  style = $style->attach ($window)

    * $window (Gtk2::Gdk::Window)

  boolean = $style->attached

  $style->set_background ($window, $state_type)
    * $window (Gtk2::Gdk::Window)
    * $state_type (Gtk2::StateType)

  color = $style->base ($state)

    * $state (Gtk2::StateType)

  gc = $style->base_gc ($state)
    * $state (Gtk2::StateType)

  color = $style->bg ($state)

    * $state (Gtk2::StateType)

  gc = $style->bg_gc ($state)
    * $state (Gtk2::StateType)

  pixmap = $style->bg_pixmap ($state, $pixmap=undef)

    * $state (Gtk2::StateType)
    * $pixmap (Gtk2::Gdk::Pixmap or undef)

  scalar = $style->black

  scalar = $style->black_gc

  style = $style->copy

  color = $style->dark ($state)

    * $state (Gtk2::StateType)

  gc = $style->dark_gc ($state)
    * $state (Gtk2::StateType)

  $style->detach

  Gtk2->draw_insertion_cursor ($widget, $drawable, $area, $location, $is_primary, $direction, $draw_arrow)

    * $widget (Gtk2::Widget)
    * $drawable (Gtk2::Gdk::Drawable)
    * $area (Gtk2::Gdk::Rectangle)
    * $location (Gtk2::Gdk::Rectangle)
    * $is_primary (boolean)
    * $direction (Gtk2::TextDirection)
    * $draw_arrow (boolean)

    Since: gtk+ 2.4

  color = $style->fg ($state)

    * $state (Gtk2::StateType)

  gc = $style->fg_gc ($state)
    * $state (Gtk2::StateType)

  scalar = $style->font_desc

  color = $style->light ($state)

    * $state (Gtk2::StateType)

  gc = $style->light_gc ($state)
    * $state (Gtk2::StateType)

  color = $style->lookup_color ($color_name)

    * $color_name (string)

    Since: gtk+ 2.10

  iconset = $style->lookup_icon_set ($stock_id)

    * $stock_id (string)

  color = $style->mid ($state)
    * $state (Gtk2::StateType)

  gc = $style->mid_gc ($state)

    * $state (Gtk2::StateType)

  $style->paint_arrow ($window, $state_type, $shadow_type, $area, $widget, $detail, $arrow_type, $fill, $x, $y, $width, $height)
    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $arrow_type (Gtk2::ArrowType)
    * $fill (boolean)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_box ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_box_gap ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height, $gap_side, $gap_x, $gap_width)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)
    * $gap_side (Gtk2::PositionType)
    * $gap_x (integer)
    * $gap_width (integer)

  $style->paint_check ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_diamond ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_expander ($window, $state_type, $area, $widget, $detail, $x, $y, $expander_style)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $expander_style (Gtk2::ExpanderStyle)

  $style->paint_extension ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height, $gap_side)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)
    * $gap_side (Gtk2::PositionType)

  $style->paint_flat_box ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_focus ($window, $state_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_handle ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height, $orientation)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)
    * $orientation (Gtk2::Orientation)

  $style->paint_hline ($window, $state_type, $area, $widget, $detail, $x1, $x2, $y)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x1 (integer)
    * $x2 (integer)
    * $y (integer)

  $style->paint_layout ($window, $state_type, $use_text, $area, $widget, $detail, $x, $y, $layout)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $use_text (boolean)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $layout (Gtk2::Pango::Layout)

  $style->paint_option ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_polygon ($window, $state_type, $shadow_type, $area, $widget, $detail, $fill, $x1, $y1, ...)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $fill (boolean)
    * $x1 (integer) x coordinate of the first vertex
    * $y1 (integer) y coordinate of the first vertex
    * ... (list) pairs of x and y coordinates

  $style->paint_resize_grip ($window, $state_type, $area, $widget, $detail, $edge, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $edge (Gtk2::Gdk::WindowEdge)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_shadow ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_shadow_gap ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height, $gap_side, $gap_x, $gap_width)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)
    * $gap_side (Gtk2::PositionType)
    * $gap_x (integer)
    * $gap_width (integer)

  $style->paint_slider ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height, $orientation)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)
    * $orientation (Gtk2::Orientation)

  $style->paint_tab ($window, $state_type, $shadow_type, $area, $widget, $detail, $x, $y, $width, $height)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $shadow_type (Gtk2::ShadowType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget)
    * $detail (string or undef)
    * $x (integer)
    * $y (integer)
    * $width (integer)
    * $height (integer)

  $style->paint_vline ($window, $state_type, $area, $widget, $detail, $y1_, $y2_, $x)

    * $window (Gtk2::Gdk::Drawable)
    * $state_type (Gtk2::StateType)
    * $area (Gtk2::Gdk::Rectangle or undef)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)
    * $y1_ (integer)
    * $y2_ (integer)
    * $x (integer)

  pixbuf = $style->render_icon ($source, $direction, $state, $size, $widget, $detail=undef)

    * $source (Gtk2::IconSource)
    * $direction (Gtk2::TextDirection)
    * $state (Gtk2::StateType)
    * $size (Gtk2::IconSize)
    * $widget (Gtk2::Widget or undef)
    * $detail (string or undef)

  color = $style->text ($state)

    * $state (Gtk2::StateType)

  color = $style->text_aa ($state)
    * $state (Gtk2::StateType)

  gc = $style->text_aa_gc ($state)

    * $state (Gtk2::StateType)

  gc = $style->text_gc ($state)
    * $state (Gtk2::StateType)

  scalar = $style->white

  scalar = $style->white_gc

  scalar = $style->xthickness

  scalar = $style->ythickness

SIGNALS

realize (Gtk2::Style)
unrealize (Gtk2::Style)

ENUMS AND FLAGS

  enum Gtk2::ArrowType

* 'up' / 'GTK_ARROW_UP'
* 'down' / 'GTK_ARROW_DOWN'
* 'left' / 'GTK_ARROW_LEFT'
* 'right' / 'GTK_ARROW_RIGHT'
* 'none' / 'GTK_ARROW_NONE'

  enum Gtk2::ExpanderStyle

* 'collapsed' / 'GTK_EXPANDER_COLLAPSED'
* 'semi-collapsed' / 'GTK_EXPANDER_SEMI_COLLAPSED'
* 'semi-expanded' / 'GTK_EXPANDER_SEMI_EXPANDED'
* 'expanded' / 'GTK_EXPANDER_EXPANDED'

  enum Gtk2::Gdk::WindowEdge

* 'north-west' / 'GDK_WINDOW_EDGE_NORTH_WEST'
* 'north' / 'GDK_WINDOW_EDGE_NORTH'
* 'north-east' / 'GDK_WINDOW_EDGE_NORTH_EAST'
* 'west' / 'GDK_WINDOW_EDGE_WEST'
* 'east' / 'GDK_WINDOW_EDGE_EAST'
* 'south-west' / 'GDK_WINDOW_EDGE_SOUTH_WEST'
* 'south' / 'GDK_WINDOW_EDGE_SOUTH'
* 'south-east' / 'GDK_WINDOW_EDGE_SOUTH_EAST'

  enum Gtk2::IconSize

* 'invalid' / 'GTK_ICON_SIZE_INVALID'
* 'menu' / 'GTK_ICON_SIZE_MENU'
* 'small-toolbar' / 'GTK_ICON_SIZE_SMALL_TOOLBAR'
* 'large-toolbar' / 'GTK_ICON_SIZE_LARGE_TOOLBAR'
* 'button' / 'GTK_ICON_SIZE_BUTTON'
* 'dnd' / 'GTK_ICON_SIZE_DND'
* 'dialog' / 'GTK_ICON_SIZE_DIALOG'

  enum Gtk2::Orientation

* 'horizontal' / 'GTK_ORIENTATION_HORIZONTAL'
* 'vertical' / 'GTK_ORIENTATION_VERTICAL'

  enum Gtk2::PositionType

* 'left' / 'GTK_POS_LEFT'
* 'right' / 'GTK_POS_RIGHT'
* 'top' / 'GTK_POS_TOP'
* 'bottom' / 'GTK_POS_BOTTOM'

  enum Gtk2::ShadowType

* 'none' / 'GTK_SHADOW_NONE'
* 'in' / 'GTK_SHADOW_IN'
* 'out' / 'GTK_SHADOW_OUT'
* 'etched-in' / 'GTK_SHADOW_ETCHED_IN'
* 'etched-out' / 'GTK_SHADOW_ETCHED_OUT'

  enum Gtk2::StateType

* 'normal' / 'GTK_STATE_NORMAL'
* 'active' / 'GTK_STATE_ACTIVE'
* 'prelight' / 'GTK_STATE_PRELIGHT'
* 'selected' / 'GTK_STATE_SELECTED'
* 'insensitive' / 'GTK_STATE_INSENSITIVE'

  enum Gtk2::TextDirection

* 'none' / 'GTK_TEXT_DIR_NONE'
* 'ltr' / 'GTK_TEXT_DIR_LTR'
* 'rtl' / 'GTK_TEXT_DIR_RTL'

SEE ALSO
Gtk2, Glib::Object

COPYRIGHT
Copyright (C) 2003-2008 by the gtk2-perl team.

This software is licensed under the LGPL. See Gtk2 for a full notice.