gnome-mag: magnifier.c File Reference

# magnifier.c File Reference

`#include "config.h"`
`#include "magnifier.h"`
`#include "magnifier-private.h"`
`#include "zoom-region.h"`
`#include "zoom-region-private.h"`
`#include "gmag-cursor.h"`
`#include "gmag-graphical-server.h"`
`#include "GNOME_Magnifier.h"`
`#include <stdlib.h>`
`#include <string.h>`
`#include <strings.h>`
`#include <libbonobo.h>`
`#include <login-helper/login-helper.h>`
`#include <gdk-pixbuf/gdk-pixbuf-io.h>`
`#include <gdk/gdkx.h>`
`#include <gdk/gdk.h>`
`#include <gtk/gtk.h>`

Go to the source code of this file.

## Data Structures
struct | MagLoginHelper
struct | MagLoginHelperClass
struct | MagnifierZoomRegionSaveProps
## Defines
#define | DEBUG_CLIENT_CALLS
#define | DBG(a) if (client_debug) { (a); }
#define | GET_PIXEL(a, i, j, s, b) (*(guint32 *)(memcpy (b,(a) + ((j) * s + (i) * pixel_size_t), pixel_size_t)))
#define | PUT_PIXEL(a, i, j, s, b) (memcpy (a + ((j) * s + (i) * pixel_size_t), &(b), pixel_size_t))
## Enumerations
enum | { MAGNIFIER_SOURCE_DISPLAY_PROP, MAGNIFIER_TARGET_DISPLAY_PROP, MAGNIFIER_SOURCE_SIZE_PROP, MAGNIFIER_TARGET_SIZE_PROP, MAGNIFIER_CURSOR_SET_PROP, MAGNIFIER_CURSOR_SIZE_PROP, MAGNIFIER_CURSOR_ZOOM_PROP, MAGNIFIER_CURSOR_COLOR_PROP, MAGNIFIER_CURSOR_HOTSPOT_PROP, MAGNIFIER_CURSOR_DEFAULT_SIZE_PROP, MAGNIFIER_CROSSWIRE_SIZE_PROP, MAGNIFIER_CROSSWIRE_LENGTH_PROP, MAGNIFIER_CROSSWIRE_CLIP_PROP, MAGNIFIER_CROSSWIRE_COLOR_PROP }
## Functions
static void | magnifier_init_cursor_set (Magnifier *magnifier, gchar *cursor_set)
static void | magnifier_init_window (Magnifier *magnifier, GdkScreen *screen)
static gboolean | magnifier_reset_struts_at_idle (gpointer data)
static void | magnifier_adjust_source_size (Magnifier *magnifier)
static Window * | mag_login_helper_get_raise_windows (LoginHelper *helper)
static LoginHelperDeviceReqFlags | mag_login_helper_get_device_reqs (LoginHelper *helper)
static gboolean | mag_login_helper_set_safe (LoginHelper *helper, gboolean ignored)
static void | mag_login_helper_class_init (MagLoginHelperClass *klass)
static void | mag_login_helper_init (MagLoginHelper *helper)
static void | mag_login_helper_set_magnifier (MagLoginHelper *helper, Magnifier *mag)
| BONOBO_TYPE_FUNC (MagLoginHelper, LOGIN_HELPER_TYPE, mag_login_helper)
static void | magnifier_warp_cursor_to_screen (Magnifier *magnifier)
void | magnifier_zoom_regions_update_pointer (Magnifier *magnifier)
static void | magnifier_zoom_regions_mark_dirty (Magnifier *magnifier, GNOME_Magnifier_RectBounds rect_bounds)
void | magnifier_set_cursor_from_pixbuf (Magnifier *magnifier, GdkPixbuf *cursor_pixbuf)
GdkPixbuf * | magnifier_get_pixbuf_for_name (Magnifier *magnifier, const gchar *cursor_name)
void | magnifier_set_cursor_pixmap_by_name (Magnifier *magnifier, const gchar *cursor_name, gboolean source_fallback)
void | magnifier_notify_damage (Magnifier *magnifier, GdkRectangle *rect)
static void | magnifier_set_extension_listeners (Magnifier *magnifier, GdkWindow *root)
static void | magnifier_size_allocate (GtkWidget *widget)
static void | magnifier_realize (GtkWidget *widget)
GdkWindow * | magnifier_get_root (Magnifier *magnifier)
static gint | magnifier_parse_display_name (Magnifier *magnifier, gchar *full_display_string, gchar **display_name)
static void | magnifier_get_display_rect_bounds (Magnifier *magnifier, GNOME_Magnifier_RectBounds *rect_bounds, gboolean is_target)
gboolean | magnifier_full_screen_capable (Magnifier *magnifier)
static void | magnifier_unref_zoom_region (gpointer data, gpointer user_data)
static GSList * | magnifier_zoom_regions_save (Magnifier *magnifier)
static void | magnifier_zoom_regions_restore (Magnifier *magnifier, GSList *region_params)
static void | magnifier_init_display (Magnifier *magnifier, gchar *display_name, gboolean is_target)
static void | magnifier_exit (GtkObject *object)
static void | magnifier_recolor_pixbuf (Magnifier *magnifier, GdkPixbuf *pixbuf)
void | magnifier_transform_cursor (Magnifier *magnifier)
static void | magnifier_get_property (BonoboPropertyBag *bag, BonoboArg *arg, guint arg_id, CORBA_Environment *ev, gpointer user_data)
static void | magnifier_set_property (BonoboPropertyBag *bag, BonoboArg *arg, guint arg_id, CORBA_Environment *ev, gpointer user_data)
static void | magnifier_do_dispose (Magnifier *magnifier)
static void | magnifier_gobject_dispose (GObject *object)
static CORBA_boolean | impl_magnifier_support_colorblind_filters (Magnifier *magnifier)
static void | impl_magnifier_hide_cursor (PortableServer_Servant servant, CORBA_Environment *ev)
static void | impl_magnifier_show_cursor (PortableServer_Servant servant, CORBA_Environment *ev)
static CORBA_boolean | impl_magnifier_full_screen_capable (PortableServer_Servant servant, CORBA_Environment *ev)
static void | impl_magnifier_set_source_display (PortableServer_Servant servant, const CORBA_char *display, CORBA_Environment *ev)
static void | impl_magnifier_set_target_display (PortableServer_Servant servant, const CORBA_char *display, CORBA_Environment *ev)
static CORBA_string | impl_magnifier_get_source_display (PortableServer_Servant servant, CORBA_Environment *ev)
static CORBA_string | impl_magnifier_get_target_display (PortableServer_Servant servant, CORBA_Environment *ev)
static GNOME_Magnifier_ZoomRegion | impl_magnifier_create_zoom_region (PortableServer_Servant servant, const CORBA_float zx, const CORBA_float zy, const GNOME_Magnifier_RectBounds *roi, const GNOME_Magnifier_RectBounds *viewport, CORBA_Environment *ev)
static CORBA_boolean | impl_magnifier_add_zoom_region (PortableServer_Servant servant, const GNOME_Magnifier_ZoomRegion region, CORBA_Environment *ev)
static Bonobo_PropertyBag | impl_magnifier_get_properties (PortableServer_Servant servant, CORBA_Environment *ev)
GNOME_Magnifier_ZoomRegionList * | impl_magnifier_get_zoom_regions (PortableServer_Servant servant, CORBA_Environment *ev)
static void | impl_magnifier_clear_all_zoom_regions (PortableServer_Servant servant, CORBA_Environment *ev)
static void | impl_magnifier_dispose (PortableServer_Servant servant, CORBA_Environment *ev)
static void | magnifier_class_init (MagnifierClass *klass)
static void | magnifier_properties_init (Magnifier *magnifier)
static void | magnifier_init (Magnifier *magnifier)
GdkDrawable * | magnifier_get_cursor (Magnifier *magnifier)
Magnifier * | magnifier_new (gboolean override_redirect)
## Variables
static gboolean | client_debug = FALSE
static GObjectClass * | parent_class = NULL
enum { ... } | PropIdx
gchar * | mag_prop_names [MAGNIFIER_CROSSWIRE_COLOR_PROP+1]
static Magnifier * | _this_magnifier = NULL
gint | fixes_event_base
static gboolean | _is_override_redirect = FALSE

