Ecore_Win32 is a library that wraps Windows graphic functions and integrate them nicely into the Ecore main loop. More...
Data Structures | |
struct | _Ecore_Win32_Event_Mouse_In |
Event sent when the mouse enters the window. More... | |
struct | _Ecore_Win32_Event_Mouse_Out |
Event sent when the mouse leaves the window. More... | |
struct | _Ecore_Win32_Event_Window_Focus_In |
Event sent when the window gets the focus. More... | |
struct | _Ecore_Win32_Event_Window_Focus_Out |
Event sent when the window looses the focus. More... | |
struct | _Ecore_Win32_Event_Window_Damage |
Event sent when the window is damaged. More... | |
struct | _Ecore_Win32_Event_Window_Create |
Event sent when the window is created. More... | |
struct | _Ecore_Win32_Event_Window_Destroy |
Event sent when the window is destroyed. More... | |
struct | _Ecore_Win32_Event_Window_Hide |
Event sent when the window is hidden. More... | |
struct | _Ecore_Win32_Event_Window_Show |
Event sent when the window is shown. More... | |
struct | _Ecore_Win32_Event_Window_Configure |
Event sent when the window is configured. More... | |
struct | _Ecore_Win32_Event_Window_Resize |
Event sent when the window is resized. More... | |
struct | _Ecore_Win32_Event_Window_Delete_Request |
Event sent when the window is deleted. More... | |
Typedefs | |
typedef struct _Ecore_Win32_Window | Ecore_Win32_Window |
typedef void | Ecore_Win32_Cursor |
Abstract type for a cursor. | |
typedef struct _Ecore_Win32_Event_Mouse_In | Ecore_Win32_Event_Mouse_In |
Event sent when the mouse enters the window. | |
typedef struct _Ecore_Win32_Event_Mouse_Out | Ecore_Win32_Event_Mouse_Out |
Event sent when the mouse leaves the window. | |
typedef struct _Ecore_Win32_Event_Window_Focus_In | Ecore_Win32_Event_Window_Focus_In |
Event sent when the window gets the focus. | |
typedef struct _Ecore_Win32_Event_Window_Focus_Out | Ecore_Win32_Event_Window_Focus_Out |
Event sent when the window looses the focus. | |
typedef struct _Ecore_Win32_Event_Window_Damage | Ecore_Win32_Event_Window_Damage |
Event sent when the window is damaged. | |
typedef struct _Ecore_Win32_Event_Window_Create | Ecore_Win32_Event_Window_Create |
Event sent when the window is created. | |
typedef struct _Ecore_Win32_Event_Window_Destroy | Ecore_Win32_Event_Window_Destroy |
Event sent when the window is destroyed. | |
typedef struct _Ecore_Win32_Event_Window_Hide | Ecore_Win32_Event_Window_Hide |
Event sent when the window is hidden. | |
typedef struct _Ecore_Win32_Event_Window_Show | Ecore_Win32_Event_Window_Show |
Event sent when the window is shown. | |
typedef struct _Ecore_Win32_Event_Window_Configure | Ecore_Win32_Event_Window_Configure |
Event sent when the window is configured. | |
typedef struct _Ecore_Win32_Event_Window_Resize | Ecore_Win32_Event_Window_Resize |
Event sent when the window is resized. | |
typedef struct _Ecore_Win32_Event_Window_Delete_Request | Ecore_Win32_Event_Window_Delete_Request |
Event sent when the window is deleted. | |
typedef int(* | Ecore_Win32_Dnd_DropTarget_Callback )(void *window, int event, int pt_x, int pt_y, void *data, int size) |
Callback type for Drop operations. More... | |
typedef struct _Ecore_Win32_Window | Ecore_Win32_Window |
Abstract type for a window. | |
Functions | |
EAPI int | ecore_win32_init () |
Initialize the Ecore_Win32 library. More... | |
EAPI int | ecore_win32_shutdown () |
Shut down the Ecore_Win32 library. More... | |
EAPI int | ecore_win32_screen_depth_get () |
Retrieve the depth of the screen. More... | |
EAPI void | ecore_win32_double_click_time_set (double t) |
Sets the timeout for a double and triple clicks to be flagged. More... | |
EAPI double | ecore_win32_double_click_time_get (void) |
Retrieve the double and triple click flag timeout. More... | |
EAPI unsigned long | ecore_win32_current_time_get (void) |
Return the last event time. More... | |
EAPI Ecore_Win32_Window * | ecore_win32_window_new (Ecore_Win32_Window *parent, int x, int y, int width, int height) |
Creates a new window. More... | |
EAPI Ecore_Win32_Window * | ecore_win32_window_override_new (Ecore_Win32_Window *parent, int x, int y, int width, int height) |
Creates a new borderless window. More... | |
EAPI void | ecore_win32_window_free (Ecore_Win32_Window *window) |
Free the given window. More... | |
EAPI void * | ecore_win32_window_hwnd_get (Ecore_Win32_Window *window) |
Return the window HANDLE associated to the given window. More... | |
EAPI void | ecore_win32_window_move (Ecore_Win32_Window *window, int x, int y) |
Move the given window to a given position. More... | |
EAPI void | ecore_win32_window_resize (Ecore_Win32_Window *window, int width, int height) |
Resize the given window to a given size. More... | |
EAPI void | ecore_win32_window_move_resize (Ecore_Win32_Window *window, int x, int y, int width, int height) |
Move and resize the given window to a given position and size. More... | |
EAPI void | ecore_win32_window_geometry_get (Ecore_Win32_Window *window, int *x, int *y, int *width, int *height) |
Get the geometry of the given window. More... | |
EAPI void | ecore_win32_window_size_get (Ecore_Win32_Window *window, int *width, int *height) |
Get the size of the given window. More... | |
EAPI void | ecore_win32_window_size_min_set (Ecore_Win32_Window *window, unsigned int min_width, unsigned int min_height) |
Set the minimum size of the given window. More... | |
EAPI void | ecore_win32_window_size_min_get (Ecore_Win32_Window *window, unsigned int *min_width, unsigned int *min_height) |
Get the minimum size of the given window. More... | |
EAPI void | ecore_win32_window_size_max_set (Ecore_Win32_Window *window, unsigned int max_width, unsigned int max_height) |
Set the maximum size of the given window. More... | |
EAPI void | ecore_win32_window_size_max_get (Ecore_Win32_Window *window, unsigned int *max_width, unsigned int *max_height) |
Get the maximum size of the given window. More... | |
EAPI void | ecore_win32_window_size_base_set (Ecore_Win32_Window *window, unsigned int base_width, unsigned int base_height) |
Set the base size of the given window. More... | |
EAPI void | ecore_win32_window_size_base_get (Ecore_Win32_Window *window, unsigned int *base_width, unsigned int *base_height) |
Get the base size of the given window. More... | |
EAPI void | ecore_win32_window_size_step_set (Ecore_Win32_Window *window, unsigned int step_width, unsigned int step_height) |
Set the step size of the given window. More... | |
EAPI void | ecore_win32_window_size_step_get (Ecore_Win32_Window *window, unsigned int *step_width, unsigned int *step_height) |
Get the step size of the given window. More... | |
EAPI void | ecore_win32_window_show (Ecore_Win32_Window *window) |
Show the given window. More... | |
EAPI void | ecore_win32_window_hide (Ecore_Win32_Window *window) |
Hide the given window. More... | |
EAPI void | ecore_win32_window_raise (Ecore_Win32_Window *window) |
Place the given window at the top of the Z order. More... | |
EAPI void | ecore_win32_window_lower (Ecore_Win32_Window *window) |
Place the given window at the bottom of the Z order. More... | |
EAPI void | ecore_win32_window_title_set (Ecore_Win32_Window *window, const char *title) |
Set the title of the given window. More... | |
EAPI void | ecore_win32_window_focus (Ecore_Win32_Window *window) |
Set the focus to the given window. More... | |
EAPI void * | ecore_win32_window_focus_get (void) |
Get the current focused window. More... | |
EAPI void | ecore_win32_window_iconified_set (Ecore_Win32_Window *window, Eina_Bool on) |
Iconify or restore the given window. More... | |
EAPI void | ecore_win32_window_borderless_set (Ecore_Win32_Window *window, Eina_Bool on) |
Remove or restore the border of the given window. More... | |
EAPI void | ecore_win32_window_fullscreen_set (Ecore_Win32_Window *window, Eina_Bool on) |
Set the given window to fullscreen. More... | |
EAPI void | ecore_win32_window_cursor_set (Ecore_Win32_Window *window, Ecore_Win32_Cursor *cursor) |
Set the given cursor to the given window. More... | |
EAPI void | ecore_win32_window_state_set (Ecore_Win32_Window *window, Ecore_Win32_Window_State *state, unsigned int num) |
Set the state of the given window. More... | |
EAPI void | ecore_win32_window_state_request_send (Ecore_Win32_Window *window, Ecore_Win32_Window_State state, unsigned int set) |
Apply the modification of the state to the given window. More... | |
EAPI void | ecore_win32_window_type_set (Ecore_Win32_Window *window, Ecore_Win32_Window_Type type) |
Set the type of the given window. More... | |
EAPI Ecore_Win32_Cursor * | ecore_win32_cursor_new (const void *pixels_and, const void *pixels_xor, int width, int height, int hot_x, int hot_y) |
Create a new cursor. More... | |
EAPI void | ecore_win32_cursor_free (Ecore_Win32_Cursor *cursor) |
Free the given cursor. More... | |
EAPI Ecore_Win32_Cursor * | ecore_win32_cursor_shaped_new (Ecore_Win32_Cursor_Shape shape) |
Create a cursor from a Windows ressource. More... | |
EAPI void | ecore_win32_cursor_size_get (int *width, int *height) |
Retrieve the size of a valid cursor. More... | |
EAPI int | ecore_win32_dnd_init () |
Initialize the Ecore_Win32 Drag and Drop module. More... | |
EAPI int | ecore_win32_dnd_shutdown () |
Shut down the Ecore_Win32 Drag and Drop module. More... | |
EAPI Eina_Bool | ecore_win32_dnd_begin (const char *data, int size) |
Begin a DnD operation. More... | |
EAPI Eina_Bool | ecore_win32_dnd_register_drop_target (Ecore_Win32_Window *window, Ecore_Win32_Dnd_DropTarget_Callback callback) |
Register a Drop operation. More... | |
EAPI void | ecore_win32_dnd_unregister_drop_target (Ecore_Win32_Window *window) |
Unregister a Drop operation. More... | |
Variables | |
EAPI int | ECORE_WIN32_EVENT_MOUSE_IN |
Ecore_Event for the Ecore_Win32_Event_Mouse_In event. | |
EAPI int | ECORE_WIN32_EVENT_MOUSE_OUT |
Ecore_Event for the Ecore_Win32_Event_Mouse_Out event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_FOCUS_IN |
Ecore_Event for the Ecore_Win32_Event_Window_Focus_In event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_FOCUS_OUT |
Ecore_Event for the Ecore_Win32_Event_Window_Focus_Out event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_DAMAGE |
Ecore_Event for the Ecore_Win32_Event_Damage event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_CREATE |
Ecore_Event for the Ecore_Win32_Event_Create event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_DESTROY |
Ecore_Event for the Ecore_Win32_Event_Destroy event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_HIDE |
Ecore_Event for the Ecore_Win32_Event_Hide event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_SHOW |
Ecore_Event for the Ecore_Win32_Event_Show event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_CONFIGURE |
Ecore_Event for the Ecore_Win32_Event_Configure event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_RESIZE |
Ecore_Event for the Ecore_Win32_Event_Resize event. | |
EAPI int | ECORE_WIN32_EVENT_WINDOW_DELETE_REQUEST |
Ecore_Event for the Ecore_Win32_Event_Window_Delete_Request event. | |
Ecore_Win32 is a library that wraps Windows graphic functions and integrate them nicely into the Ecore main loop.
To fill...
It is possible to also sets the icon of the application easily:
Ecore_Win32_Dnd_DropTarget_Callback |
Callback type for Drop operations.
State of a window.
Type of a window.
Shape of a cursor.
EAPI int ecore_win32_init | ( | ) |
Initialize the Ecore_Win32 library.
This function sets up the Windows graphic system. It returns 0 on failure, otherwise it returns the number of times it has already been called.
When Ecore_Win32 is not used anymore, call ecore_win32_shutdown() to shut down the Ecore_Win32 library.
References ecore_event_type_new(), ecore_win32_dnd_init(), eina_init(), eina_log_domain_register(), eina_log_domain_unregister(), EINA_LOG_ERR, and eina_shutdown().
EAPI int ecore_win32_shutdown | ( | ) |
Shut down the Ecore_Win32 library.
This function shuts down the Ecore_Win32 library. It returns 0 when it has been called the same number of times than ecore_win32_init(). In that case it shuts down all the Windows graphic system.
References ecore_win32_dnd_shutdown(), eina_log_domain_unregister(), and eina_shutdown().
EAPI int ecore_win32_screen_depth_get | ( | ) |
Retrieve the depth of the screen.
This function returns the depth of the screen. If an error occurs, it returns 0.
EAPI void ecore_win32_double_click_time_set | ( | double | t | ) |
Sets the timeout for a double and triple clicks to be flagged.
t | The time in seconds. |
This function sets the time t
between clicks before the double_click flag is set in a button down event. If 3 clicks occur within double this time, the triple_click flag is also set.
EAPI double ecore_win32_double_click_time_get | ( | void | ) |
Retrieve the double and triple click flag timeout.
This function returns the double clicks in seconds. If ecore_win32_double_click_time_set() has not been called, the default value is returned. See ecore_win32_double_click_time_set() for more informations.
EAPI unsigned long ecore_win32_current_time_get | ( | void | ) |
Return the last event time.
This function returns the last event time.
EAPI Ecore_Win32_Window * ecore_win32_window_new | ( | Ecore_Win32_Window * | parent, |
int | x, | ||
int | y, | ||
int | width, | ||
int | height | ||
) |
Creates a new window.
parent | The parent window. |
x | The x coordinate of the top-left corner of the window. |
y | The y coordinate of the top-left corner of the window. |
width | The width of the window. |
height | The height of hte window. |
This function creates a new window which parent is parent
. width
and height
are the size of the window content (the client part), without the border and title bar. x
and y
are the system coordinates of the top left cerner of the window (that is, of the title bar). This function returns a newly created window on success, and NULL
on failure.
EAPI Ecore_Win32_Window * ecore_win32_window_override_new | ( | Ecore_Win32_Window * | parent, |
int | x, | ||
int | y, | ||
int | width, | ||
int | height | ||
) |
Creates a new borderless window.
parent | The parent window. |
x | The x coordinate of the top-left corner of the window. |
y | The y coordinate of the top-left corner of the window. |
width | The width of the window. |
height | The height of hte window. |
This function is the same than ecore_win32_window_override_new() but the returned window is borderless.
EAPI void ecore_win32_window_free | ( | Ecore_Win32_Window * | window | ) |
Free the given window.
window | The window to free. |
This function frees window
. If window
is NULL
, this function does nothing.
EAPI void * ecore_win32_window_hwnd_get | ( | Ecore_Win32_Window * | window | ) |
Return the window HANDLE associated to the given window.
window | The window to retrieve the HANDLE from. |
This function returns the window HANDLE associated to window
. If window
is NULL
, this function returns NULL
.
EAPI void ecore_win32_window_move | ( | Ecore_Win32_Window * | window, |
int | x, | ||
int | y | ||
) |
Move the given window to a given position.
window | The window to move. |
x | The x coordinate of the destination position. |
y | The y coordinate of the destination position. |
This function move window
to the new position of coordinates x
and y
. If window
is NULL
, or if it is fullscreen, or on error, this function does nothing.
EAPI void ecore_win32_window_resize | ( | Ecore_Win32_Window * | window, |
int | width, | ||
int | height | ||
) |
Resize the given window to a given size.
window | The window to resize. |
width | The new width. |
height | The new height. |
This function resize window
to the new width
and height
. If window
is NULL
, or if it is fullscreen, or on error, this function does nothing.
EAPI void ecore_win32_window_move_resize | ( | Ecore_Win32_Window * | window, |
int | x, | ||
int | y, | ||
int | width, | ||
int | height | ||
) |
Move and resize the given window to a given position and size.
window | The window to move and resize. |
x | The x coordinate of the destination position. |
y | The x coordinate of the destination position. |
width | The new width. |
height | The new height. |
This function resize window
to the new position of coordinates x
and y
and the new width
and height
. If window
is NULL
, or if it is fullscreen, or on error, this function does nothing.
EAPI void ecore_win32_window_geometry_get | ( | Ecore_Win32_Window * | window, |
int * | x, | ||
int * | y, | ||
int * | width, | ||
int * | height | ||
) |
Get the geometry of the given window.
window | The window to retrieve the geometry from. |
x | The x coordinate of the position. |
y | The x coordinate of the position. |
width | The width. |
height | The height. |
This function retrieves the position and size of window
. x
, y
, width
and height
can be buffers that will be filled with the corresponding values. If one of them is NULL
, nothing will be done for that parameter. If window
is NULL
, and if the buffers are not NULL
, they will be filled with respectively 0, 0, the size of the screen and the height of the screen.
EAPI void ecore_win32_window_size_get | ( | Ecore_Win32_Window * | window, |
int * | width, | ||
int * | height | ||
) |
Get the size of the given window.
window | The window to retrieve the size from. |
width | The width. |
height | The height. |
This function retrieves the size of window
. width
and height
can be buffers that will be filled with the corresponding values. If one of them is NULL
, nothing will be done for that parameter. If window
is NULL
, and if the buffers are not NULL
, they will be filled with respectively the size of the screen and the height of the screen.
EAPI void ecore_win32_window_size_min_set | ( | Ecore_Win32_Window * | window, |
unsigned int | min_width, | ||
unsigned int | min_height | ||
) |
Set the minimum size of the given window.
window | The window. |
min_width | The minimal width. |
min_height | The minimal height. |
This function sets the minimum size of window
to min_width
and *p min_height. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_min_get | ( | Ecore_Win32_Window * | window, |
unsigned int * | min_width, | ||
unsigned int * | min_height | ||
) |
Get the minimum size of the given window.
window | The window. |
min_width | The minimal width. |
min_height | The minimal height. |
This function fills the minimum size of window
in the buffers min_width
and *p min_height. They both can be NULL
. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_max_set | ( | Ecore_Win32_Window * | window, |
unsigned int | max_width, | ||
unsigned int | max_height | ||
) |
Set the maximum size of the given window.
window | The window. |
max_width | The maximal width. |
max_height | The maximal height. |
This function sets the maximum size of window
to max_width
and *p max_height. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_max_get | ( | Ecore_Win32_Window * | window, |
unsigned int * | max_width, | ||
unsigned int * | max_height | ||
) |
Get the maximum size of the given window.
window | The window. |
max_width | The maximal width. |
max_height | The maximal height. |
This function fills the maximum size of window
in the buffers max_width
and *p max_height. They both can be NULL
. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_base_set | ( | Ecore_Win32_Window * | window, |
unsigned int | base_width, | ||
unsigned int | base_height | ||
) |
Set the base size of the given window.
window | The window. |
base_width | The base width. |
base_height | The base height. |
This function sets the base size of window
to base_width
and *p base_height. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_base_get | ( | Ecore_Win32_Window * | window, |
unsigned int * | base_width, | ||
unsigned int * | base_height | ||
) |
Get the base size of the given window.
window | The window. |
base_width | The base width. |
base_height | The bas height. |
This function fills the base size of window
in the buffers base_width
and *p base_height. They both can be NULL
. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_step_set | ( | Ecore_Win32_Window * | window, |
unsigned int | step_width, | ||
unsigned int | step_height | ||
) |
Set the step size of the given window.
window | The window. |
step_width | The step width. |
step_height | The step height. |
This function sets the step size of window
to step_width
and *p step_height. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_size_step_get | ( | Ecore_Win32_Window * | window, |
unsigned int * | step_width, | ||
unsigned int * | step_height | ||
) |
Get the step size of the given window.
window | The window. |
step_width | The step width. |
step_height | The bas height. |
This function fills the step size of window
in the buffers step_width
and *p step_height. They both can be NULL
. If window
is NULL
, this functions does nothing.
EAPI void ecore_win32_window_show | ( | Ecore_Win32_Window * | window | ) |
Show the given window.
window | The window to show. |
This function shows window
. If window
is NULL
, or on error, this function does nothing.
EAPI void ecore_win32_window_hide | ( | Ecore_Win32_Window * | window | ) |
Hide the given window.
window | The window to show. |
This function hides window
. If window
is NULL
, or on error, this function does nothing.
EAPI void ecore_win32_window_raise | ( | Ecore_Win32_Window * | window | ) |
Place the given window at the top of the Z order.
window | The window to place at the top. |
This function places window
at the top of the Z order. If window
is NULL
, this function does nothing.
EAPI void ecore_win32_window_lower | ( | Ecore_Win32_Window * | window | ) |
Place the given window at the bottom of the Z order.
window | The window to place at the bottom. |
This function places window
at the bottom of the Z order. If window
is NULL
, this function does nothing.
EAPI void ecore_win32_window_title_set | ( | Ecore_Win32_Window * | window, |
const char * | title | ||
) |
Set the title of the given window.
window | The window to set the title. |
title | The new title. |
This function sets the title of window
to title
. If window
is NULL
, or if title
is NULL
or empty, or on error, this function does nothing.
EAPI void ecore_win32_window_focus | ( | Ecore_Win32_Window * | window | ) |
Set the focus to the given window.
window | The window to give focus to. |
This function gives the focus to window
. If window
is NULL
, this function does nothing.
EAPI void * ecore_win32_window_focus_get | ( | void | ) |
Get the current focused window.
This function returns the window that has focus. If the calling thread's message queue does not have an associated window with the keyboard focus, the return value is NULL
.
NULL
, another thread's queue may be associated with a window that has the keyboard focus.EAPI void ecore_win32_window_iconified_set | ( | Ecore_Win32_Window * | window, |
Eina_Bool | on | ||
) |
Iconify or restore the given window.
window | The window. |
on | EINA_TRUE to iconify the window, EINA_FALSE to restore it. |
This function iconify or restore window
. If on
is set to EINA_TRUE
, the window will be iconified, if it is set to EINA_FALSE
, it will be restored. If window
is NULL
or if the state does not change (like iconifying the window while it is already iconified), this function does nothing.
Referenced by ecore_win32_window_state_request_send().
EAPI void ecore_win32_window_borderless_set | ( | Ecore_Win32_Window * | window, |
Eina_Bool | on | ||
) |
Remove or restore the border of the given window.
window | The window. |
on | EINA_TRUE to remove the border, EINA_FALSE to restore it. |
This function remove or restore the border of window
. If on
is set to EINA_TRUE
, the window will have no border, if it is set to EINA_FALSE
, it will have a border. If window
is NULL
or if the state does not change (like setting to borderless while the window has no border), this function does nothing.
EAPI void ecore_win32_window_fullscreen_set | ( | Ecore_Win32_Window * | window, |
Eina_Bool | on | ||
) |
Set the given window to fullscreen.
window | The window. |
on | EINA_TRUE for fullscreen mode, EINA_FALSE for windowed mode. |
This function set window
to fullscreen or windowed mode. If on
is set to EINA_TRUE
, the window will be fullscreen, if it is set to EINA_FALSE
, it will be windowed. If window
is NULL
or if the state does not change (like setting to fullscreen while the window is already fullscreen), this function does nothing.
Referenced by ecore_win32_window_state_request_send().
EAPI void ecore_win32_window_cursor_set | ( | Ecore_Win32_Window * | window, |
Ecore_Win32_Cursor * | cursor | ||
) |
Set the given cursor to the given window.
window | The window to modify the cursor. |
cursor | The new cursor. |
This function sets cursor
to window
. cursor
must have been obtained by ecore_win32_cursor_new() or ecore_win32_cursor_shaped_new(). If window
or cursor
is NULL
, the function does nothing.
EAPI void ecore_win32_window_state_set | ( | Ecore_Win32_Window * | window, |
Ecore_Win32_Window_State * | state, | ||
unsigned int | num | ||
) |
Set the state of the given window.
window | The window to modify the state. |
state | An array of the new states. |
num | The number of states in the array. |
This function set the state of window
. state
is an array of states of size num
. If window
or state
are NULL
, or if num
is less or equal than 0, the function does nothing.
References ECORE_WIN32_WINDOW_STATE_ABOVE, ECORE_WIN32_WINDOW_STATE_BELOW, ECORE_WIN32_WINDOW_STATE_DEMANDS_ATTENTION, ECORE_WIN32_WINDOW_STATE_FULLSCREEN, ECORE_WIN32_WINDOW_STATE_HIDDEN, ECORE_WIN32_WINDOW_STATE_ICONIFIED, ECORE_WIN32_WINDOW_STATE_MAXIMIZED, ECORE_WIN32_WINDOW_STATE_MAXIMIZED_HORZ, ECORE_WIN32_WINDOW_STATE_MAXIMIZED_VERT, ECORE_WIN32_WINDOW_STATE_MODAL, ECORE_WIN32_WINDOW_STATE_SHADED, ECORE_WIN32_WINDOW_STATE_STICKY, and ECORE_WIN32_WINDOW_STATE_UNKNOWN.
EAPI void ecore_win32_window_state_request_send | ( | Ecore_Win32_Window * | window, |
Ecore_Win32_Window_State | state, | ||
unsigned int | set | ||
) |
Apply the modification of the state to the given window.
window | The window. |
state | The state to apply changes. |
set | The value of the state change. |
This function applies the modification of the state state
of window
. set
is used only for ECORE_WIN32_WINDOW_STATE_ICONIFIED and ECORE_WIN32_WINDOW_STATE_FULLSCREEN. If window
is NULL
, the function does nothing.
References ecore_win32_window_fullscreen_set(), ecore_win32_window_iconified_set(), ECORE_WIN32_WINDOW_STATE_ABOVE, ECORE_WIN32_WINDOW_STATE_BELOW, ECORE_WIN32_WINDOW_STATE_DEMANDS_ATTENTION, ECORE_WIN32_WINDOW_STATE_FULLSCREEN, ECORE_WIN32_WINDOW_STATE_HIDDEN, ECORE_WIN32_WINDOW_STATE_ICONIFIED, ECORE_WIN32_WINDOW_STATE_MAXIMIZED, ECORE_WIN32_WINDOW_STATE_MAXIMIZED_HORZ, ECORE_WIN32_WINDOW_STATE_MAXIMIZED_VERT, ECORE_WIN32_WINDOW_STATE_MODAL, ECORE_WIN32_WINDOW_STATE_SHADED, ECORE_WIN32_WINDOW_STATE_STICKY, and ECORE_WIN32_WINDOW_STATE_UNKNOWN.
EAPI void ecore_win32_window_type_set | ( | Ecore_Win32_Window * | window, |
Ecore_Win32_Window_Type | type | ||
) |
Set the type of the given window.
window | The window to modify the type. |
type | The nwindow types. |
This function set the type of window
to type
. If window
is NULL
, the function does nothing.
References ECORE_WIN32_WINDOW_TYPE_DESKTOP, ECORE_WIN32_WINDOW_TYPE_DIALOG, ECORE_WIN32_WINDOW_TYPE_DOCK, ECORE_WIN32_WINDOW_TYPE_MENU, ECORE_WIN32_WINDOW_TYPE_NORMAL, ECORE_WIN32_WINDOW_TYPE_SPLASH, ECORE_WIN32_WINDOW_TYPE_TOOLBAR, ECORE_WIN32_WINDOW_TYPE_UNKNOWN, and ECORE_WIN32_WINDOW_TYPE_UTILITY.
EAPI Ecore_Win32_Cursor * ecore_win32_cursor_new | ( | const void * | pixels_and, |
const void * | pixels_xor, | ||
int | width, | ||
int | height, | ||
int | hot_x, | ||
int | hot_y | ||
) |
Create a new cursor.
pixels_and | The array of bytes containing the bit values for the AND mask of the cursor. |
pixels_xor | The array of bytes containing the bit values for the XOR mask of the cursor. |
width | The width of the cursor. |
height | The height of the cursor. |
hot_x | The horizontal position of the cursor's hot spot. |
hot_y | The vertical position of the cursor's hot spot. |
This function creates a new cursor of size width
and height
. They must be valid size. To determine the valid size of a cursor, use ecore_win32_cursor_size_get(). pixels_and
is an array of bytes (unsigned char) containing the bits of the cursor that will be visible. pixels_xor
is similar but will allow the cursor to have a shape. Here is the truth table for the masks:
AND mask | XOR mask | Display |
0 | 0 | Black |
0 | 1 | White |
1 | 0 | Screen |
1 | 1 | Reverse screen |
hot_x
and hot_y
are the position of the hot spot of the cursor. If pixels_and
or pixels_xor
are NULL
, the function returns NULL. If width
or height
does not match the valid size of a cursor, the function returns NULL
. On success, the function creates a user-defined cursor, otherwise it returns NULL
.
Once the cursor is not used anymore, use ecore_win32_cursor_free() to free the ressources.
Example of use:
EAPI void ecore_win32_cursor_free | ( | Ecore_Win32_Cursor * | cursor | ) |
Free the given cursor.
cursor | The cursor to free. |
This function free cursor
. cursor
must have been obtained with ecore_win32_cursor_new().
EAPI Ecore_Win32_Cursor * ecore_win32_cursor_shaped_new | ( | Ecore_Win32_Cursor_Shape | shape | ) |
Create a cursor from a Windows ressource.
shape | The pre-defined shape of the cursor. |
This function returns a pre-defined cursor with a specified shape
. This cursor does not need to be freed, as it is loaded from an existing resource.
References ECORE_WIN32_CURSOR_SHAPE_APP_STARTING, ECORE_WIN32_CURSOR_SHAPE_ARROW, ECORE_WIN32_CURSOR_SHAPE_CROSS, ECORE_WIN32_CURSOR_SHAPE_HAND, ECORE_WIN32_CURSOR_SHAPE_HELP, ECORE_WIN32_CURSOR_SHAPE_I_BEAM, ECORE_WIN32_CURSOR_SHAPE_NO, ECORE_WIN32_CURSOR_SHAPE_SIZE_ALL, ECORE_WIN32_CURSOR_SHAPE_SIZE_NESW, ECORE_WIN32_CURSOR_SHAPE_SIZE_NS, ECORE_WIN32_CURSOR_SHAPE_SIZE_NWSE, ECORE_WIN32_CURSOR_SHAPE_SIZE_WE, ECORE_WIN32_CURSOR_SHAPE_UP_ARROW, and ECORE_WIN32_CURSOR_SHAPE_WAIT.
EAPI void ecore_win32_cursor_size_get | ( | int * | width, |
int * | height | ||
) |
Retrieve the size of a valid cursor.
width | The width of a valid cursor. |
height | The height of a valid cursor. |
This function returns the size of a cursor that must be passed to ecore_win32_cursor_new(). width
and height
are buffers that will be filled with the correct size. They can be NULL
.
EAPI int ecore_win32_dnd_init | ( | ) |
Initialize the Ecore_Win32 Drag and Drop module.
This function initialize the Drag and Drop module. It returns 0 on failure, otherwise it returns the number of times it has already been called.
When the Drag and Drop module is not used anymore, call ecore_win32_dnd_shutdown() to shut down the module.
Referenced by ecore_win32_init().
EAPI int ecore_win32_dnd_shutdown | ( | ) |
Shut down the Ecore_Win32 Drag and Drop module.
This function shuts down the Drag and Drop module. It returns 0 when it has been called the same number of times than ecore_win32_dnd_init(). In that case it shut down the module.
Referenced by ecore_win32_shutdown().
Begin a DnD operation.
data | The name pf the Drag operation. |
size | The size of the name. |
EINA_TRUE
on success, EINA_FALSE
otherwise.This function start a Drag operation with the name data
. If data
is NULL
, EINA_FALSE
is returned. if size
is less than 0
, it is set to the length (as strlen()) of data
. On success the function returns EINA_TRUE
, otherwise it returns EINA_FALSE
.
References EINA_FALSE, and EINA_TRUE.
EAPI Eina_Bool ecore_win32_dnd_register_drop_target | ( | Ecore_Win32_Window * | window, |
Ecore_Win32_Dnd_DropTarget_Callback | callback | ||
) |
Register a Drop operation.
window | The destination of the Drop operation. |
callback | The callback called when the Drop operation finishes. |
EINA_TRUE
on success, EINA_FALSE
otherwise.This function register a Drop operation on window
. Once the Drop operation finishes, callback
is called. If window
is NULL
, the function returns EINA_FALSE
. On success, it returns EINA_TRUE
, otherwise it returns EINA_FALSE
.
References EINA_FALSE, and EINA_TRUE.
EAPI void ecore_win32_dnd_unregister_drop_target | ( | Ecore_Win32_Window * | window | ) |
Unregister a Drop operation.
window | The destination of the Drop operation. |
This function unregister a Drop operation on window
. If window
is NULL
, the function does nothing.