#include <gtk/gtk-a11y.h>
#include "ev-document-model.h"
Go to the source code of this file.
|
GType | ev_view_accessible_get_type (void) |
|
AtkObject * | ev_view_accessible_new (GtkWidget *widget) |
|
void | ev_view_accessible_set_model (EvViewAccessible *accessible, EvDocumentModel *model) |
|
gint | ev_view_accessible_get_n_pages (EvViewAccessible *accessible) |
|
gint | ev_view_accessible_get_relevant_page (EvViewAccessible *accessible) |
|
void | ev_view_accessible_set_page_range (EvViewAccessible *accessible, gint start, gint end) |
|
void | _transform_doc_rect_to_atk_rect (EvViewAccessible *accessible, gint page, EvRectangle *doc_rect, EvRectangle *atk_rect, AtkCoordType coord_type) |
|
gboolean | ev_view_accessible_is_doc_rect_showing (EvViewAccessible *accessible, gint page, EvRectangle *doc_rect) |
|
void | ev_view_accessible_set_focused_element (EvViewAccessible *accessible, EvMapping *new_focus, gint new_focus_page) |
|
void | ev_view_accessible_update_element_state (EvViewAccessible *accessible, EvMapping *element, gint element_page) |
|
Definition at line 517 of file ev-view-accessible.c.
524 GdkRectangle view_rect;
525 GtkWidget *widget, *toplevel;
526 gint x_widget, y_widget;
528 view =
EV_VIEW (gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible)));
533 widget = GTK_WIDGET (view);
534 toplevel = gtk_widget_get_toplevel (widget);
535 gtk_widget_translate_coordinates (widget, toplevel, 0, 0, &x_widget, &y_widget);
536 view_rect.x += x_widget;
537 view_rect.y += y_widget;
539 if (coord_type == ATK_XY_SCREEN) {
540 gint x_window, y_window;
541 gdk_window_get_origin (gtk_widget_get_window (toplevel), &x_window, &y_window);
542 view_rect.x += x_window;
543 view_rect.y += y_window;
546 atk_rect->
x1 = view_rect.x;
547 atk_rect->
y1 = view_rect.y;
548 atk_rect->
x2 = view_rect.x + view_rect.width;
549 atk_rect->
y2 = view_rect.y + view_rect.height;
Definition at line 134 of file ev-view-accessible.c.
136 return self->priv->children == NULL ? 0 :
self->priv->children->len;
Definition at line 505 of file ev-view-accessible.c.
511 view =
EV_VIEW (gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible)));
513 return get_relevant_page (view);
GType ev_view_accessible_get_type |
( |
void |
) | |
|
Definition at line 553 of file ev-view-accessible.c.
558 GdkRectangle view_rect;
559 GtkAllocation allocation;
563 view =
EV_VIEW (gtk_accessible_get_widget (GTK_ACCESSIBLE (accessible)));
564 if (page < view->start_page || page > view->
end_page)
567 gtk_widget_get_allocation (GTK_WIDGET (view), &allocation);
572 hidden = view_rect.x + view_rect.width < x || view_rect.x > x + allocation.width ||
573 view_rect.y + view_rect.height < y || view_rect.y > y + allocation.height;
AtkObject* ev_view_accessible_new |
( |
GtkWidget * |
widget) | |
|
Definition at line 473 of file ev-view-accessible.c.
475 AtkObject *accessible;
478 g_return_val_if_fail (
EV_IS_VIEW (widget), NULL);
481 atk_object_initialize (accessible, widget);
483 g_signal_connect (widget,
"cursor-moved",
486 g_signal_connect (widget,
"selection-changed",
489 g_signal_connect (widget,
"focus-in-event",
492 g_signal_connect (widget,
"focus-out-event",
Definition at line 427 of file ev-view-accessible.c.
432 if (priv->
model == model)
436 g_signal_handlers_disconnect_by_data (priv->
model, accessible);
437 g_object_unref (priv->
model);
440 priv->
model = g_object_ref (model);
443 g_signal_connect (priv->
model,
"page-changed",
446 g_signal_connect (priv->
model,
"notify::document",
void ev_view_accessible_set_page_range |
( |
EvViewAccessible * |
accessible, |
|
|
gint |
start, |
|
|
gint |
end |
|
) |
| |
Definition at line 579 of file ev-view-accessible.c.
588 for (i = accessible->
priv->
start_page; i <= accessible->priv->end_page; i++) {
589 if (i < start || i > end) {
590 page = g_ptr_array_index (accessible->
priv->
children, i);
591 atk_object_notify_state_change (page, ATK_STATE_SHOWING,
FALSE);
595 for (i = start; i <= end; i++) {
596 if (i < accessible->priv->start_page || i > accessible->
priv->
end_page) {
597 page = g_ptr_array_index (accessible->
priv->
children, i);
598 atk_object_notify_state_change (page, ATK_STATE_SHOWING,
TRUE);