## Define Documentation

#define DEBUG_CLIENT_CALLS

Definition at line 45 of file magnifier.c.

#define DBG | ( | a |  | ) | if (client_debug) { (a); }

Definition at line 49 of file magnifier.c.

Referenced by impl_magnifier_create_zoom_region(), impl_magnifier_get_source_display(), impl_magnifier_get_target_display(), impl_magnifier_get_zoom_regions(), impl_magnifier_set_source_display(), impl_magnifier_set_target_display(), impl_zoom_region_set_brightness(), impl_zoom_region_set_contrast(), impl_zoom_region_set_pointer_pos(), impl_zoom_region_set_roi(), magnifier_get_property(), magnifier_set_cursor_from_pixbuf(), magnifier_set_property(), magnifier_transform_cursor(), magnifier_unref_zoom_region(), magnifier_zoom_regions_save(), zoom_region_calculate_scroll_rects(), zoom_region_do_dispose(), zoom_region_finalize(), zoom_region_get_property(), zoom_region_init(), zoom_region_init_window(), and zoom_region_set_property().

#define GET_PIXEL | ( | a,
|  | i,
|  | j,
|  | s,
|  | b |  | ) | (*(guint32 *)(memcpy (b,(a) + ((j) * s + (i) * pixel_size_t), pixel_size_t)))

Definition at line 683 of file magnifier.c.

Referenced by magnifier_recolor_pixbuf().

#define PUT_PIXEL | ( | a,
|  | i,
|  | j,
|  | s,
|  | b |  | ) | (memcpy (a + ((j) * s + (i) * pixel_size_t), &(b), pixel_size_t))

Definition at line 686 of file magnifier.c.

Referenced by magnifier_recolor_pixbuf().

## Enumeration Type Documentation

anonymous enum

