Evince
Evince is a document viewer capable of displaying multiple and single page document formats like PDF and Postscript.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
ev-view-cursor.c
Go to the documentation of this file.
1 /* this file is part of evince, a gnome document viewer
2  *
3  * Copyright (C) 2004 Red Hat, Inc
4  *
5  * Evince is free software; you can redistribute it and/or modify it
6  * under the terms of the GNU General Public License as published by
7  * the Free Software Foundation; either version 2 of the License, or
8  * (at your option) any later version.
9  *
10  * Evince is distributed in the hope that it will be useful, but
11  * WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * General Public License for more details.
14  *
15  * You should have received a copy of the GNU General Public License
16  * along with this program; if not, write to the Free Software
17  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18  */
19 
20 #include "ev-view-cursor.h"
21 
22 GdkCursor *
23 ev_view_cursor_new (GdkDisplay *display,
24  EvViewCursor new_cursor)
25 {
26  GdkCursor *cursor = NULL;
27 
28  switch (new_cursor) {
30  break;
32  cursor = gdk_cursor_new_for_display (display, GDK_XTERM);
33  break;
35  cursor = gdk_cursor_new_for_display (display, GDK_HAND2);
36  break;
38  cursor = gdk_cursor_new_for_display (display, GDK_WATCH);
39  break;
41  cursor = gdk_cursor_new_for_display (display, GDK_BLANK_CURSOR);
42  break;
44  cursor = gdk_cursor_new_for_display (display, GDK_FLEUR);
45  break;
47  cursor = gdk_cursor_new_for_display (display, GDK_DOUBLE_ARROW);
48  break;
49  case EV_VIEW_CURSOR_ADD:
50  cursor = gdk_cursor_new_for_display (display, GDK_PLUS);
51  break;
52  }
53 
54  return cursor;
55 }