GtkViewport

GtkViewport — An adapter which makes widgets scrollable

Synopsis


#include <gtk/gtk.h>


                    GtkViewport;
GtkWidget*          gtk_viewport_new                    (GtkAdjustment *hadjustment,
                                                         GtkAdjustment *vadjustment);
GtkAdjustment*      gtk_viewport_get_hadjustment        (GtkViewport *viewport);
GtkAdjustment*      gtk_viewport_get_vadjustment        (GtkViewport *viewport);
void                gtk_viewport_set_hadjustment        (GtkViewport *viewport,
                                                         GtkAdjustment *adjustment);
void                gtk_viewport_set_vadjustment        (GtkViewport *viewport,
                                                         GtkAdjustment *adjustment);
void                gtk_viewport_set_shadow_type        (GtkViewport *viewport,
                                                         GtkShadowType type);
GtkShadowType       gtk_viewport_get_shadow_type        (GtkViewport *viewport);


Object Hierarchy


  GObject
   +----GInitiallyUnowned
         +----GtkObject
               +----GtkWidget
                     +----GtkContainer
                           +----GtkBin
                                 +----GtkViewport

Implemented Interfaces

GtkViewport implements AtkImplementorIface.

Properties


  "hadjustment"              GtkAdjustment         : Read / Write / Construct
  "shadow-type"              GtkShadowType         : Read / Write
  "vadjustment"              GtkAdjustment         : Read / Write / Construct

Signals


  "set-scroll-adjustments"                         : Run Last / Action

Description

Details

GtkViewport

typedef struct _GtkViewport GtkViewport;


gtk_viewport_new ()

GtkWidget*          gtk_viewport_new                    (GtkAdjustment *hadjustment,
                                                         GtkAdjustment *vadjustment);

Creates a new GtkViewport with the given adjustments.

hadjustment : horizontal adjustment.
vadjustment : vertical adjustment.
Returns : a new GtkViewport.

gtk_viewport_get_hadjustment ()

GtkAdjustment*      gtk_viewport_get_hadjustment        (GtkViewport *viewport);

Returns the horizontal adjustment of the viewport.

viewport : a GtkViewport.
Returns : the horizontal adjustment of viewport.

gtk_viewport_get_vadjustment ()

GtkAdjustment*      gtk_viewport_get_vadjustment        (GtkViewport *viewport);

Returns the vertical adjustment of the viewport.

viewport : a GtkViewport.
Returns : the vertical adjustment of viewport.

gtk_viewport_set_hadjustment ()

void                gtk_viewport_set_hadjustment        (GtkViewport *viewport,
                                                         GtkAdjustment *adjustment);

Sets the horizontal adjustment of the viewport.

viewport : a GtkViewport.
adjustment : a GtkAdjustment.

gtk_viewport_set_vadjustment ()

void                gtk_viewport_set_vadjustment        (GtkViewport *viewport,
                                                         GtkAdjustment *adjustment);

Sets the vertical adjustment of the viewport.

viewport : a GtkViewport.
adjustment : a GtkAdjustment.

gtk_viewport_set_shadow_type ()

void                gtk_viewport_set_shadow_type        (GtkViewport *viewport,
                                                         GtkShadowType type);

Sets the shadow type of the viewport.

viewport : a GtkViewport.
type : the new shadow type.

gtk_viewport_get_shadow_type ()

GtkShadowType       gtk_viewport_get_shadow_type        (GtkViewport *viewport);

Gets the shadow type of the GtkViewport. See gtk_viewport_set_shadow_type().

viewport : a GtkViewport
Returns : the shadow type

Property Details

The "hadjustment" property

  "hadjustment"              GtkAdjustment         : Read / Write / Construct

The GtkAdjustment that determines the values of the horizontal position for this viewport.


The "shadow-type" property

  "shadow-type"              GtkShadowType         : Read / Write

Determines how the shadowed box around the viewport is drawn.

Default value: GTK_SHADOW_IN


The "vadjustment" property

  "vadjustment"              GtkAdjustment         : Read / Write / Construct

The GtkAdjustment that determines the values of the vertical position for this viewport.

Signal Details

The "set-scroll-adjustments" signal

void                user_function                      (GtkViewport   *viewport,
                                                        GtkAdjustment *arg1,
                                                        GtkAdjustment *arg2,
                                                        gpointer       user_data)      : Run Last / Action

viewport : the object which received the signal.
arg1 :
arg2 :
user_data : user data set when the signal handler was connected.