Enumerator:

  MAGNIFIER_SOURCE_DISPLAY_PROP |
  MAGNIFIER_TARGET_DISPLAY_PROP |
  MAGNIFIER_SOURCE_SIZE_PROP |
  MAGNIFIER_TARGET_SIZE_PROP |
  MAGNIFIER_CURSOR_SET_PROP |
  MAGNIFIER_CURSOR_SIZE_PROP |
  MAGNIFIER_CURSOR_ZOOM_PROP |
  MAGNIFIER_CURSOR_COLOR_PROP |
  MAGNIFIER_CURSOR_HOTSPOT_PROP |
  MAGNIFIER_CURSOR_DEFAULT_SIZE_PROP |
  MAGNIFIER_CROSSWIRE_SIZE_PROP |
  MAGNIFIER_CROSSWIRE_LENGTH_PROP |
  MAGNIFIER_CROSSWIRE_CLIP_PROP |
  MAGNIFIER_CROSSWIRE_COLOR_PROP |

Definition at line 67 of file magnifier.c.

## Function Documentation

static void magnifier_init_cursor_set | ( | Magnifier * | magnifier,
|  | gchar * | cursor_set |
| ) |  |  | `[static]`

Definition at line 812 of file magnifier.c.

References _MagnifierPrivate::cursor, Magnifier::cursor_set, _MagnifierPrivate::cursorlist, fixes_event_base, magnifier_set_cursor_pixmap_by_name(), magnifier_transform_cursor(), Magnifier::priv, and _MagnifierPrivate::use_source_cursor.

Referenced by magnifier_init(), and magnifier_set_property().

static void magnifier_init_window | ( | Magnifier * | magnifier,
|  | GdkScreen * | screen |
| ) |  |  | `[static]`

Definition at line 1680 of file magnifier.c.

References _is_override_redirect, _MagnifierPrivate::canvas, magnifier_exit(), magnifier_realize(), magnifier_size_allocate(), Magnifier::priv, _MagnifierPrivate::root, and _MagnifierPrivate::w.

Referenced by magnifier_init(), and magnifier_set_property().

static gboolean magnifier_reset_struts_at_idle | ( | gpointer | data | ) | `[static]`

Definition at line 874 of file magnifier.c.

References MAGNIFIER, Magnifier::priv, and _MagnifierPrivate::w.

Referenced by magnifier_new().

static void magnifier_adjust_source_size | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 469 of file magnifier.c.

References magnifier_full_screen_capable(), magnifier_get_display_rect_bounds(), Magnifier::source_bounds, Magnifier::target_bounds, GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_RectBounds_type::y1, and GNOME_Magnifier_RectBounds_type::y2.

Referenced by magnifier_set_property().

static Window* mag_login_helper_get_raise_windows | ( | LoginHelper * | helper | ) | `[static]`

Definition at line 132 of file magnifier.c.

References MagLoginHelper::mag, MAGNIFIER, Magnifier::priv, and _MagnifierPrivate::w.

Referenced by mag_login_helper_class_init().

static LoginHelperDeviceReqFlags mag_login_helper_get_device_reqs | ( | LoginHelper * | helper | ) | `[static]`

Definition at line 148 of file magnifier.c.

Referenced by mag_login_helper_class_init().

static gboolean mag_login_helper_set_safe | ( | LoginHelper * | helper,
|  | gboolean | ignored |
| ) |  |  | `[static]`

Definition at line 159 of file magnifier.c.

Referenced by mag_login_helper_class_init().

static void mag_login_helper_class_init | ( | MagLoginHelperClass * | klass | ) | `[static]`

Definition at line 165 of file magnifier.c.

References mag_login_helper_get_device_reqs(), mag_login_helper_get_raise_windows(), and mag_login_helper_set_safe().

static void mag_login_helper_init | ( | MagLoginHelper * | helper | ) | `[static]`

Definition at line 174 of file magnifier.c.

References MagLoginHelper::mag.

static void mag_login_helper_set_magnifier | ( | MagLoginHelper * | helper,
|  | Magnifier * | mag |
| ) |  |  | `[static]`

Definition at line 180 of file magnifier.c.

References MagLoginHelper::mag.

Referenced by magnifier_new().

BONOBO_TYPE_FUNC | ( | MagLoginHelper | ,
|  | LOGIN_HELPER_TYPE | ,
|  | mag_login_helper |  |
| ) |  |  |

Definition at line 186 of file magnifier.c.

static void magnifier_warp_cursor_to_screen | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 203 of file magnifier.c.

References Magnifier::priv, _MagnifierPrivate::root, and Magnifier::source_display.

Referenced by magnifier_set_property().

void magnifier_zoom_regions_update_pointer | ( | Magnifier * | magnifier | ) |

Definition at line 230 of file magnifier.c.

References GNOME_Magnifier_ZoomRegion_updatePointer(), zoom_region, and Magnifier::zoom_regions.

Referenced by magnifier_set_property().

static void magnifier_zoom_regions_mark_dirty | ( | Magnifier * | magnifier,
|  | GNOME_Magnifier_RectBounds | rect_bounds |
| ) |  |  | `[static]`

Definition at line 251 of file magnifier.c.

