Package ecore :: Package evas :: Module c_ecore_evas :: Class EcoreEvas
[hide private]
[frames] | no frames]

Class EcoreEvas

object --+
         |
        EcoreEvas
Known Subclasses:

Integration of Ecore and Evas providing a Window.

This class does the integration of ecore and evas, setups the correct evas engine and handle events, redraws and other requeriments for a properly working system.

Instance Methods [hide private]
a new object with type S, a subtype of T
__new__(T, S, ...)
 
__repr__(...)
repr(x)
 
__str__(...)
str(x)
 
activate(...)
bool
alpha_get(...)
Get whether the object has an alpha channel or not.
 
alpha_set(...)
Set whether the object has an alpha channel or not.
bool
associate(...)
Associate the given object to this ecore evas.
evas object.
associate_get(...)
Get the associated object.
int
avoid_damage_get(...)
 
avoid_damage_set(...)
bool
borderless_get(...)
 
borderless_set(...)
(object, int, int, int)
cursor_get(...)
 
cursor_set(...)
Set window cursor to some file (image) or any Evas Object.
bool
dissociate(...)
Reverts the effect of associate()
evas.c_evas.Canvas
evas_get(...)
bool
focus_get(...)
 
focus_set(...)
 
fullscreen_get(...)
bool
fullscreen_set(...)
tuple of int
geometry_get(...)
 
geometry_set(...)
Same as move_resize().
 
hide(...)
bool
iconified_get(...)
 
iconified_set(...)
bool
ignore_events_get(...)
 
ignore_events_set(...)
int
layer_get(...)
 
layer_set(...)
 
lower(...)
 
managed_move(...)
This sets the managed geometry position of the window.
bool
maximized_get(...)
 
maximized_set(...)
 
move(...)
Move window to given position.
 
move_resize(...)
Move and resize the window.
tuple of str
name_class_get(...)
 
name_class_set(...)
Set name and class for this window (WM_CLASS)
 
object_cursor_set(...)
Set window cursor to any Evas Object.
bool
override_get(...)
 
override_set(...)
tuple of int
pos_get(...)
 
pos_set(...)
Same as move()
 
raise_(...)
 
resize(...)
Resize window to given size.
int
rotation_get(...)
Get rotation angle, in degrees.
 
rotation_set(...)
Set rotation angle, in degrees.
bool
shaped_get(...)
Get whether the object is shaped or not.
 
shaped_set(...)
Set whether the object is shaped or not.
 
show(...)
tuple of int
size_base_get(...)
 
size_base_set(...)
tuple of int
size_get(...)
tuple of int
size_max_get(...)
 
size_max_set(...)
tuple of int
size_min_get(...)
 
size_min_set(...)
 
size_set(...)
Same as resize()
tuple of int
size_step_get(...)
 
size_step_set(...)
This limits the size of window to always being an integer multiple of the step size.
bool
sticky_get(...)
 
sticky_set(...)
str
title_get(...)
 
title_set(...)
bool
visibility_get(...)
 
visibility_set(...)
bool
withdrawn_get(...)
 
withdrawn_set(...)

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __init__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __subclasshook__

    Callbacks
callable
callback_delete_request_get(...)
 
callback_delete_request_set(...)
Set function to be called when window gets a delete request.
callable
callback_destroy_get(...)
 
callback_destroy_set(...)
Set function to be called when window is destroyed.
callable
callback_focus_in_get(...)
 
callback_focus_in_set(...)
Set function to be called when window gets focus.
callable
callback_focus_out_get(...)
 
callback_focus_out_set(...)
Set function to be called when window is loses focus.
callable
callback_hide_get(...)
 
callback_hide_set(...)
Set function to be called when window is hidden.
callable
callback_mouse_in_get(...)
 
callback_mouse_in_set(...)
Set function to be called when mouse enters window.
callable
callback_mouse_out_get(...)
 
callback_mouse_out_set(...)
Set function to be called when mouse leaves window.
callable
callback_move_get(...)
 
callback_move_set(...)
Set function to be called when window is moved.
callable
callback_post_render_get(...)
 
callback_post_render_set(...)
Set function to be called after evas is rendered.
callable
callback_pre_render_get(...)
 
callback_pre_render_set(...)
Set function to be called before evas is rendered.
callable
callback_resize_get(...)
 
callback_resize_set(...)
Set function to be called when window is resized.
callable
callback_show_get(...)
 
callback_show_set(...)
Set function to be called when window is shown.
callable
callback_sticky_get(...)
 
callback_sticky_set(...)
Set function to be called when window becomes sticky.
callable
callback_unsticky_get(...)
 
callback_unsticky_set(...)
Set function to be called when window becomes un-sticky.
Instance Variables [hide private]
  alpha
if using alpha channel or not.
  avoid_damage
if avoiding damage or not.
  borderless
if window have border or not.
  evas
associated Evas canvas.
  focus
if window have focus or not.
  fullscreen
if window is fullscreen.
  geometry
position and size.
  iconified
if window is minimized (iconified).
  ignore_events
if window ignores events or not.
  layer
which layer this window is.
  maximized
if window is maximized or not.
  name_class
