1 /**
2  * @defgroup Elm_Cursors Cursors
3  * @ingroup Elementary
4  */
5 
6 #ifndef EFL_NOLEGACY_API_SUPPORT
7 
8 
9 /**
10  * @brief The cursor to be shown when mouse is over the object
11  *
12  * This is the cursor that will be displayed when mouse is over the object. The
13  * object can have only one cursor set to it so if @ref elm_object_cursor_set
14  * is called twice for an object, the previous set will be unset.
15  *
16  * If using X cursors, a definition of all the valid cursor names is listed on
17  * Elementary_Cursors.h. If an invalid name is set the default cursor will be
18  * used.
19  *
20  * Sets or unsets the current cursor.
21  *
22  * If @c cursor is @c null this function will reset the cursor to the default
23  * one.
24  *
25  * @param[in] obj The object.
26  * @param[in] cursor The cursor name, defined either by the display system or
27  * the theme.
28  *
29  * @return @c true if successful.
30  *
31  * @ingroup Elm_Cursors
32  */
33 EAPI Eina_Bool elm_object_cursor_set(Eo *obj, const char *cursor);
34 
35 /**
36  * @brief The cursor to be shown when mouse is over the object
37  *
38  * This is the cursor that will be displayed when mouse is over the object. The
39  * object can have only one cursor set to it so if @ref elm_object_cursor_set
40  * is called twice for an object, the previous set will be unset.
41  *
42  * If using X cursors, a definition of all the valid cursor names is listed on
43  * Elementary_Cursors.h. If an invalid name is set the default cursor will be
44  * used.
45  *
46  * Returns the current cursor name.
47  *
48  * @param[in] obj The object.
49  *
50  * @return The cursor name, defined either by the display system or the theme.
51  *
52  * @ingroup Elm_Cursors
53  */
54 EAPI const char *elm_object_cursor_get(const Eo *obj);
55 
56 /**
57  * @brief A different style for the cursor.
58  *
59  * This only makes sense if theme cursors are used. The cursor should be set
60  * with @ref elm_object_cursor_set first before setting its style with this
61  * property.
62  *
63  * Sets a style for the current cursor. Call after @ref elm_object_cursor_set.
64  *
65  * @param[in] obj The object.
66  * @param[in] style A specific style to use, eg. default, transparent, ....
67  *
68  * @return @c true if successful.
69  *
70  * @ingroup Elm_Cursors
71  */
72 EAPI Eina_Bool elm_object_cursor_style_set(Eo *obj, const char *style);
73 
74 /**
75  * @brief A different style for the cursor.
76  *
77  * This only makes sense if theme cursors are used. The cursor should be set
78  * with @ref elm_object_cursor_set first before setting its style with this
79  * property.
80  *
81  * Returns the current cursor style name.
82  *
83  * @param[in] obj The object.
84  *
85  * @return A specific style to use, eg. default, transparent, ....
86  *
87  * @ingroup Elm_Cursors
88  */
89 EAPI const char *elm_object_cursor_style_get(const Eo *obj);
90 
91 /**
92  * @brief Whether the cursor may be looked in the theme or not.
93  *
94  * If @c false, the cursor may only come from the render engine, i.e. from the
95  * display manager.
96  *
97  * Enables or disables theme cursors.
98  *
99  * @param[in] obj The object.
100  * @param[in] allow Whether to use theme cursors.
101  *
102  * @return @c true if successful.
103  *
104  * @ingroup Elm_Cursors
105  */
106 EAPI Eina_Bool elm_object_cursor_theme_search_enabled_set(Eo *obj, Eina_Bool allow);
107 
108 /**
109  * @brief Whether the cursor may be looked in the theme or not.
110  *
111  * If @c false, the cursor may only come from the render engine, i.e. from the
112  * display manager.
113  *
114  * Returns the current state of theme cursors search.
115  *
116  * @param[in] obj The object.
117  *
118  * @return Whether to use theme cursors.
119  *
120  * @ingroup Elm_Cursors
121  */
122 EAPI Eina_Bool elm_object_cursor_theme_search_enabled_get(const Eo *obj);
123 
124 /**
125  * Unset cursor for object
126  *
127  * Unset cursor for object, and set the cursor to default if the mouse
128  * was over this object.
129  *
130  * @param obj Target object
131  * @see elm_object_cursor_set()
132  *
133  * @ingroup Elm_Cursors
134  */
135 EAPI void elm_object_cursor_unset(Evas_Object *obj);
136 
137 #endif
138 
139 /**
140  * @}
141  */
142