summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--README14
-rw-r--r--data/themes/default_pointer.edc211
-rw-r--r--data/themes/images/Makefile.am6
-rw-r--r--data/themes/images/e17_pointer.png (renamed from data/themes/images/pointer.png)bin1460 -> 1461 bytes
-rw-r--r--data/themes/images/e17_pointer_mono.pngbin0 -> 230 bytes
-rw-r--r--data/themes/images/pointer_mono.pngbin229 -> 0 bytes
-rw-r--r--src/bin/e_container.c2
-rw-r--r--src/bin/e_container.h1
-rw-r--r--src/bin/e_error.c10
-rw-r--r--src/bin/e_pointer.c37
-rw-r--r--src/bin/e_pointer.h26
11 files changed, 152 insertions, 155 deletions
diff --git a/README b/README
index bc009321d..6408e4842 100644
--- a/README
+++ b/README
@@ -9,3 +9,17 @@ of its own (recommended) like:
9 ./configure --prefix=/usr/local/e17 9 ./configure --prefix=/usr/local/e17
10 10
11You will, as usual need to add the subsequent bin dir to your $PATH etc. 11You will, as usual need to add the subsequent bin dir to your $PATH etc.
12
13NOTES:
14
15* do NOT use -mfpmath=sse in CFLAGS - we are not sure, but it may have bugds
16and screws up things in edje, evas and e17. if your gcc uses this by default
17(which apparently gcc4.x does on amd64), turn it off with a -fpmath=387 in
18your CFLAGS.
19
20* your freetype2 version must be > 2.1.7
21
22* i remember hearing of bugs with later versions of freetype on some
23distributions (2.1.9 and 2.1.10) with certain patches or missing certain
24patches. be aware of this as a possible font problem.
25
diff --git a/data/themes/default_pointer.edc b/data/themes/default_pointer.edc
index 97d843cb7..aa0bcd8fc 100644
--- a/data/themes/default_pointer.edc
+++ b/data/themes/default_pointer.edc
@@ -1,123 +1,124 @@
1images { 1images {
2 image: "pointer.png" COMP; 2 image: "e17_pointer.png" COMP;
3 image: "pointer_mono.png" COMP; 3 image: "e17_pointer_mono.png" COMP;
4} 4}
5 5
6 group { 6group {
7 name: "pointer/enlightenment/default"; 7 name: "pointer/enlightenment/default/color";
8 parts { 8 parts {
9 part { 9 part {
10 name: "pointer"; 10 name: "pointer";
11 type: IMAGE; 11 type: IMAGE;
12 mouse_events: 0; 12 mouse_events: 0;
13 description { 13 description {
14 state: "default" 0.0; 14 state: "default" 0.0;
15 rel1 { 15 rel1 {
16 relative: 0.0 0.0; 16 relative: 0.0 0.0;
17 offset: 0 0; 17 offset: 0 0;
18 }
19 rel2 {
20 relative: 0.68750 1.0;
21 offset: -1 -1;
22 }
23 image {
24 normal: "pointer.png";
25 }
26 } 18 }
27 description { 19 rel2 {
28 state: "test" 0.0; 20 relative: 0.68750 1.0;
29 aspect: 0.75 1.0; 21 offset: -1 -1;
30 rel1 { 22 }
31 relative: 0.0 0.0; 23 image {
32 offset: 8 8; 24 normal: "e17_pointer.png";
33 } 25 }
34 rel2 { 26 }
35 relative: 0.0 0.0; 27 description {
36 offset: 24 32; 28 state: "test" 0.0;
37 } 29 aspect: 0.75 1.0;
38 image { 30 rel1 {
39 normal: "pointer_mono.png"; 31 relative: 0.0 0.0;
40 } 32 offset: 8 8;
33 }
34 rel2 {
35 relative: 0.0 0.0;
36 offset: 24 32;
37 }
38 image {
39 normal: "e17_pointer_mono.png";
40 }
41 }
42 }
43 part {
44 name: "hotspot";
45 type: SWALLOW;
46 mouse_events: 0;
47 description {
48 state: "default" 0.0;
49 visible: 0;
50 rel1 {
51 relative: 0.0 0.0;
52 offset: 1 2;
53 }
54 rel2 {
55 relative: 0.0 0.0;
56 offset: 1 2;
41 } 57 }
42 } 58 }
43 part { 59 description {
44 name: "hotspot"; 60 state: "test" 0.0;
45 type: SWALLOW; 61 visible: 0;
46 mouse_events: 0; 62 rel1 {
47 description { 63 relative: 0.0 0.0;
48 state: "default" 0.0; 64 offset: 8 8;
49 visible: 0;
50 rel1 {
51 relative: 0.0 0.0;
52 offset: 1 2;
53 }
54 rel2 {
55 relative: 0.0 0.0;
56 offset: 2 3;
57 }
58 } 65 }
59 description { 66 rel2 {
60 state: "test" 0.0; 67 relative: 0.0 0.0;
61 visible: 0; 68 offset: 8 8;
62 rel1 {
63 relative: 0.0 0.0;
64 offset: 8 8;
65 }
66 rel2 {
67 relative: 0.0 0.0;
68 offset: 9 9;
69 }
70 } 69 }
71 } 70 }
72 } 71 }
73 programs { 72 }
74 program { 73 programs {
75 name: "test_hot"; 74 program {
76 signal: "test"; 75 name: "test_hot";
77 source: ""; 76 signal: "test";
78 action: STATE_SET "test" 0.0; 77 source: "";
79 target: "hotspot"; 78 action: STATE_SET "test" 0.0;
80 } 79 target: "hotspot";
81 program { 80 }
82 name: "test_pointer"; 81 program {
83 signal: "test"; 82 name: "test_pointer";
84 source: ""; 83 signal: "test";
85 action: STATE_SET "test" 0.0; 84 source: "";
86 target: "pointer"; 85 action: STATE_SET "test" 0.0;
87 } 86 target: "pointer";
88 } 87 }
89 } 88 }
90 group { 89}
91 name: "pointer/enlightenment/mono"; 90
92 parts { 91group {
93 part { 92 name: "pointer/enlightenment/default/mono";
94 name: "pointer"; 93 parts {
95 type: IMAGE; 94 part {
96 mouse_events: 0; 95 name: "pointer";
97 description { 96 type: IMAGE;
98 state: "default" 0.0; 97 mouse_events: 0;
99 aspect: 0.75 1.0; 98 description {
100 image { 99 state: "default" 0.0;
101 normal: "pointer_mono.png"; 100 aspect: 0.75 1.0;
102 } 101 image {
102 normal: "e17_pointer_mono.png";
103 } 103 }
104 } 104 }
105 part { 105 }
106 name: "hotspot"; 106 part {
107 type: SWALLOW; 107 name: "hotspot";
108 mouse_events: 0; 108 type: SWALLOW;
109 description { 109 mouse_events: 0;
110 state: "default" 0.0; 110 description {
111 visible: 0; 111 state: "default" 0.0;
112 rel1 { 112 visible: 0;
113 relative: 0.0 0.0; 113 rel1 {
114 offset: 0 0; 114 relative: 0.0 0.0;
115 } 115 offset: 0 0;
116 rel2 { 116 }
117 relative: 0.0 0.0; 117 rel2 {
118 offset: 1 1; 118 relative: 0.0 0.0;
119 } 119 offset: 0 0;
120 } 120 }
121 } 121 }
122 } 122 }
123 } 123 }
124}
diff --git a/data/themes/images/Makefile.am b/data/themes/images/Makefile.am
index e5f21edde..3e4aca3ba 100644
--- a/data/themes/images/Makefile.am
+++ b/data/themes/images/Makefile.am
@@ -306,6 +306,6 @@ e17_icon_run.png \
306e17_icon_theme_0.png \ 306e17_icon_theme_0.png \
307e17_icon_theme_glow_0.png \ 307e17_icon_theme_glow_0.png \
308e17_icon_windows.png \ 308e17_icon_windows.png \
309e17_icon_lost_windows.png 309e17_icon_lost_windows.png \
310 310e17_pointer.png \
311 311e17_pointer_mono.png
diff --git a/data/themes/images/pointer.png b/data/themes/images/e17_pointer.png
index 3682632f5..634323053 100644
--- a/data/themes/images/pointer.png
+++ b/data/themes/images/e17_pointer.png
Binary files differ
diff --git a/data/themes/images/e17_pointer_mono.png b/data/themes/images/e17_pointer_mono.png
new file mode 100644
index 000000000..207685601
--- /dev/null
+++ b/data/themes/images/e17_pointer_mono.png
Binary files differ
diff --git a/data/themes/images/pointer_mono.png b/data/themes/images/pointer_mono.png
deleted file mode 100644
index 3e3d24d36..000000000
--- a/data/themes/images/pointer_mono.png
+++ /dev/null
Binary files differ
diff --git a/src/bin/e_container.c b/src/bin/e_container.c
index 97af8e581..beccf4237 100644
--- a/src/bin/e_container.c
+++ b/src/bin/e_container.c
@@ -123,7 +123,6 @@ e_container_new(E_Manager *man)
123 evas_object_show(o); 123 evas_object_show(o);
124 124
125 con->pointer.root = e_pointer_window_set(con->manager->root); 125 con->pointer.root = e_pointer_window_set(con->manager->root);
126 con->pointer.win = e_pointer_window_set(con->win);
127 126
128 con->num = container_num; 127 con->num = container_num;
129 container_num++; 128 container_num++;
@@ -892,7 +891,6 @@ _e_container_free(E_Container *con)
892 int i; 891 int i;
893 892
894 if (con->pointer.root) e_object_del(E_OBJECT(con->pointer.root)); 893 if (con->pointer.root) e_object_del(E_OBJECT(con->pointer.root));
895 if (con->pointer.win) e_object_del(E_OBJECT(con->pointer.win));
896 894
897 ecore_x_window_del(con->event_win); 895 ecore_x_window_del(con->event_win);
898 if (con->gadman) e_object_del(E_OBJECT(con->gadman)); 896 if (con->gadman) e_object_del(E_OBJECT(con->gadman));
diff --git a/src/bin/e_container.h b/src/bin/e_container.h
index 58557c0c8..817b51751 100644
--- a/src/bin/e_container.h
+++ b/src/bin/e_container.h
@@ -57,7 +57,6 @@ struct _E_Container
57 57
58 struct { 58 struct {
59 E_Pointer *root; 59 E_Pointer *root;
60 E_Pointer *win;
61 } pointer; 60 } pointer;
62}; 61};
63 62
diff --git a/src/bin/e_error.c b/src/bin/e_error.c
index 0b7fcd3fd..952da108f 100644
--- a/src/bin/e_error.c
+++ b/src/bin/e_error.c
@@ -61,7 +61,6 @@ e_error_message_manager_show(E_Manager *man, char *title, char *txt)
61 Evas_Coord maxw, maxh; 61 Evas_Coord maxw, maxh;
62 E_Container *con; 62 E_Container *con;
63 Ecore_X_Window win; 63 Ecore_X_Window win;
64 E_Pointer *p;
65 int x, y; 64 int x, y;
66 char *s; 65 char *s;
67 66
@@ -94,8 +93,6 @@ e_error_message_manager_show(E_Manager *man, char *title, char *txt)
94 ecore_evas_title_set(ee, "Enlightenment: Low Level Dialog"); 93 ecore_evas_title_set(ee, "Enlightenment: Low Level Dialog");
95// ecore_evas_avoid_damage_set(ee, 1); 94// ecore_evas_avoid_damage_set(ee, 1);
96 e = ecore_evas_get(ee); 95 e = ecore_evas_get(ee);
97 p = e_pointer_window_set(win);
98 ecore_evas_data_set(ee, "pointer", p);
99 96
100 o = edje_object_add(e); 97 o = edje_object_add(e);
101 if (!e_theme_edje_object_set(o, "base/theme/error", "error/main")) 98 if (!e_theme_edje_object_set(o, "base/theme/error", "error/main"))
@@ -423,17 +420,12 @@ _e_error_cb_job_ecore_evas_free(void *data)
423{ 420{
424 Ecore_Evas *ee; 421 Ecore_Evas *ee;
425 Evas_List *shapelist, *l; 422 Evas_List *shapelist, *l;
426 E_Pointer *p;
427 423
428 ee = data; 424 ee = data;
429 shapelist = ecore_evas_data_get(ee, "shapes"); 425 shapelist = ecore_evas_data_get(ee, "shapes");
430 for (l = shapelist; l; l = l->next) 426 for (l = shapelist; l; l = l->next) e_object_del(E_OBJECT(l->data));
431 e_object_del(E_OBJECT(l->data));
432 evas_list_free(shapelist); 427 evas_list_free(shapelist);
433 428
434 p = ecore_evas_data_get(ee, "pointer");
435 e_object_del(E_OBJECT(p));
436
437 e_canvas_del(ee); 429 e_canvas_del(ee);
438 ecore_evas_free(ee); 430 ecore_evas_free(ee);
439} 431}
diff --git a/src/bin/e_pointer.c b/src/bin/e_pointer.c
index 46735fddc..8bbacf52f 100644
--- a/src/bin/e_pointer.c
+++ b/src/bin/e_pointer.c
@@ -56,28 +56,19 @@ e_pointer_window_set(Ecore_X_Window win)
56 { 56 {
57 if (!e_theme_edje_object_set(o, 57 if (!e_theme_edje_object_set(o,
58 "base/theme/pointer", 58 "base/theme/pointer",
59 "pointer/enlightenment/default")) 59 "pointer/enlightenment/default/color"))
60 { 60 e_theme_edje_object_set(o,
61 /* error */ 61 "base/theme/pointer",
62 printf("ERROR: No default theme for pointer!\n"); 62 "pointer/enlightenment/default/mono");
63 if (!e_theme_edje_object_set(o,
64 "base/theme/pointer",
65 "pointer/enlightenment/mono"))
66 {
67 /* error */
68 printf("ERROR: No mono theme for pointer!\n");
69 }
70 }
71 } 63 }
72 else 64 else
73 { 65 {
74 if (!e_theme_edje_object_set(o, 66 if (!e_theme_edje_object_set(o,
75 "base/theme/pointer", 67 "base/theme/pointer",
76 "pointer/enlightenment/mono")) 68 "pointer/enlightenment/default/mono"))
77 { 69 e_theme_edje_object_set(o,
78 /* error */ 70 "base/theme/pointer",
79 printf("ERROR: No mono theme for pointer!\n"); 71 "pointer/enlightenment/default/color");
80 }
81 } 72 }
82 73
83 /* Create the hotspot object */ 74 /* Create the hotspot object */
@@ -109,15 +100,15 @@ e_pointer_idler_before(void)
109 100
110 p = l->data; 101 p = l->data;
111 updates = evas_render_updates(p->evas); 102 updates = evas_render_updates(p->evas);
112 if (updates) 103 if ((updates) || (p->hot.update))
113 { 104 {
114 Ecore_X_Cursor cur; 105 Ecore_X_Cursor cur;
115 106
116 cur = ecore_x_cursor_new(p->win, p->pixels, p->w, p->h, p->hot.x, p->hot.y); 107 cur = ecore_x_cursor_new(p->win, p->pixels, p->w, p->h, p->hot.x, p->hot.y);
117 ecore_x_window_cursor_set(p->win, cur); 108 ecore_x_window_cursor_set(p->win, cur);
118 ecore_x_cursor_free(cur); 109 ecore_x_cursor_free(cur);
119
120 evas_render_updates_free(updates); 110 evas_render_updates_free(updates);
111 p->hot.update = 0;
121 } 112 }
122 } 113 }
123} 114}
@@ -131,8 +122,12 @@ _e_pointer_cb_move(void *data, Evas *e __UNUSED__, Evas_Object *obj, void *event
131 122
132 p = data; 123 p = data;
133 evas_object_geometry_get(p->hot_object, &x, &y, NULL, NULL); 124 evas_object_geometry_get(p->hot_object, &x, &y, NULL, NULL);
134 p->hot.x = x; 125 if ((p->hot.x != x) || (p->hot.y != y))
135 p->hot.y = y; 126 {
127 p->hot.x = x;
128 p->hot.y = y;
129 p->hot.update = 1;
130 }
136} 131}
137 132
138static void 133static void
diff --git a/src/bin/e_pointer.h b/src/bin/e_pointer.h
index 2ddfa400f..7c96cfaa2 100644
--- a/src/bin/e_pointer.h
+++ b/src/bin/e_pointer.h
@@ -13,20 +13,18 @@ typedef struct _E_Pointer E_Pointer;
13 13
14struct _E_Pointer 14struct _E_Pointer
15{ 15{
16 E_Object e_obj_inherit; 16 E_Object e_obj_inherit;
17 17
18 Evas *evas; 18 Evas *evas;
19 Evas_Object *pointer_object; 19 Evas_Object *pointer_object;
20 Evas_Object *hot_object; 20 Evas_Object *hot_object;
21 int *pixels; 21 int *pixels;
22 22 Ecore_X_Window win;
23 Ecore_X_Window win; 23 int w, h;
24 24 struct {
25 int w, h; 25 int x, y;
26 26 unsigned char update : 1;
27 struct { 27 } hot;
28 int x, y;
29 } hot;
30}; 28};
31 29
32EAPI E_Pointer *e_pointer_window_set(Ecore_X_Window win); 30EAPI E_Pointer *e_pointer_window_set(Ecore_X_Window win);