(name, class) that identifies this window (WM_CLASS)
  override
if the WM should ignore or not this window.
  pos
window position.
  rotation
if window contents should be rotated or not.
  shaped
if window is shaped or not.
  size
window size.
  size_base
window base size.
  size_max
maximum size.
  size_min
minimum size.
  size_step
size must be multiple of these values.
  sticky
if window is sticky or not.
  title
window title.
  visibility
if window is visible or not.
  withdrawn
if window is withdrawn or not.
    Callbacks
  callback_delete_request
callback used to handle delete events.
  callback_destroy
callback used to handle destroy events.
  callback_focus_in
callback used to handle focus in events.
  callback_focus_out
callback used to handle focus out events.
  callback_hide
callback used to handle hide events.
  callback_mouse_in
callback used to handle mouse in events.
  callback_mouse_out
callback used to handle mouse out events.
  callback_move
callback used to handle move events.
  callback_post_render
callback used after render.
  callback_pre_render
callback used before render.
  callback_resize
callback used to handle resize events.
  callback_show
callback used to handle show events.
  callback_sticky
callback used to handle sticky events.
  callback_unsticky
callback used to handle unsticky events.
Properties [hide private]
  data

Inherited from object: __class__

Method Details [hide private]

__new__(T, S, ...)

 
Returns: a new object with type S, a subtype of T
Overrides: object.__new__

__repr__(...)
(Representation operator)

 

repr(x)

Overrides: object.__repr__
(inherited documentation)

__str__(...)
(Informal representation operator)

 

str(x)

Overrides: object.__str__
(inherited documentation)

alpha_set(...)

 

Set whether the object has an alpha channel or not.

This method allows you to make an EcoreEvas translucent using an alpha channel. See shaped_set() for details. The difference between a shaped window and a window with an alpha channel is that an alpha channel supports multiple levels of transpararency, as opposed to the 1 bit transparency of a shaped window (a pixel is either opaque, or it's transparent).

associate(...)

 

Associate the given object to this ecore evas.

Association means that operations on one will affect the other, for example moving the object will move the window, resize the object will also affect the ecore evas window, hide and show applies as well.

This is meant to simplify development, since you often need to associate these events with your"base" objects, background or bottom-most object.

Be aware that some methods might not be what you would like, deleting either the window or the object will delete the other. If you want to change that behavior, let's say to hide window when it's closed, you must use ecore_evas_callback_delete_request_set() and set your own code, like ecore_evas_hide(). Just remember that if you override delete_request and still want to delete the window/object, you must do that yourself.

Since we now define delete_request, deleting windows will not quit main loop, if you wish to do so, you should listen for EVAS_CALLBACK_FREE on the object, that way you get notified and you can call ecore_main_loop_quit().

Flags can be OR'ed of:

  • ECORE_EVAS_OBJECT_ASSOCIATE_BASE (or 0): to listen to basic events like delete, resize and move, but no stacking or layer are used.
  • ECORE_EVAS_OBJECT_ASSOCIATE_STACK: stacking operations will act on the Ecore_Evas, not the object. So evas_object_raise() will call ecore_evas_raise(). Relative operations (stack_above, stack_below) are still not implemented.
  • ECORE_EVAS_OBJECT_ASSOCIATE_LAYER: stacking operations will act on the Ecore_Evas, not the object. So evas_object_layer_set() will call ecore_evas_layer_set().
Returns: bool
true on success, false otherwise.

callback_delete_request_set(...)

 

Set function to be called when window gets a delete request.

Signature: function(object)

callback_destroy_set(...)

 

Set function to be called when window is destroyed.

Signature: function(object)

callback_focus_in_set(...)

 

Set function to be called when window gets focus.

Signature: function(object)

callback_focus_out_set(...)

 

Set function to be called when window is loses focus.

Signature: function(object)

callback_hide_set(...)

 

Set function to be called when window is hidden.

Signature: function(object)

callback_mouse_in_set(...)

 

Set function to be called when mouse enters window.

Signature: function(object)

callback_mouse_out_set(...)

 

Set function to be called when mouse leaves window.

Signature: function(object)

callback_move_set(...)

 

Set function to be called when window is moved.

Signature: function(object)

callback_post_render_set(...)

 

Set function to be called after evas is rendered.

Signature: function(object)

callback_pre_render_set(...)

 

Set function to be called before evas is rendered.

Signature: function(object)

callback_resize_set(...)

 

Set function to be called when window is resized.

Signature: function(object)

callback_show_set(...)

 

Set function to be called when window is shown.

Signature: function(object)

callback_sticky_set(...)

 

Set function to be called when window becomes sticky.

Signature: function(object)

callback_unsticky_set(...)

 

Set function to be called when window becomes un-sticky.

Signature: function(object)

rotation_set(...)

 

Set rotation angle, in degrees.

Acceptable values depends on underlying engine, but usually this is multiple of 90 degrees.

shaped_get(...)

 

Get whether the object is shaped or not.

A shaped EcoreEvas will be transparent in areas without any evas.c_evas.Object.

Returns: bool

shaped_set(...)

 

Set whether the object is shaped or not.

If true, EcoreEvas will be transparent in areas without any evas.c_evas.Object.