References GNOME_Magnifier_ZoomRegion_markDirty(), zoom_region, and Magnifier::zoom_regions.

Referenced by magnifier_notify_damage(), and magnifier_set_property().

void magnifier_set_cursor_from_pixbuf | ( | Magnifier * | magnifier,
|  | GdkPixbuf * | cursor_pixbuf |
| ) |  |  |

Definition at line 274 of file magnifier.c.

References _MagnifierPrivate::cursor, _MagnifierPrivate::cursor_default_size_x, _MagnifierPrivate::cursor_default_size_y, Magnifier::cursor_hotspot, _MagnifierPrivate::cursor_hotspot_x, _MagnifierPrivate::cursor_hotspot_y, _MagnifierPrivate::cursor_mask, DBG, Magnifier::priv, _MagnifierPrivate::w, GNOME_Magnifier_Point_type::x, and GNOME_Magnifier_Point_type::y.

Referenced by magnifier_get_cursor(), and magnifier_set_cursor_pixmap_by_name().

GdkPixbuf* magnifier_get_pixbuf_for_name | ( | Magnifier * | magnifier,
|  | const gchar * | cursor_name |
| ) |  |  |

Definition at line 329 of file magnifier.c.

References _MagnifierPrivate::cursorlist, and Magnifier::priv.

Referenced by magnifier_set_cursor_pixmap_by_name().

void magnifier_set_cursor_pixmap_by_name | ( | Magnifier * | magnifier,
|  | const gchar * | cursor_name,
|  | gboolean | source_fallback |
| ) |  |  |

Definition at line 340 of file magnifier.c.

References magnifier_get_pixbuf_for_name(), and magnifier_set_cursor_from_pixbuf().

Referenced by magnifier_init_cursor_set().

void magnifier_notify_damage | ( | Magnifier * | magnifier,
|  | GdkRectangle * | rect |
| ) |  |  |

Definition at line 361 of file magnifier.c.

References magnifier_zoom_regions_mark_dirty(), GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_RectBounds_type::y1, and GNOME_Magnifier_RectBounds_type::y2.

static void magnifier_set_extension_listeners | ( | Magnifier * | magnifier,
|  | GdkWindow * | root |
| ) |  |  | `[static]`

Definition at line 378 of file magnifier.c.

References Magnifier::source_initialized.

Referenced by impl_magnifier_add_zoom_region(), and magnifier_set_property().

static void magnifier_size_allocate | ( | GtkWidget * | widget | ) | `[static]`

Definition at line 385 of file magnifier.c.

Referenced by magnifier_init_window(), and magnifier_set_property().

static void magnifier_realize | ( | GtkWidget * | widget | ) | `[static]`

Definition at line 391 of file magnifier.c.

Referenced by magnifier_init_window(), and magnifier_set_property().

GdkWindow* magnifier_get_root | ( | Magnifier * | magnifier | ) |

Definition at line 397 of file magnifier.c.

References Magnifier::priv, _MagnifierPrivate::root, Magnifier::source_display, and Magnifier::source_screen_num.

Referenced by impl_magnifier_add_zoom_region(), magnifier_main_pan_image(), magnifier_set_property(), and zoom_region_update_pointer().

static gint magnifier_parse_display_name | ( | Magnifier * | magnifier,
|  | gchar * | full_display_string,
|  | gchar ** | display_name |
| ) |  |  | `[static]`

Definition at line 408 of file magnifier.c.

Referenced by magnifier_init_display(), and magnifier_set_property().

static void magnifier_get_display_rect_bounds | ( | Magnifier * | magnifier,
|  | GNOME_Magnifier_RectBounds * | rect_bounds,
|  | gboolean | is_target |
| ) |  |  | `[static]`

Definition at line 429 of file magnifier.c.

References Magnifier::source_display, Magnifier::source_screen_num, Magnifier::target_display, Magnifier::target_screen_num, GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_RectBounds_type::y1, and GNOME_Magnifier_RectBounds_type::y2.

Referenced by magnifier_adjust_source_size(), magnifier_properties_init(), and magnifier_set_property().

gboolean magnifier_full_screen_capable | ( | Magnifier * | magnifier | ) |

Definition at line 458 of file magnifier.c.

References Magnifier::source_display_name, and Magnifier::target_display_name.

Referenced by magnifier_adjust_source_size().

static void magnifier_unref_zoom_region | ( | gpointer | data,
|  | gpointer | user_data |
| ) |  |  | `[static]`

Definition at line 523 of file magnifier.c.

References DBG, GNOME_Magnifier_ZoomRegion_dispose(), and zoom_region.

Referenced by impl_magnifier_clear_all_zoom_regions(), and magnifier_zoom_regions_save().

static GSList* magnifier_zoom_regions_save | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 538 of file magnifier.c.

