#include <config.h>
#include <stdio.h>
#include "gschem.h"
Go to the source code of this file.
Defines |
#define | OVER_ZOOM_FACTOR 0.1 |
Enumerations |
enum | { PROP_FILENAME = 1,
PROP_BUFFER,
PROP_ACTIVE
} |
Functions |
static void | preview_class_init (PreviewClass *class) |
static void | preview_init (Preview *preview) |
static void | preview_set_property (GObject *object, guint property_id, const GValue *value, GParamSpec *pspec) |
static void | preview_get_property (GObject *object, guint property_id, GValue *value, GParamSpec *pspec) |
static void | preview_dispose (GObject *self) |
static void | preview_callback_realize (GtkWidget *widget, gpointer user_data) |
| Completes initialitation of the widget after realization.
|
static gboolean | preview_callback_expose (GtkWidget *widget, GdkEventExpose *event, gpointer user_data) |
| Redraws the view when widget is exposed.
|
static gboolean | preview_callback_button_press (GtkWidget *widget, GdkEventButton *event, gpointer user_data) |
| Handles the press on a mouse button.
|
static void | preview_update (Preview *preview) |
| Updates the preview widget.
|
GType | preview_get_type () |
static gboolean | preview_event_configure (GtkWidget *widget, GdkEventConfigure *event, gpointer user_data) |
static gboolean | preview_event_scroll (GtkWidget *widget, GdkEventScroll *event, GSCHEM_TOPLEVEL *w_current) |
Variables |
static GObjectClass * | preview_parent_class = NULL |
Define Documentation
#define OVER_ZOOM_FACTOR 0.1 |
Enumeration Type Documentation
- Enumerator:
PROP_FILENAME |
|
PROP_BUFFER |
|
PROP_ACTIVE |
|
Definition at line 42 of file x_preview.c.
Function Documentation
static void preview_class_init |
( |
PreviewClass * |
class | ) |
[static] |
static void preview_init |
( |
Preview * |
preview | ) |
[static] |
static void preview_set_property |
( |
GObject * |
object, |
|
|
guint |
property_id, |
|
|
const GValue * |
value, |
|
|
GParamSpec * |
pspec |
|
) |
| [static] |
static void preview_get_property |
( |
GObject * |
object, |
|
|
guint |
property_id, |
|
|
GValue * |
value, |
|
|
GParamSpec * |
pspec |
|
) |
| [static] |
static void preview_dispose |
( |
GObject * |
self | ) |
[static] |
static void preview_callback_realize |
( |
GtkWidget * |
widget, |
|
|
gpointer |
user_data |
|
) |
| [static] |
- Function Description
- This function terminates the initialization of preview's GSCHEM_TOPLEVEL and TOPLEVEL environments after the widget has been realized.
It creates a preview page in the TOPLEVEL environment.
- Parameters:
-
[in] | widget | The preview widget. |
[in] | user_data | Unused user data. |
Definition at line 74 of file x_preview.c.
static gboolean preview_callback_expose |
( |
GtkWidget * |
widget, |
|
|
GdkEventExpose * |
event, |
|
|
gpointer |
user_data |
|
) |
| [static] |
- Function Description
- It redraws the preview pixmap every time the widget is exposed.
- Parameters:
-
[in] | widget | The preview widget. |
[in] | event | The event structure. |
[in] | user_data | Unused user data. |
- Returns:
- FALSE to propagate the event further.
Definition at line 115 of file x_preview.c.
static gboolean preview_callback_button_press |
( |
GtkWidget * |
widget, |
|
|
GdkEventButton * |
event, |
|
|
gpointer |
user_data |
|
) |
| [static] |
- Function Description
- It handles the user inputs.
Three action are available: zoom in, pan and zoom out on preview display.
- Parameters:
-
[in] | widget | The preview widget. |
[in] | event | The event structure. |
[in] | user_data | Unused user data. |
- Returns:
- FALSE to propagate the event further.
Definition at line 157 of file x_preview.c.
static void preview_update |
( |
Preview * |
preview | ) |
[static] |
- Function Description
- This function update the preview: if the preview is active and a filename has been given, it opens the file and display it. Otherwise it display a blank page.
- Parameters:
-
[in] | preview | The preview widget. |
Definition at line 200 of file x_preview.c.
GType preview_get_type |
( |
void |
| ) |
|
static gboolean preview_event_configure |
( |
GtkWidget * |
widget, |
|
|
GdkEventConfigure * |
event, |
|
|
gpointer |
user_data |
|
) |
| [static] |
static gboolean preview_event_scroll |
( |
GtkWidget * |
widget, |
|
|
GdkEventScroll * |
event, |
|
|
GSCHEM_TOPLEVEL * |
w_current |
|
) |
| [static] |
Variable Documentation