GtkGestureZoom

GtkGestureZoom — Zoom gesture

Functions

Types and Values

Includes

#include <gtk/gtk.h>

Description

GtkGestureZoom is a GtkGesture implementation able to recognize pinch/zoom gestures, whenever the distance between both tracked sequences changes, the “scale-changed” signal is emitted to report the scale factor.

Functions

gtk_gesture_zoom_new ()

GtkGesture *
gtk_gesture_zoom_new (GtkWidget *widget);

Returns a newly created GtkGesture that recognizes zoom in/out gestures (usually known as pinch/zoom).

Parameters

widget

a GtkWidget

 

Returns

a newly created GtkGestureZoom

Since: 3.14


gtk_gesture_zoom_get_scale_delta ()

gdouble
gtk_gesture_zoom_get_scale_delta (GtkGestureZoom *gesture);

If gesture is active, this function returns the zooming difference since the gesture was recognized (hence the starting point is considered 1:1). If gesture is not active, 1 is returned.

Parameters

gesture

a GtkGestureZoom

 

Returns

the scale delta

Since: 3.14

Types and Values

GtkGestureZoom

typedef struct _GtkGestureZoom GtkGestureZoom;

See Also

GtkGestureRotate