References MagnifierZoomRegionSaveProps::border_color, MagnifierZoomRegionSaveProps::border_size, MagnifierZoomRegionSaveProps::contrast, DBG, GNOME_Magnifier_ZoomRegion_getProperties(), GNOME_Magnifier_ZoomRegion_getROI(), MagnifierZoomRegionSaveProps::inverse, MagnifierZoomRegionSaveProps::is_managed, magnifier_unref_zoom_region(), MagnifierZoomRegionSaveProps::rectbounds, MagnifierZoomRegionSaveProps::scroll_policy, MagnifierZoomRegionSaveProps::smoothing_type, TC_GNOME_Magnifier_RectBounds, MagnifierZoomRegionSaveProps::viewport, MagnifierZoomRegionSaveProps::xalign, MagnifierZoomRegionSaveProps::yalign, zoom_region, Magnifier::zoom_regions, MagnifierZoomRegionSaveProps::zx, and MagnifierZoomRegionSaveProps::zy.

Referenced by magnifier_set_property().

static void magnifier_zoom_regions_restore | ( | Magnifier * | magnifier,
|  | GSList * | region_params |
| ) |  |  | `[static]`

Definition at line 590 of file magnifier.c.

References MagnifierZoomRegionSaveProps::border_color, MagnifierZoomRegionSaveProps::border_size, MagnifierZoomRegionSaveProps::contrast, GNOME_Magnifier_Magnifier_addZoomRegion(), GNOME_Magnifier_Magnifier_createZoomRegion(), GNOME_Magnifier_ZoomRegion_getProperties(), MagnifierZoomRegionSaveProps::inverse, MagnifierZoomRegionSaveProps::is_managed, MagnifierZoomRegionSaveProps::rectbounds, MagnifierZoomRegionSaveProps::scroll_policy, MagnifierZoomRegionSaveProps::smoothing_type, MagnifierZoomRegionSaveProps::viewport, MagnifierZoomRegionSaveProps::zx, and MagnifierZoomRegionSaveProps::zy.

Referenced by magnifier_set_property().

static void magnifier_init_display | ( | Magnifier * | magnifier,
|  | gchar * | display_name,
|  | gboolean | is_target |
| ) |  |  | `[static]`

Definition at line 634 of file magnifier.c.

References magnifier_parse_display_name(), Magnifier::priv, _MagnifierPrivate::root, Magnifier::source_display, Magnifier::source_display_name, Magnifier::source_screen_num, Magnifier::target_display, Magnifier::target_display_name, and Magnifier::target_screen_num.

Referenced by magnifier_properties_init().

static void magnifier_exit | ( | GtkObject * | object | ) | `[static]`

Definition at line 677 of file magnifier.c.

Referenced by magnifier_init_window(), and magnifier_set_property().

static void magnifier_recolor_pixbuf | ( | Magnifier * | magnifier,
|  | GdkPixbuf * | pixbuf |
| ) |  |  | `[static]`

Definition at line 690 of file magnifier.c.

References Magnifier::cursor_color, GET_PIXEL, and PUT_PIXEL.

Referenced by magnifier_transform_cursor().

void magnifier_transform_cursor | ( | Magnifier * | magnifier | ) |

Definition at line 717 of file magnifier.c.

References _MagnifierPrivate::cursor, Magnifier::cursor_color, _MagnifierPrivate::cursor_default_size_x, _MagnifierPrivate::cursor_default_size_y, Magnifier::cursor_hotspot, _MagnifierPrivate::cursor_hotspot_x, _MagnifierPrivate::cursor_hotspot_y, _MagnifierPrivate::cursor_mask, Magnifier::cursor_scale_factor, Magnifier::cursor_size_x, Magnifier::cursor_size_y, DBG, magnifier_recolor_pixbuf(), Magnifier::priv, _MagnifierPrivate::w, GNOME_Magnifier_Point_type::x, and GNOME_Magnifier_Point_type::y.

Referenced by magnifier_get_cursor(), magnifier_init_cursor_set(), and magnifier_set_property().

static void magnifier_get_property | ( | BonoboPropertyBag * | bag,
|  | BonoboArg * | arg,
|  | guint | arg_id,
|  | CORBA_Environment * | ev,
|  | gpointer | user_data |
| ) |  |  | `[static]`

Definition at line 889 of file magnifier.c.

References Magnifier::crosswire_clip, Magnifier::crosswire_color, Magnifier::crosswire_length, Magnifier::crosswire_size, _MagnifierPrivate::cursor, Magnifier::cursor_color, Magnifier::cursor_hotspot, Magnifier::cursor_scale_factor, Magnifier::cursor_set, Magnifier::cursor_size_x, Magnifier::cursor_size_y, DBG, ex_Bonobo_PropertyBag_NotFound, mag_prop_names, MAGNIFIER_CROSSWIRE_CLIP_PROP, MAGNIFIER_CROSSWIRE_COLOR_PROP, MAGNIFIER_CROSSWIRE_LENGTH_PROP, MAGNIFIER_CROSSWIRE_SIZE_PROP, MAGNIFIER_CURSOR_COLOR_PROP, MAGNIFIER_CURSOR_DEFAULT_SIZE_PROP, MAGNIFIER_CURSOR_HOTSPOT_PROP, MAGNIFIER_CURSOR_SET_PROP, MAGNIFIER_CURSOR_SIZE_PROP, MAGNIFIER_CURSOR_ZOOM_PROP, MAGNIFIER_SOURCE_DISPLAY_PROP, MAGNIFIER_SOURCE_SIZE_PROP, MAGNIFIER_TARGET_DISPLAY_PROP, MAGNIFIER_TARGET_SIZE_PROP, Magnifier::priv, Magnifier::source_bounds, Magnifier::source_display_name, Magnifier::target_bounds, Magnifier::target_display_name, TC_GNOME_Magnifier_Point, and TC_GNOME_Magnifier_RectBounds.

