API review: Documented changes, corrected str repr, clean up.
This commit is contained in:
parent
f946d87318
commit
7344ad361f
|
@ -0,0 +1,53 @@
|
|||
.. module:: efl
|
||||
|
||||
:py:mod:`efl` Package
|
||||
=====================
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
Logging
|
||||
-------
|
||||
|
||||
PyEFL provides `logging <http://docs.python.org/2/library/logging.html>`_
|
||||
to loggers which are usually named after their equivalent module,
|
||||
f.e. *efl.eo*. There is a root logger called *efl* which also receives
|
||||
any messages coming from the underlying C libraries.
|
||||
|
||||
These loggers have a NullHandler by default and are set to log messages
|
||||
with level logging.WARNING and higher. The child loggers propagate
|
||||
messages to *efl*, which doesn't propagate to the root Python logger,
|
||||
so you need to add handlers to it to get output from it::
|
||||
|
||||
import logging
|
||||
elog = logging.getLogger("efl")
|
||||
elog.addHandler(logging.StreamHandler())
|
||||
|
||||
You should also set its level::
|
||||
|
||||
elog.setLevel(logging.INFO)
|
||||
|
||||
And you may control the child loggers individually::
|
||||
|
||||
elm_log = logging.getLogger("efl.elementary")
|
||||
elm_log.propagate = False
|
||||
elm_log.addHandler(logging.StreamHandler())
|
||||
elm_log.setLevel(logging.ERROR)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
Loggers
|
||||
|
||||
Class properties
|
||||
----------------
|
||||
|
||||
All class properties have their respective _get/_set methods defined.
|
||||
|
||||
These are useful when there are properties with the same name in the
|
||||
inheritance tree, or when you're using a lambda.
|
||||
|
||||
The properties can be applied to the instance by using keyword arguments that
|
||||
are not already used by the constructor, for example like this::
|
||||
|
||||
Button(win, text="I win")
|
||||
|
||||
.. versionadded:: 1.8
|
||||
Using keyword arguments to set properties
|
|
@ -29,41 +29,11 @@ and more.
|
|||
`EFL Overview <http://trac.enlightenment.org/e/wiki/EFLOverview>`_
|
||||
`EFL Documentation <http://web.enlightenment.org/p.php?p=docs>`_
|
||||
|
||||
Logging
|
||||
-------
|
||||
|
||||
PyEFL provides `logging <http://docs.python.org/2/library/logging.html>`_
|
||||
to loggers which are usually named after their equivalent module,
|
||||
f.e. *efl.eo*. There is a root logger called *efl* which also receives
|
||||
any messages coming from the underlying C libraries.
|
||||
EFL
|
||||
---
|
||||
|
||||
These loggers have a NullHandler by default and are set to log messages
|
||||
with level logging.WARNING and higher. The child loggers propagate
|
||||
messages to *efl*, which doesn't propagate to the root Python logger,
|
||||
so you need to add handlers to it to get output from it::
|
||||
|
||||
import logging
|
||||
elog = logging.getLogger("efl")
|
||||
elog.addHandler(logging.StreamHandler())
|
||||
|
||||
You should also set its level::
|
||||
|
||||
elog.setLevel(logging.INFO)
|
||||
|
||||
And you may control the child loggers individually::
|
||||
|
||||
elm_log = logging.getLogger("efl.elementary")
|
||||
elm_log.propagate = False
|
||||
elm_log.addHandler(logging.StreamHandler())
|
||||
elm_log.setLevel(logging.ERROR)
|
||||
|
||||
Class properties
|
||||
----------------
|
||||
|
||||
All class properties have their respective _get/_set methods defined.
|
||||
|
||||
These are useful when there are properties with the same name in the
|
||||
inheritance tree, or when you're using a lambda.
|
||||
.. toctree:: efl.rst
|
||||
|
||||
Ecore
|
||||
-----
|
||||
|
|
|
@ -89,6 +89,33 @@ cdef Eina_Bool _ecore_timeline_cb(void *data, double pos) with gil:
|
|||
return ret
|
||||
|
||||
cdef class AnimatorTimeline(Animator):
|
||||
|
||||
"""
|
||||
|
||||
Add an animator that runs for a limited time
|
||||
|
||||
:param runtime: The time to run in seconds
|
||||
:param func: The function to call when it ticks off
|
||||
|
||||
This is just like a normal :py:class:`Animator` except the animator only
|
||||
runs for a limited time specified in seconds by ``runtime``. Once the
|
||||
runtime the animator has elapsed (animator finished) it will automatically
|
||||
be deleted. The callback function ``func`` can return ECORE_CALLBACK_RENEW
|
||||
to keep the animator running or ECORE_CALLBACK_CANCEL ro stop it and have it
|
||||
be deleted automatically at any time.
|
||||
|
||||
The ``func`` will ALSO be passed a position parameter that will be in value
|
||||
from 0.0 to 1.0 to indicate where along the timeline (0.0 start, 1.0 end)
|
||||
the animator run is at. If the callback wishes not to have a linear
|
||||
transition it can "map" this value to one of several curves and mappings via
|
||||
:py:meth:`Animator.pos_map`.
|
||||
|
||||
.. note:: The default ``frametime`` value is 1/30th of a second.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
|
||||
def __init__(self, func, double runtime, *args, **kargs):
|
||||
if not callable(func):
|
||||
raise TypeError("Parameter 'func' must be callable")
|
||||
|
|
|
@ -344,20 +344,6 @@ cdef class Exe(object):
|
|||
Py_DECREF(self)
|
||||
return 1
|
||||
|
||||
def __str__(self):
|
||||
if self.exe == NULL:
|
||||
pid = None
|
||||
cmd = None
|
||||
flags = ""
|
||||
data = None
|
||||
else:
|
||||
pid = self.pid
|
||||
cmd = self.cmd
|
||||
flags = exe_flags2str(self.flags)
|
||||
data = None
|
||||
return "%s(pid=%s, cmd=%r, flags=[%s], data=%r)" % \
|
||||
(self.__class__.__name__, pid, cmd, flags, data)
|
||||
|
||||
def __repr__(self):
|
||||
if self.exe == NULL:
|
||||
pid = None
|
||||
|
@ -369,8 +355,8 @@ cdef class Exe(object):
|
|||
cmd = self.cmd
|
||||
flags = exe_flags2str(self.flags)
|
||||
data = None
|
||||
return ("%s(%#x, Ecore_Exe=%#x, refcount=%d, pid=%s, cmd=%r, "
|
||||
"flags=[%s], data=%r)") % \
|
||||
return ("<%s(%#x, Ecore_Exe=%#x, refcount=%d, pid=%s, cmd=%r, "
|
||||
"flags=[%s], data=%r)>") % \
|
||||
(self.__class__.__name__, <unsigned long><void *>self,
|
||||
<unsigned long>self.exe, PY_REFCOUNT(self),
|
||||
pid, cmd, flags, data)
|
||||
|
|
|
@ -50,16 +50,18 @@ cdef class FileMonitor(object):
|
|||
print("ECORE_FILE_EVENT_DELETED_DIRECTORY: '%s'" % path)
|
||||
elif event == ecore.ECORE_FILE_EVENT_DELETED_SELF:
|
||||
print("ECORE_FILE_EVENT_DELETED_SELF: '%s'" % path)
|
||||
|
||||
|
||||
ecore.FileMonitor("/tmp", monitor_cb)
|
||||
ecore.main_loop_begin()
|
||||
|
||||
|
||||
|
||||
:param path: The complete path of the folder you want to monitor.
|
||||
:type path: str
|
||||
:param monitor_cb: A callback called when something change in `path`
|
||||
:type monitor_cb: callable
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __init__(self, path, monitor_cb, *args, **kargs):
|
||||
|
||||
|
|
|
@ -26,12 +26,12 @@ cdef class Poller(Eo):
|
|||
ecore poller parlance) for each added poller. Ecore pollers should only be
|
||||
used when the poller doesn't have specific requirements on the exact times
|
||||
to poll.
|
||||
|
||||
|
||||
This architecture means that the main loop is only woken up once to handle
|
||||
all pollers of that type, this will save power as the CPU has more of a
|
||||
chance to go into a low power state the longer it is asleep for, so this
|
||||
should be used in situations where power usage is a concern.
|
||||
|
||||
|
||||
For now only 1 core poller type is supported: ECORE_POLLER_CORE, the default
|
||||
interval for ECORE_POLLER_CORE is 0.125(or 1/8th) second.
|
||||
|
||||
|
@ -41,19 +41,19 @@ cdef class Poller(Eo):
|
|||
defined. Ecore will endeavor to keep pollers synchronized and to call as
|
||||
many in 1 wakeup event as possible. If `interval` is not a power of two, the
|
||||
closest power of 2 greater than `interval` will be used.
|
||||
|
||||
|
||||
When the poller `func` is called, it must return a value of either
|
||||
ECORE_CALLBACK_RENEW(or True) or ECORE_CALLBACK_CANCEL(or False). If it
|
||||
returns 1, it will be called again at the next tick, or if it returns
|
||||
0 it will be deleted automatically making any references/handles for it
|
||||
invalid.
|
||||
|
||||
|
||||
Example::
|
||||
|
||||
def poller_cb():
|
||||
print("Poller")
|
||||
return True
|
||||
|
||||
|
||||
ecore.Poller(4, poller_cb)
|
||||
|
||||
:param interval: The poll interval
|
||||
|
@ -62,7 +62,9 @@ cdef class Poller(Eo):
|
|||
:type func: callable
|
||||
:param poll_type: The ticker type to attach the poller to. Must be ECORE_POLLER_CORE
|
||||
:type poll_type: Ecore_Poll_Type
|
||||
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __init__(self, int interval, func, pol_type=0, *args, **kargs):
|
||||
if not callable(func):
|
||||
|
|
|
@ -82,20 +82,30 @@ cdef class Timer(Eo):
|
|||
ecore_timer_thaw(self.obj)
|
||||
|
||||
def delay(self, double add):
|
||||
""" Delay the execution of the timer by the given amount
|
||||
"""delay(float add)
|
||||
|
||||
Delay the execution of the timer by the given amount
|
||||
|
||||
:param add: seconds to add to the timer
|
||||
:type add: double
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
ecore_timer_delay(self.obj, add)
|
||||
|
||||
def reset(self):
|
||||
"Reset the counter of the timer"
|
||||
"""reset()
|
||||
|
||||
Reset the counter of the timer
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
ecore_timer_reset(self.obj)
|
||||
|
||||
property interval:
|
||||
""" The interval (in seconds) between each call of the timer
|
||||
"""The interval (in seconds) between each call of the timer
|
||||
|
||||
:type: double
|
||||
|
||||
|
@ -112,16 +122,18 @@ cdef class Timer(Eo):
|
|||
return ecore_timer_interval_get(self.obj)
|
||||
|
||||
property pending:
|
||||
""" The pending time for the timer to expire
|
||||
"""The pending time for the timer to expire
|
||||
|
||||
:type: double
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
|
||||
def __get__(self):
|
||||
return ecore_timer_pending_get(self.obj)
|
||||
|
||||
def ecore_timer_pending_get(self):
|
||||
def pending_get(self):
|
||||
ecore_timer_pending_get(self.obj)
|
||||
|
||||
|
||||
|
|
|
@ -147,7 +147,7 @@ cdef class Edje(Object):
|
|||
self._text_change_cb = None
|
||||
self._message_handler_cb = None
|
||||
|
||||
def __str__(self):
|
||||
def __repr__(self):
|
||||
x, y, w, h = self.geometry_get()
|
||||
r, g, b, a = self.color_get()
|
||||
file, group = self.file_get()
|
||||
|
@ -157,19 +157,9 @@ cdef class Edje(Object):
|
|||
else:
|
||||
name_str = ""
|
||||
clip = bool(self.clip_get() is not None)
|
||||
return ("%s(%sfile=%r, group=%r, geometry=(%d, %d, %d, %d), "
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%s, visible=%s)") % \
|
||||
(self.__class__.__name__, name_str, file, group, x, y, w, h,
|
||||
r, g, b, a, self.layer_get(), clip, self.visible_get())
|
||||
|
||||
def __repr__(self):
|
||||
x, y, w, h = self.geometry_get()
|
||||
r, g, b, a = self.color_get()
|
||||
file, group = self.file_get()
|
||||
clip = bool(self.clip_get() is not None)
|
||||
return ("%s(name=%r, file=%r, group=%r, geometry=(%d, %d, %d, %d), "
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%r, visible=%s)") % \
|
||||
(self.__class__.__name__, self.name_get(), file, group,
|
||||
return ("<%s(%sfile=%r, group=%r, geometry=(%d, %d, %d, %d), "
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%r, visible=%s)>") % \
|
||||
(self.__class__.__name__, name_str, file, group,
|
||||
x, y, w, h, r, g, b, a,
|
||||
self.layer_get(), clip, self.visible_get())
|
||||
|
||||
|
@ -193,6 +183,8 @@ cdef class Edje(Object):
|
|||
returns data stored on the Edje (.edj), stored inside a
|
||||
*data* section inside the *group* that defines this object.
|
||||
|
||||
:type: string
|
||||
|
||||
"""
|
||||
if isinstance(key, unicode): key = PyUnicode_AsUTF8String(key)
|
||||
return _ctouni(edje_object_data_get(self.obj,
|
||||
|
@ -201,8 +193,8 @@ cdef class Edje(Object):
|
|||
def file_set(self, file, group):
|
||||
"""Set the file (.edj) and the group to load the Edje object from.
|
||||
|
||||
:param file: the name of the file to load
|
||||
:param group: the name of the group inside the edj to load
|
||||
:param string file: the name of the file to load
|
||||
:param string group: the name of the group inside the edj to load
|
||||
|
||||
:raise EdjeLoadError: if error occurred during load.
|
||||
|
||||
|
@ -218,7 +210,7 @@ cdef class Edje(Object):
|
|||
"""Get the file and group used to load the object.
|
||||
|
||||
:return: the tuple (file, group)
|
||||
:rtype: tuple for str
|
||||
:rtype: tuple of str
|
||||
|
||||
"""
|
||||
cdef const_char *file, *group
|
||||
|
@ -290,6 +282,8 @@ cdef class Edje(Object):
|
|||
:type cancel: bool
|
||||
:rtype: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return bool(edje_object_preload(self.obj, cancel))
|
||||
|
||||
|
@ -362,7 +356,15 @@ cdef class Edje(Object):
|
|||
size)
|
||||
|
||||
property scale:
|
||||
"""The scaling factor for a given Edje object."""
|
||||
"""
|
||||
|
||||
The scaling factor for a given Edje object.
|
||||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, double scale):
|
||||
edje_object_scale_set(self.obj, scale)
|
||||
|
||||
|
@ -375,7 +377,15 @@ cdef class Edje(Object):
|
|||
return edje_object_scale_get(self.obj)
|
||||
|
||||
property mirrored:
|
||||
"""The RTL orientation for this object."""
|
||||
"""
|
||||
|
||||
The RTL orientation for this object.
|
||||
|
||||
:type: int
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, int rtl):
|
||||
edje_object_mirrored_set(self.obj, rtl)
|
||||
|
||||
|
@ -432,6 +442,8 @@ cdef class Edje(Object):
|
|||
:warning: Be advised that invisible parts in the object obj will be
|
||||
taken into account in this calculation.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef int w, h
|
||||
edje_object_size_min_restricted_calc(self.obj, &w, &h, minw, minh)
|
||||
|
@ -460,6 +472,8 @@ cdef class Edje(Object):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return bool(edje_object_update_hints_get(self.obj))
|
||||
|
|
|
@ -299,6 +299,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: int
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_hold_threshold_get()
|
||||
|
@ -326,6 +328,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: int
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_flick_distance_tolerance_get()
|
||||
|
@ -352,6 +356,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_min_friction_get()
|
||||
|
@ -382,6 +388,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_border_friction_get()
|
||||
|
@ -410,6 +418,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_acceleration_threshold_get()
|
||||
|
@ -421,6 +431,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_acceleration_time_limit_get()
|
||||
|
@ -432,6 +444,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_config_scroll_thumbscroll_acceleration_weight_get()
|
||||
|
@ -459,6 +473,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: :ref:`Elm_Softcursor_Mode`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, Elm_Softcursor_Mode mode):
|
||||
elm_config_softcursor_mode_set(mode)
|
||||
|
@ -672,6 +688,8 @@ cdef class Configuration(object):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return bool(elm_config_selection_unfocused_clear_get())
|
||||
|
@ -870,6 +888,8 @@ cdef class Configuration(object):
|
|||
|
||||
:return: The indicator service name according to the rotation degree.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return _ctouni(elm_config_indicator_service_get(rotation))
|
||||
|
||||
|
|
|
@ -812,6 +812,8 @@ cdef class Entry(LayoutClass):
|
|||
|
||||
:param string style: The style user to push
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
if isinstance(style, unicode): style = PyUnicode_AsUTF8String(style)
|
||||
elm_entry_text_style_user_push(self.obj,
|
||||
|
@ -824,6 +826,8 @@ cdef class Entry(LayoutClass):
|
|||
|
||||
:seealso: :py:meth:`text_style_user_push`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_entry_text_style_user_pop(self.obj)
|
||||
|
||||
|
@ -836,6 +840,8 @@ cdef class Entry(LayoutClass):
|
|||
|
||||
:seealso: :py:meth:`text_style_user_push`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return _ctouni(elm_entry_text_style_user_peek(self.obj))
|
||||
|
||||
|
@ -1318,6 +1324,8 @@ cdef class Entry(LayoutClass):
|
|||
:param func: The callback to execute when the item is clicked
|
||||
:type func: function
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef Evas_Smart_Cb cb = NULL
|
||||
if func is not None:
|
||||
|
@ -1411,6 +1419,8 @@ cdef class Entry(LayoutClass):
|
|||
:param func: The function to use as text filter
|
||||
:param data: User data to pass to ``func``
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cb_data = (func, data)
|
||||
# TODO: This is now a ref leak. It should be stored somewhere and
|
||||
|
@ -1431,6 +1441,8 @@ cdef class Entry(LayoutClass):
|
|||
:param func: The function to use as text filter
|
||||
:param data: User data to pass to ``func``
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cb_data = (func, data)
|
||||
Py_INCREF(cb_data)
|
||||
|
@ -1449,6 +1461,8 @@ cdef class Entry(LayoutClass):
|
|||
:param func: The filter function to remove
|
||||
:param data: The user data passed when adding the function
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cb_data = (func, data)
|
||||
Py_INCREF(cb_data)
|
||||
|
@ -1456,9 +1470,19 @@ cdef class Entry(LayoutClass):
|
|||
py_elm_entry_filter_cb,
|
||||
<void *>cb_data)
|
||||
|
||||
markup_to_utf8 = staticmethod(DEPRECATED("1.8", "Use module level markup_to_utf8() instead.")(Entry_markup_to_utf8))
|
||||
@DEPRECATED("1.8", "Use the module level markup_to_utf8() method instead.")
|
||||
def markup_to_utf8(self, string):
|
||||
"""markup_to_utf8(string)"""
|
||||
if isinstance(string, unicode): string = PyUnicode_AsUTF8String(string)
|
||||
return _touni(elm_entry_markup_to_utf8(
|
||||
<const_char *>string if string is not None else NULL))
|
||||
|
||||
utf8_to_markup = staticmethod(DEPRECATED("1.8", "Use module level utf8_to_markup() instead.")(Entry_utf8_to_markup))
|
||||
@DEPRECATED("1.8", "Use the module level utf8_to_markup() method instead.")
|
||||
def utf8_to_markup(self, string):
|
||||
"""utf8_to_markup(string)"""
|
||||
if isinstance(string, unicode): string = PyUnicode_AsUTF8String(string)
|
||||
return _touni(elm_entry_utf8_to_markup(
|
||||
<const_char *>string if string is not None else NULL))
|
||||
|
||||
property file:
|
||||
"""The file for the text to display and then edit.
|
||||
|
@ -1572,6 +1596,8 @@ cdef class Entry(LayoutClass):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint setting):
|
||||
elm_entry_end_visible_set(self.obj, setting)
|
||||
|
@ -1621,6 +1647,8 @@ cdef class Entry(LayoutClass):
|
|||
|
||||
:type: :ref:`Elm_Entry_Autocapital_Type`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, Elm_Autocapital_Type autocapital_type):
|
||||
elm_entry_autocapital_type_set(self.obj, autocapital_type)
|
||||
|
|
|
@ -268,6 +268,8 @@ cdef class Flip(Object):
|
|||
Flips the front and back contents using the ``flip_mode`` animation. This
|
||||
effectively hides the currently visible content and shows the hidden one.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_flip_go_to(self.obj, front, flip_mode)
|
||||
|
||||
|
|
|
@ -361,6 +361,8 @@ def cache_all_flush():
|
|||
|
||||
.. note:: Evas caches are flushed for every canvas associated with a window.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_cache_all_flush()
|
||||
|
||||
|
@ -377,6 +379,8 @@ def font_properties_get(font not None):
|
|||
:py:func:`font_fontconfig_name_get`, for one style only (single font
|
||||
instance, not family).
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
if isinstance(font, unicode): font = PyUnicode_AsUTF8String(font)
|
||||
cdef FontProperties ret = FontProperties.__new__()
|
||||
|
@ -390,6 +394,8 @@ def font_properties_free(FontProperties fp):
|
|||
|
||||
:param fp: the font properties struct
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_font_properties_free(fp.efp)
|
||||
Py_DECREF(fp)
|
||||
|
@ -409,6 +415,8 @@ def font_fontconfig_name_get(font_name, style = None):
|
|||
:py:func:`font_properties_get`, for one style only (single font
|
||||
instance, not family).
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
unicode ret
|
||||
|
@ -458,6 +466,8 @@ def object_tree_dump(evasObject top):
|
|||
|
||||
:param top: The root object
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_object_tree_dump(top.obj)
|
||||
|
||||
|
@ -469,6 +479,8 @@ def object_tree_dot_dump(evasObject top, path):
|
|||
:param top: The root object
|
||||
:param path: The path of output file
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
if isinstance(path, unicode): path = PyUnicode_AsUTF8String(path)
|
||||
elm_object_tree_dot_dump(top.obj, <const_char *>path)
|
||||
|
|
|
@ -67,6 +67,8 @@ cdef class GengridItem(ObjectItem):
|
|||
|
||||
Append a new item (add as last item) to this gengrid.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
Elm_Object_Item *item
|
||||
|
@ -91,6 +93,8 @@ cdef class GengridItem(ObjectItem):
|
|||
|
||||
Prepend a new item (add as first item) to this gengrid.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
Elm_Object_Item *item
|
||||
|
@ -117,6 +121,8 @@ cdef class GengridItem(ObjectItem):
|
|||
:param before: a reference item to use, the new item
|
||||
will be inserted before it.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
Elm_Object_Item *item
|
||||
|
@ -144,6 +150,8 @@ cdef class GengridItem(ObjectItem):
|
|||
:param after: a reference item to use, the new item
|
||||
will be inserted after it.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
Elm_Object_Item *item
|
||||
|
@ -171,6 +179,8 @@ cdef class GengridItem(ObjectItem):
|
|||
:param after: a reference item to use, the new item
|
||||
will be inserted after it.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
Elm_Object_Item *item
|
||||
|
|
|
@ -129,15 +129,27 @@ cdef class GengridItemClass:
|
|||
self._del_func)
|
||||
|
||||
def ref(self):
|
||||
"""Increase the C level reference count."""
|
||||
"""Increase the C level reference count.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_gengrid_item_class_ref(self.cls)
|
||||
|
||||
def unref(self):
|
||||
"""Decrease the C level reference count."""
|
||||
"""Decrease the C level reference count.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_gengrid_item_class_unref(self.cls)
|
||||
|
||||
def free(self):
|
||||
"""Free the C level struct."""
|
||||
"""Free the C level struct.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_gengrid_item_class_free(self.cls)
|
||||
|
||||
property item_style:
|
||||
|
|
|
@ -469,6 +469,8 @@ cdef class Gengrid(Object):
|
|||
based if the coordinate is above or below all items respectively in
|
||||
the gengrid.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
int xposret, yposret
|
||||
|
|
|
@ -142,15 +142,27 @@ cdef class GenlistItemClass(object):
|
|||
self._del_func)
|
||||
|
||||
def ref(self):
|
||||
"""Increase the C level reference count."""
|
||||
"""Increase the C level reference count.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_genlist_item_class_ref(self.cls)
|
||||
|
||||
def unref(self):
|
||||
"""Decrease the C level reference count."""
|
||||
"""Decrease the C level reference count.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_genlist_item_class_unref(self.cls)
|
||||
|
||||
def free(self):
|
||||
"""Free the C level struct."""
|
||||
"""Free the C level struct.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_genlist_item_class_free(self.cls)
|
||||
|
||||
property item_style:
|
||||
|
|
|
@ -664,6 +664,8 @@ cdef class Genlist(Object):
|
|||
key movement. Clicking on a focusable widget inside an item will
|
||||
couse this particular item to get focus as usual.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint enabled):
|
||||
elm_genlist_focus_on_selection_set(self.obj, enabled)
|
||||
|
|
|
@ -544,6 +544,8 @@ cdef class Index(LayoutClass):
|
|||
|
||||
.. note:: Delay time is 0.2 sec by default.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, double delay_change_time):
|
||||
elm_index_delay_change_time_set(self.obj, delay_change_time)
|
||||
|
|
|
@ -11,7 +11,7 @@ cdef extern from "Elementary.h":
|
|||
Eina_Bool elm_label_ellipsis_get(Evas_Object *obj)
|
||||
void elm_label_slide_duration_set(Evas_Object *obj, double duration)
|
||||
double elm_label_slide_duration_get(Evas_Object *obj)
|
||||
void elm_label_slide_area_limit_set(Evas_Object *obj, Eina_Bool limit)
|
||||
# TODO: void elm_label_slide_area_limit_set(Evas_Object *obj, Eina_Bool limit)
|
||||
void elm_label_slide_mode_set(Evas_Object *obj, Elm_Label_Slide_Mode mode)
|
||||
Elm_Label_Slide_Mode elm_label_slide_mode_get(const_Evas_Object *obj)
|
||||
void elm_label_slide_go(Evas_Object *obj)
|
||||
|
|
|
@ -227,19 +227,18 @@ cdef class Label(LayoutClass):
|
|||
def slide_duration_get(self):
|
||||
return elm_label_slide_duration_get(self.obj)
|
||||
|
||||
# TODO: In header but not implemented yet?
|
||||
# TODO: What the heck does this do?
|
||||
# property slide_area_limit:
|
||||
# """
|
||||
# Slide only if the
|
||||
|
||||
# :type: bool
|
||||
|
||||
# """
|
||||
# def __set__(self, bint value):
|
||||
# elm_label_slide_area_limit_set(self.obj, limit)
|
||||
# .. versionadded:: 1.8
|
||||
|
||||
# def __get__(self):
|
||||
# return elm_label_slide_area_limit_set(self.obj)
|
||||
# """
|
||||
# def __set__(self, bint limit):
|
||||
# elm_label_slide_area_limit_set(self.obj, limit)
|
||||
|
||||
property slide_mode:
|
||||
"""Change the slide mode of the label widget.
|
||||
|
|
|
@ -210,6 +210,8 @@ cdef class LayoutClass(Object):
|
|||
|
||||
:see: :py:func:`thaw`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return elm_layout_freeze(self.obj)
|
||||
|
||||
|
@ -226,6 +228,8 @@ cdef class LayoutClass(Object):
|
|||
|
||||
:see: :py:func:`freeze`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return elm_layout_thaw(self.obj)
|
||||
|
||||
|
@ -904,8 +908,7 @@ cdef class LayoutClass(Object):
|
|||
|
||||
:raise RuntimeError: if accessibility cannot be set.
|
||||
|
||||
.. versionchanged:: 1.8
|
||||
Raises RuntimeError if setting accessibility fails
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, can_access):
|
||||
|
|
|
@ -934,6 +934,7 @@ cdef class List(Object):
|
|||
based if the coordinate is above or below all items respectively in
|
||||
the list.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef:
|
||||
|
@ -955,6 +956,8 @@ cdef class List(Object):
|
|||
clicking an unfocusable area in an item or selecting it with a key movement. Clicking on a
|
||||
focusable widget inside an item will couse this particular item to get focus as usual.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint enabled):
|
||||
elm_list_focus_on_selection_set(self.obj, enabled)
|
||||
|
|
|
@ -114,6 +114,8 @@ cdef class Mapbuf(Object):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint on):
|
||||
elm_mapbuf_auto_set(self.obj, on)
|
||||
|
|
|
@ -168,6 +168,9 @@ cdef class MenuItem(ObjectItem):
|
|||
|
||||
:type: tuple of :py:class:`MenuItem`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
Calling del on this property clears the subitems
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return _object_item_list_to_python(elm_menu_item_subitems_get(self.item))
|
||||
|
|
|
@ -414,6 +414,8 @@ cdef class MultiButtonEntry(Object):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint editable):
|
||||
elm_multibuttonentry_editable_set(self.obj, editable)
|
||||
|
|
|
@ -1240,6 +1240,8 @@ cdef class Object(evasObject):
|
|||
|
||||
:type: int
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_object_scroll_hold_get(self.obj)
|
||||
|
@ -1274,6 +1276,8 @@ cdef class Object(evasObject):
|
|||
|
||||
:type: int
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_object_scroll_freeze_get(self.obj)
|
||||
|
|
|
@ -425,6 +425,9 @@ cdef class Scrollable(Object):
|
|||
|
||||
:type: (int **h_pagesize**, int **v_pagesize**)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
Getter for this property
|
||||
|
||||
"""
|
||||
def __set__(self, value):
|
||||
h_pagesize, v_pagesize = value
|
||||
|
|
|
@ -9,7 +9,7 @@ cdef extern from "Elementary.h":
|
|||
const_char * elm_slider_unit_format_get(const_Evas_Object *obj)
|
||||
void elm_slider_indicator_format_set(Evas_Object *obj, const_char *indicator)
|
||||
const_char * elm_slider_indicator_format_get(const_Evas_Object *obj)
|
||||
void elm_slider_indicator_format_function_set(Evas_Object *obj, const_char(*func)(double val), void (*free_func)(const_char *str))
|
||||
# TODO: void elm_slider_indicator_format_function_set(Evas_Object *obj, const_char(*func)(double val), void (*free_func)(const_char *str))
|
||||
# TODO: void elm_slider_units_format_function_set(Evas_Object *obj, const_char *(*func)(double val), void (*free_func)(const_char *str))
|
||||
void elm_slider_horizontal_set(Evas_Object *obj, Eina_Bool horizontal)
|
||||
Eina_Bool elm_slider_horizontal_get(const_Evas_Object *obj)
|
||||
|
|
|
@ -265,8 +265,6 @@ cdef class Spinner(LayoutClass):
|
|||
:param label: The label to be used.
|
||||
:type label: unicode
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
if isinstance(label, unicode): label = PyUnicode_AsUTF8String(label)
|
||||
elm_spinner_special_value_add(self.obj, value,
|
||||
|
|
|
@ -154,6 +154,8 @@ cdef class Table(Object):
|
|||
|
||||
:return: Child of object if find if not return None.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return object_from_instance(elm_table_child_get(self.obj, col, row))
|
||||
|
||||
|
|
|
@ -956,6 +956,8 @@ cdef class Toolbar(LayoutClass):
|
|||
transverse length of the toolbar. The default is what the transverse
|
||||
length of the item is set according its min value (this property is False).
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint transverse_expanded):
|
||||
elm_toolbar_transverse_expanded_set(self.obj, transverse_expanded)
|
||||
|
@ -1101,6 +1103,8 @@ cdef class Toolbar(LayoutClass):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint reorder_mode):
|
||||
elm_toolbar_reorder_mode_set(self.obj, reorder_mode)
|
||||
|
|
|
@ -535,6 +535,8 @@ cdef class Transit(object):
|
|||
|
||||
:type: (float **v1**, float **v2**) (defaults are 1.0, 0.0)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, value):
|
||||
cdef float v1, v2
|
||||
|
|
|
@ -249,9 +249,19 @@ cdef class WebWindowFeatures(object):
|
|||
return x, y, w, h
|
||||
|
||||
def ref(self):
|
||||
"""
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_web_window_features_ref(self.wf);
|
||||
|
||||
def unref(self):
|
||||
"""
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_web_window_features_unref(self.wf)
|
||||
|
||||
cdef class Web(Object):
|
||||
|
@ -494,6 +504,8 @@ cdef class Web(Object):
|
|||
|
||||
:raise RuntimeError: if url could not be set
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, url):
|
||||
if isinstance(url, unicode): url = PyUnicode_AsUTF8String(url)
|
||||
|
|
|
@ -766,6 +766,8 @@ cdef class Window(Object):
|
|||
|
||||
:type: :py:class:`efl.evas.Object`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return object_from_instance(elm_win_main_menu_get(self.obj))
|
||||
|
@ -1064,6 +1066,8 @@ cdef class Window(Object):
|
|||
:py:attr:`norender`
|
||||
:py:func:`render`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_win_norender_push(self.obj)
|
||||
|
||||
|
@ -1079,6 +1083,8 @@ cdef class Window(Object):
|
|||
:py:attr:`norender`
|
||||
:py:func:`render`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_win_norender_pop(self.obj)
|
||||
|
||||
|
@ -1092,6 +1098,8 @@ cdef class Window(Object):
|
|||
:py:func:`norender_pop`
|
||||
:py:func:`render`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return elm_win_norender_get(self.obj)
|
||||
|
@ -1115,6 +1123,8 @@ cdef class Window(Object):
|
|||
:py:func:`norender_pop`
|
||||
:py:attr:`norender`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
elm_win_render(self.obj)
|
||||
|
||||
|
@ -1369,6 +1379,8 @@ cdef class Window(Object):
|
|||
|
||||
:type: (int X_DPI, int Y_DPI)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
cdef int xdpi, ydpi
|
||||
|
@ -1432,6 +1444,8 @@ cdef class Window(Object):
|
|||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __set__(self, bint enabled):
|
||||
elm_win_focus_highlight_animate_set(self.obj, enabled)
|
||||
|
@ -1582,7 +1596,7 @@ cdef class Window(Object):
|
|||
# """
|
||||
# Ecore_Wl_Window *elm_win_wl_window_get(const Evas_Object *obj)
|
||||
|
||||
property floating:
|
||||
property floating_mode:
|
||||
"""Floating mode of a window.
|
||||
|
||||
:type: bool
|
||||
|
@ -1596,9 +1610,9 @@ cdef class Window(Object):
|
|||
def __get__(self):
|
||||
return bool(elm_win_floating_mode_get(self.obj))
|
||||
|
||||
def floating_set(self, floating):
|
||||
def floating_mode_set(self, floating):
|
||||
elm_win_floating_mode_set(self.obj, floating)
|
||||
def floating_get(self):
|
||||
def floating_mode_get(self):
|
||||
return bool(elm_win_floating_mode_get(self.obj))
|
||||
|
||||
# TODO:
|
||||
|
|
|
@ -131,8 +131,14 @@ def shutdown():
|
|||
|
||||
|
||||
def webcams_get():
|
||||
""" Get a list of active and available webcam.
|
||||
"""webcams_get() -> list
|
||||
|
||||
Get a list of active and available webcam.
|
||||
|
||||
:return: the list of tuple (webcam name, webcam device)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
cdef const_Eina_List *lst, *itr
|
||||
cdef Emotion_Webcam *cam
|
||||
|
@ -150,7 +156,9 @@ def webcams_get():
|
|||
return ret
|
||||
|
||||
def extension_may_play_get(filename):
|
||||
""" Do we have a chance to play that file?
|
||||
"""extension_may_play_get(filename) -> bool
|
||||
|
||||
Do we have a chance to play that file?
|
||||
|
||||
This just actually look at the extention of the file, it doesn't check
|
||||
the mime-type nor if the file is actually sane. So this is just an
|
||||
|
@ -159,6 +167,8 @@ def extension_may_play_get(filename):
|
|||
:param filename: A filename that we want to know if Emotion can play.
|
||||
:type filename: str
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
if isinstance(filename, unicode): filename = PyUnicode_AsUTF8String(filename)
|
||||
return bool(emotion_object_extension_may_play_get(
|
||||
|
@ -166,7 +176,9 @@ def extension_may_play_get(filename):
|
|||
|
||||
|
||||
cdef class Emotion(evasObject):
|
||||
""" The emotion object
|
||||
"""
|
||||
|
||||
The Emotion object
|
||||
|
||||
:see: :py:mod:`The documentation page<efl.emotion>`
|
||||
|
||||
|
@ -180,6 +192,9 @@ cdef class Emotion(evasObject):
|
|||
:param color: (r, g, b, a)
|
||||
:return: The emotion object instance just created.
|
||||
|
||||
.. versionchanged:: 1.8
|
||||
Keyword argument module_filename was renamed to module_name.
|
||||
|
||||
"""
|
||||
def __cinit__(self, *a, **ka):
|
||||
self._emotion_callbacks = {}
|
||||
|
@ -205,26 +220,12 @@ cdef class Emotion(evasObject):
|
|||
|
||||
self._set_properties_from_keyword_args(kwargs)
|
||||
|
||||
def __str__(self):
|
||||
x, y, w, h = self.geometry_get()
|
||||
r, g, b, a = self.color_get()
|
||||
name = self.name_get()
|
||||
if name:
|
||||
name_str = "name=%r, "
|
||||
else:
|
||||
name_str = ""
|
||||
return ("%s(%sfile=%r, geometry=(%d, %d, %d, %d), "
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%s, visible=%s)") % \
|
||||
(self.__class__.__name__, name_str, self.file_get(), x, y, w, h,
|
||||
r, g, b, a, self.layer_get(), self.clip_get(),
|
||||
self.visible_get())
|
||||
|
||||
def __repr__(self):
|
||||
x, y, w, h = self.geometry_get()
|
||||
r, g, b, a = self.color_get()
|
||||
return ("%s(%#x, type=%r, name=%r, "
|
||||
return ("<%s(%#x, type=%r, name=%r, "
|
||||
"file=%r, geometry=(%d, %d, %d, %d), "
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%r, visible=%s) %s") % \
|
||||
"color=(%d, %d, %d, %d), layer=%s, clip=%r, visible=%s) %s>") % \
|
||||
(self.__class__.__name__, <unsigned long><void *>self,
|
||||
self.type_get(), self.name_get(), self.file_get(),
|
||||
x, y, w, h, r, g, b, a,
|
||||
|
@ -318,6 +319,9 @@ cdef class Emotion(evasObject):
|
|||
default, an Emotion object doesn't have any border.
|
||||
|
||||
:type: tuple of int (l, r, t, b)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
cdef int l, r, t, b
|
||||
|
@ -346,6 +350,9 @@ cdef class Emotion(evasObject):
|
|||
The default color is (0, 0, 0, 0)
|
||||
|
||||
:type: tuple of int (r, g, b, a)
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
cdef int r, g, b, a
|
||||
|
@ -400,6 +407,9 @@ cdef class Emotion(evasObject):
|
|||
set the aspect policy to #EMOTION_ASPECT_CUSTOM.
|
||||
|
||||
:type: Emotion_Aspect
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return emotion_object_keep_aspect_get(self.obj)
|
||||
|
@ -417,6 +427,9 @@ cdef class Emotion(evasObject):
|
|||
For supported subtitle formats consult the backend's documentation.
|
||||
|
||||
:type: str
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return _ctouni(emotion_object_video_subtitle_file_get(self.obj))
|
||||
|
@ -450,6 +463,9 @@ cdef class Emotion(evasObject):
|
|||
*True* means high priority.
|
||||
|
||||
:type: bool
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return bool(emotion_object_priority_get(self.obj))
|
||||
|
@ -480,6 +496,9 @@ cdef class Emotion(evasObject):
|
|||
or object resolution if lower
|
||||
|
||||
:type: Emotion_Suspend
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return emotion_object_suspend_get(self.obj)
|
||||
|
@ -561,6 +580,9 @@ cdef class Emotion(evasObject):
|
|||
represents the normal speed, 2 double speed, 0.5 half speed and so on.
|
||||
|
||||
:type: float
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __get__(self):
|
||||
return emotion_object_play_speed_get(self.obj)
|
||||
|
@ -1022,6 +1044,8 @@ cdef class Emotion(evasObject):
|
|||
Every operation is fully asynchronous and not linked to the actual
|
||||
engine used to play the video.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
emotion_object_last_position_load(self.obj)
|
||||
|
||||
|
@ -1030,6 +1054,8 @@ cdef class Emotion(evasObject):
|
|||
|
||||
:see: :py:meth:`last_position_load`
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
emotion_object_last_position_save(self.obj)
|
||||
|
||||
|
@ -1038,10 +1064,14 @@ cdef class Emotion(evasObject):
|
|||
emotion object.
|
||||
|
||||
This function is usefull when you want to get a direct access to the pixels.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
return object_from_instance(emotion_object_image_get(self.obj))
|
||||
|
||||
property vis:
|
||||
# TODO: document this
|
||||
def __get__(self):
|
||||
return emotion_object_vis_get(self.obj)
|
||||
|
||||
|
|
|
@ -67,7 +67,13 @@ EVAS_TEXTGRID_FONT_STYLE_ITALIC = enums.EVAS_TEXTGRID_FONT_STYLE_ITALIC
|
|||
|
||||
|
||||
cdef class TextgridCell(object):
|
||||
"""The values that describe each cell."""
|
||||
"""
|
||||
|
||||
The values that describe each cell.
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
|
||||
cdef Evas_Textgrid_Cell *cell
|
||||
|
||||
|
@ -212,6 +218,11 @@ cdef class TextgridCell(object):
|
|||
|
||||
cdef class Textgrid(Object):
|
||||
|
||||
"""
|
||||
|
||||
.. versionadded:: 1.8
|
||||
|
||||
"""
|
||||
def __init__(self, Canvas canvas not None, **kwargs):
|
||||
self._set_obj(evas_object_textgrid_add(canvas.obj))
|
||||
self._set_properties_from_keyword_args(kwargs)
|
||||
|
|
Loading…
Reference in New Issue