Referenced by magnifier_properties_init().

static void magnifier_set_property | ( | BonoboPropertyBag * | bag,
|  | BonoboArg * | arg,
|  | guint | arg_id,
|  | CORBA_Environment * | ev,
|  | gpointer | user_data |
| ) |  |  | `[static]`

Definition at line 963 of file magnifier.c.

References Magnifier::crosswire_clip, Magnifier::crosswire_color, Magnifier::crosswire_length, Magnifier::crosswire_size, Magnifier::cursor_color, Magnifier::cursor_hotspot, Magnifier::cursor_scale_factor, Magnifier::cursor_set, Magnifier::cursor_size_x, Magnifier::cursor_size_y, DBG, ex_Bonobo_PropertyBag_NotFound, ex_Bonobo_PropertyBag_ReadOnly, magnifier_adjust_source_size(), MAGNIFIER_CROSSWIRE_CLIP_PROP, MAGNIFIER_CROSSWIRE_COLOR_PROP, MAGNIFIER_CROSSWIRE_LENGTH_PROP, MAGNIFIER_CROSSWIRE_SIZE_PROP, MAGNIFIER_CURSOR_COLOR_PROP, MAGNIFIER_CURSOR_DEFAULT_SIZE_PROP, MAGNIFIER_CURSOR_HOTSPOT_PROP, MAGNIFIER_CURSOR_SET_PROP, MAGNIFIER_CURSOR_SIZE_PROP, MAGNIFIER_CURSOR_ZOOM_PROP, magnifier_exit(), magnifier_get_display_rect_bounds(), magnifier_get_root(), magnifier_init_cursor_set(), magnifier_init_window(), magnifier_parse_display_name(), magnifier_realize(), magnifier_set_extension_listeners(), magnifier_size_allocate(), MAGNIFIER_SOURCE_DISPLAY_PROP, MAGNIFIER_SOURCE_SIZE_PROP, MAGNIFIER_TARGET_DISPLAY_PROP, MAGNIFIER_TARGET_SIZE_PROP, magnifier_transform_cursor(), magnifier_warp_cursor_to_screen(), magnifier_zoom_regions_mark_dirty(), magnifier_zoom_regions_restore(), magnifier_zoom_regions_save(), magnifier_zoom_regions_update_pointer(), _MagnifierPrivate::overlay, Magnifier::priv, _MagnifierPrivate::root, Magnifier::source_bounds, Magnifier::source_display, Magnifier::source_display_name, _MagnifierPrivate::source_drawable, Magnifier::source_screen_num, Magnifier::target_bounds, Magnifier::target_display, Magnifier::target_display_name, Magnifier::target_screen_num, TC_GNOME_Magnifier_Point, TC_GNOME_Magnifier_RectBounds, _MagnifierPrivate::w, GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_RectBounds_type::y1, and GNOME_Magnifier_RectBounds_type::y2.

Referenced by impl_magnifier_set_source_display(), impl_magnifier_set_target_display(), and magnifier_properties_init().

static void magnifier_do_dispose | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 1196 of file magnifier.c.

References MAGNIFIER_OAFIID, and Magnifier::zoom_regions.

Referenced by impl_magnifier_dispose(), and magnifier_gobject_dispose().

static void magnifier_gobject_dispose | ( | GObject * | object | ) | `[static]`

Definition at line 1210 of file magnifier.c.

References MAGNIFIER, and magnifier_do_dispose().

Referenced by magnifier_class_init().

static CORBA_boolean impl_magnifier_support_colorblind_filters | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 1219 of file magnifier.c.

Referenced by magnifier_class_init().

static void impl_magnifier_hide_cursor | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1229 of file magnifier.c.

References MAGNIFIER.

Referenced by magnifier_class_init().

static void impl_magnifier_show_cursor | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1238 of file magnifier.c.

References MAGNIFIER.

Referenced by magnifier_class_init().

static CORBA_boolean impl_magnifier_full_screen_capable | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1248 of file magnifier.c.

References MAGNIFIER, Magnifier::source_display_name, and Magnifier::target_display_name.

Referenced by magnifier_class_init().

static void impl_magnifier_set_source_display | ( | PortableServer_Servant | servant,
|  | const CORBA_char * | display,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1262 of file magnifier.c.

References DBG, MAGNIFIER, magnifier_set_property(), MAGNIFIER_SOURCE_DISPLAY_PROP, Magnifier::property_bag, and Magnifier::source_display_name.

Referenced by magnifier_class_init().

static void impl_magnifier_set_target_display | ( | PortableServer_Servant | servant,
|  | const CORBA_char * | display,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1295 of file magnifier.c.

References DBG, MAGNIFIER, magnifier_set_property(), MAGNIFIER_TARGET_DISPLAY_PROP, Magnifier::property_bag, and Magnifier::target_display_name.

Referenced by magnifier_class_init().

static CORBA_string impl_magnifier_get_source_display | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1330 of file magnifier.c.

References DBG, MAGNIFIER, and Magnifier::source_display_name.

Referenced by magnifier_class_init().

static CORBA_string impl_magnifier_get_target_display | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1341 of file magnifier.c.

References DBG, MAGNIFIER, and Magnifier::target_display_name.

Referenced by magnifier_class_init().

static GNOME_Magnifier_ZoomRegion impl_magnifier_create_zoom_region | ( | PortableServer_Servant | servant,
|  | const CORBA_float | zx,
|  | const CORBA_float | zy,
|  | const GNOME_Magnifier_RectBounds * | roi,
|  | const GNOME_Magnifier_RectBounds * | viewport,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1352 of file magnifier.c.

References Bonobo_PropertyBag_setValue(), _MagnifierPrivate::canvas, DBG, GNOME_Magnifier_ZoomRegion_getProperties(), GNOME_Magnifier_ZoomRegion_setMagFactor(), GNOME_Magnifier_ZoomRegion_setROI(), MAGNIFIER, _ZoomRegionPrivate::parent, Magnifier::priv, ZoomRegion::priv, TC_GNOME_Magnifier_RectBounds, _MagnifierPrivate::w, GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_RectBounds_type::y1, GNOME_Magnifier_RectBounds_type::y2, zoom_region, and zoom_region_new().

Referenced by magnifier_class_init().

static CORBA_boolean impl_magnifier_add_zoom_region | ( | PortableServer_Servant | servant,
|  | const GNOME_Magnifier_ZoomRegion | region,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1412 of file magnifier.c.

References MAGNIFIER, magnifier_get_root(), magnifier_set_extension_listeners(), Magnifier::source_initialized, and Magnifier::zoom_regions.

Referenced by magnifier_class_init().

static Bonobo_PropertyBag impl_magnifier_get_properties | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1431 of file magnifier.c.

References MAGNIFIER, and Magnifier::property_bag.

Referenced by magnifier_class_init().

GNOME_Magnifier_ZoomRegionList* impl_magnifier_get_zoom_regions | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  |

Definition at line 1440 of file magnifier.c.

References CORBA_sequence_CORBA_Object::_buffer, CORBA_sequence_CORBA_Object::_length, DBG, GNOME_Magnifier_ZoomRegionList__alloc, GNOME_Magnifier_ZoomRegionList_allocbuf, MAGNIFIER, and Magnifier::zoom_regions.

Referenced by magnifier_class_init().

static void impl_magnifier_clear_all_zoom_regions | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1468 of file magnifier.c.

References MAGNIFIER, magnifier_unref_zoom_region(), and Magnifier::zoom_regions.

Referenced by magnifier_class_init().

static void impl_magnifier_dispose | ( | PortableServer_Servant | servant,
|  | CORBA_Environment * | ev |
| ) |  |  | `[static]`

Definition at line 1481 of file magnifier.c.

References MAGNIFIER, and magnifier_do_dispose().

Referenced by magnifier_class_init().

static void magnifier_class_init | ( | MagnifierClass * | klass | ) | `[static]`

Definition at line 1489 of file magnifier.c.

References POA_GNOME_Magnifier_Magnifier__epv::_get_SourceDisplay, POA_GNOME_Magnifier_Magnifier__epv::_get_TargetDisplay, POA_GNOME_Magnifier_Magnifier__epv::_set_SourceDisplay, POA_GNOME_Magnifier_Magnifier__epv::_set_TargetDisplay, POA_GNOME_Magnifier_Magnifier__epv::addZoomRegion, POA_GNOME_Magnifier_Magnifier__epv::clearAllZoomRegions, POA_GNOME_Magnifier_Magnifier__epv::createZoomRegion, POA_GNOME_Magnifier_Magnifier__epv::dispose, MagnifierClass::epv, POA_GNOME_Magnifier_Magnifier__epv::fullScreenCapable, POA_GNOME_Magnifier_Magnifier__epv::getProperties, POA_GNOME_Magnifier_Magnifier__epv::getZoomRegions, POA_GNOME_Magnifier_Magnifier__epv::hideCursor, impl_magnifier_add_zoom_region(), impl_magnifier_clear_all_zoom_regions(), impl_magnifier_create_zoom_region(), impl_magnifier_dispose(), impl_magnifier_full_screen_capable(), impl_magnifier_get_properties(), impl_magnifier_get_source_display(), impl_magnifier_get_target_display(), impl_magnifier_get_zoom_regions(), impl_magnifier_hide_cursor(), impl_magnifier_set_source_display(), impl_magnifier_set_target_display(), impl_magnifier_show_cursor(), impl_magnifier_support_colorblind_filters(), magnifier_gobject_dispose(), parent_class, POA_GNOME_Magnifier_Magnifier__epv::showCursor, and POA_GNOME_Magnifier_Magnifier__epv::supportColorblindFilters.

static void magnifier_properties_init | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 1515 of file magnifier.c.

References Bonobo_PROPERTY_READABLE, Bonobo_PROPERTY_WRITEABLE, MAGNIFIER_CROSSWIRE_CLIP_PROP, MAGNIFIER_CROSSWIRE_COLOR_PROP, MAGNIFIER_CROSSWIRE_LENGTH_PROP, MAGNIFIER_CROSSWIRE_SIZE_PROP, MAGNIFIER_CURSOR_COLOR_PROP, MAGNIFIER_CURSOR_DEFAULT_SIZE_PROP, MAGNIFIER_CURSOR_HOTSPOT_PROP, MAGNIFIER_CURSOR_SET_PROP, MAGNIFIER_CURSOR_SIZE_PROP, MAGNIFIER_CURSOR_ZOOM_PROP, magnifier_get_display_rect_bounds(), magnifier_get_property(), magnifier_init_display(), magnifier_set_property(), MAGNIFIER_SOURCE_DISPLAY_PROP, MAGNIFIER_SOURCE_SIZE_PROP, MAGNIFIER_TARGET_DISPLAY_PROP, MAGNIFIER_TARGET_SIZE_PROP, Magnifier::property_bag, TC_GNOME_Magnifier_Point, and TC_GNOME_Magnifier_RectBounds.

Referenced by magnifier_init().

static void magnifier_init | ( | Magnifier * | magnifier | ) | `[static]`

Definition at line 1708 of file magnifier.c.

References client_debug, Magnifier::crosswire_clip, Magnifier::crosswire_color, Magnifier::crosswire_length, Magnifier::crosswire_size, _MagnifierPrivate::cursor, Magnifier::cursor_color, Magnifier::cursor_hotspot, Magnifier::cursor_scale_factor, Magnifier::cursor_size_x, Magnifier::cursor_size_y, _MagnifierPrivate::cursorlist, timing::frame, timing::idle, mag_timing, magnifier_init_cursor_set(), magnifier_init_window(), magnifier_properties_init(), _MagnifierPrivate::overlay, Magnifier::priv, timing::process, timing::scale, Magnifier::source_display_name, _MagnifierPrivate::source_drawable, Magnifier::source_screen_num, Magnifier::target_bounds, Magnifier::target_display, Magnifier::target_display_name, Magnifier::target_screen_num, _MagnifierPrivate::use_source_cursor, _MagnifierPrivate::w, GNOME_Magnifier_Point_type::x, GNOME_Magnifier_RectBounds_type::x1, GNOME_Magnifier_RectBounds_type::x2, GNOME_Magnifier_Point_type::y, GNOME_Magnifier_RectBounds_type::y1, GNOME_Magnifier_RectBounds_type::y2, and Magnifier::zoom_regions.

GdkDrawable* magnifier_get_cursor | ( | Magnifier * | magnifier | ) |

Definition at line 1752 of file magnifier.c.

References _MagnifierPrivate::cursor, Magnifier::cursor_set, fixes_event_base, magnifier_set_cursor_from_pixbuf(), magnifier_transform_cursor(), and Magnifier::priv.

Referenced by zoom_region_cursor_rect(), zoom_region_paint_crosswire_cursor(), and zoom_region_paint_cursor().

Magnifier* magnifier_new | ( | gboolean | override_redirect | ) |

Definition at line 1781 of file magnifier.c.

References _is_override_redirect, mag_login_helper_set_magnifier(), magnifier_get_type(), MAGNIFIER_OAFIID, and magnifier_reset_struts_at_idle().

Referenced by main().

## Variable Documentation

gboolean client_debug = FALSE`[static]`

Definition at line 48 of file magnifier.c.

Referenced by magnifier_init(), and zoom_region_class_init().

GObjectClass* parent_class = NULL`[static]`

Definition at line 65 of file magnifier.c.

Referenced by magnifier_class_init(), and zoom_region_class_init().

enum { ... } PropIdx

gchar* mag_prop_names[MAGNIFIER_CROSSWIRE_COLOR_PROP+1]

Initial value:

     {
        "SOURCE_DISPLAY",
        "TARGET_DISPLAY",
        "SOURCE_SIZE",
        "TARGET_SIZE",
        "CURSOR_SET",
        "CURSOR_SIZE",
        "CURSOR_ZOOM",
        "CURSOR_COLOR",
        "CURSOR_HOTSPOT",
        "CURSOR_DEFAULT_SIZE",
        "CROSSWIRE_SIZE",
        "CROSSWIRE_LENGTH",
        "CROSSWIRE_CLIP",
        "CROSSWIRE_COLOR"
    }

Definition at line 103 of file magnifier.c.

Referenced by magnifier_get_property().

Magnifier* _this_magnifier = NULL`[static]`

Definition at line 121 of file magnifier.c.

gint fixes_event_base

Referenced by magnifier_get_cursor(), and magnifier_init_cursor_set().

gboolean _is_override_redirect = FALSE`[static]`

Definition at line 129 of file magnifier.c.

Referenced by magnifier_init_window(), and magnifier_new().