From: Enlightenment S. <no-...@en...> - 2012-06-06 23:30:06
|
Log: python-elementary: Correct formatting etc. mistakes in documentation. Author: kuuko Date: 2012-06-06 16:29:57 -0700 (Wed, 06 Jun 2012) New Revision: 71768 Trac: http://trac.enlightenment.org/e/changeset/71768 Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_actionslider.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_background.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_box.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_bubble.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_button.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_calendar.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_check.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_clock.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_colorselector.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_ctxpopup.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_entry.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_fileselector.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_fileselector_button.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_fileselector_entry.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_flip.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_frame.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_hover.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_hoversel.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_icon.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_image.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_index.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_innerwindow.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_list.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_naviframe.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_object.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_object_item.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_slider.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_spinner.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_toolbar.pxi trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_window.pxi Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_actionslider.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_actionslider.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_actionslider.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -25,30 +25,35 @@ cdef public class Actionslider(Object) [object PyElementaryActionslider, type PyElementaryActionslider_Type]: - """An actionslider is a switcher for two or three labels with customizable magnet properties. + """An actionslider is a switcher for two or three labels with + customizable magnet properties. The user drags and releases the indicator, to choose a label. Labels can occupy the following positions. - - Left - - Right - - Center + - Left + - Right + - Center Positions can be enabled or disabled. Magnets can be set on the above positions. - When the indicator is released, it will move to its nearest "enabled and magnetized" position. + When the indicator is released, it will move to its nearest "enabled and + magnetized" position. - This widget emits the following X{signals}, besides the ones sent from L{Layout}: - - B{selected} - when user selects an enabled position (the label is passed as event info)". - - B{pos_changed} - when the indicator reaches any of the positions("left", "right" or "center"). + This widget emits the following signals, besides the ones sent from + L{Layout}: + - B{selected} - when user selects an enabled position (the label is + passed as event info)". + - B{pos_changed} - when the indicator reaches any of the + positions("left", "right" or "center"). - Default X{text parts} of the actionslider widget that you can use for are: - - B{indicator} - An indicator label of the actionslider - - B{left} - A left label of the actionslider - - B{right} - A right label of the actionslider - - B{center} - A center label of the actionslider + Default text parts of the actionslider widget that you can use for are: + - B{indicator} - An indicator label of the actionslider + - B{left} - A left label of the actionslider + - B{right} - A right label of the actionslider + - B{center} - A center label of the actionslider @note: By default all positions are set as enabled. @@ -62,14 +67,16 @@ """Get actionslider selected label. @return: The selected label. - @rtype: char * + @rtype: string + """ return elm_actionslider_selected_label_get(self.obj) property selected_label: """Selected label. - @type: char * + @type: string + """ def __get__(self): return self.selected_label_get() @@ -79,6 +86,7 @@ @param pos: The position of the indicator. @type pos: Elm_Actionslider_Pos + """ elm_actionslider_indicator_pos_set(self.obj, pos) @@ -87,6 +95,7 @@ @return: The position of the indicator. @rtype: Elm_Actionslider_Pos + """ return elm_actionslider_indicator_pos_get(self.obj) @@ -94,6 +103,7 @@ """Indicator position. @type: Elm_Actionslider_Pos + """ def __get__(self): return self.indicator_pos_get() @@ -101,11 +111,13 @@ self.indicator_pos_set(pos) def magnet_pos_set(self, pos): - """Set actionslider magnet position. To make multiple positions magnets C{or} - them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | ELM_ACTIONSLIDER_RIGHT}) + """Set actionslider magnet position. To make multiple positions + magnets C{or} them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | + ELM_ACTIONSLIDER_RIGHT}) @param pos: Bit mask indicating the magnet positions. @type pos: Elm_Actionslider_Pos + """ elm_actionslider_magnet_pos_set(self.obj, pos) @@ -114,13 +126,17 @@ @return: The positions with magnet property. @rtype: Elm_Actionslider_Pos + """ return elm_actionslider_magnet_pos_get(self.obj) property magnet_pos: - """Magnet position. + """The actionslider magnet position. To make multiple positions + magnets C{or} them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | + ELM_ACTIONSLIDER_RIGHT}) @type: Elm_Actionslider_Pos + """ def __get__(self): return self.magnet_pos_get() @@ -128,13 +144,15 @@ self.magnet_pos_set(pos) def enabled_pos_set(self, pos): - """Set actionslider enabled position. To set multiple positions as enabled C{or} - them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | ELM_ACTIONSLIDER_RIGHT}). + """Set actionslider enabled position. To set multiple positions as + enabled C{or} them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | + ELM_ACTIONSLIDER_RIGHT}). @note: All the positions are enabled by default. @param pos: Bit mask indicating the enabled positions. @type pos: Elm_Actionslider_Pos + """ elm_actionslider_enabled_pos_set(self.obj, pos) @@ -143,13 +161,19 @@ @return: The enabled positions. @rtype: Elm_Actionslider_Pos + """ return elm_actionslider_enabled_pos_get(self.obj) property enabled_pos: - """Enabled position. + """The actionslider enabled position. To set multiple positions as + enabled C{or} them together(e.g.: C{ELM_ACTIONSLIDER_LEFT | + ELM_ACTIONSLIDER_RIGHT}). + @note: All the positions are enabled by default. + @type: Elm_Actionslider_Pos + """ def __get__(self): return self.enabled_pos_get() @@ -157,14 +181,16 @@ self.enabled_pos_set(pos) def callback_selected_add(self, func, *args, **kwargs): - """Called when user selects an enabled position. The label is passed as event info.""" + """Called when user selects an enabled position. The label is passed + as event info.""" self._callback_add_full("selected", _actionslider_callback_conv, func, *args, **kwargs) def callback_selected_del(self, func): self._callback_del_full("selected", _actionslider_callback_conv, func) def callback_pos_changed_add(self, func, *args, **kwargs): - """Called when the indicator reaches any of the positions B{left}, B{right} or B{center}. The label is passed as event info.""" + """Called when the indicator reaches any of the positions B{left}, + B{right} or B{center}. The label is passed as event info.""" self._callback_add_full("pos_changed", _actionslider_callback_conv, func, *args, **kwargs) def callback_pos_changed_del(self, func): Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_background.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_background.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_background.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -20,17 +20,16 @@ """Background widget object - Used for setting a solid color, image or - Edje group as a background to a window or any container object. + Used for setting a solid color, image or Edje group as a background to a + window or any container object. - The background widget is used for setting (solid) background - decorations to a window (unless it has transparency enabled) or to - any container object. It works just like an image, but has some - properties useful to a background, like setting it to tiled, - centered, scaled or stretched. + The background widget is used for setting (solid) background decorations + to a window (unless it has transparency enabled) or to any container + object. It works just like an image, but has some properties useful to a + background, like setting it to tiled, centered, scaled or stretched. Default content parts of the bg widget that you can use for are: - - B{overlay} - overlay of the bg + - B{overlay} - overlay of the bg """ @@ -47,16 +46,16 @@ def file_set(self, filename, group = ""): """Set the file (image or edje collection) to give life for the background. - This sets the image file used in the background object. If the - image comes from an Edje group, it will be stretched to completely - fill the background object. If it comes from a traditional image file, it - will by default be centered in this widget's are (thus retaining - its aspect), what could lead to some parts being not visible. You - may change the mode of exhibition for a real image file with - elm_bg_option_set(). + This sets the image file used in the background object. If the image + comes from an Edje group, it will be stretched to completely fill + the background object. If it comes from a traditional image file, it + will by default be centered in this widget's are (thus retaining its + aspect), what could lead to some parts being not visible. You may + change the mode of exhibition for a real image file with + L{option_set()}. - @note: Once the image of B{obj} is set, a previously set one will be - deleted, even if B{file} is C{None}. + @note: Once the image is set, a previously set one will be deleted, + even if B{file} is C{None}. @note: This will only affect the contents of one of the background's swallow spots, namely C{"elm.swallow.background"}. If you want to @@ -64,9 +63,9 @@ that method on this object. @param file: The file path - @type file: char * + @type file: string @param group: Optional key (group in Edje) within the file - @type group: char * + @type group: string @return: C{True} on success, C{False} otherwise @rtype: bool @@ -90,10 +89,26 @@ return (filename, group) property file: - """The file (image or edje) used for the background. + """The file (image or edje collection) giving life for the background. - @type: tuple (char *filename, char *group) + This property contains the image file name (and edje group) used in + the background object. If the image comes from an Edje group, it + will be stretched to completely fill the background object. If it + comes from a traditional image file, it will by default be centered + in this widget's are (thus retaining its aspect), what could lead to + some parts being not visible. You may change the mode of exhibition + for a real image file with L{option_set()}. + @note: Once the image is set, a previously set one will be deleted, + even if B{file} is C{None}. + + @note: This will only affect the contents of one of the background's + swallow spots, namely C{"elm.swallow.background"}. If you want to + achieve the L{Layout}'s file setting behavior, you'll have to call + that method on this object. + + @type: (string file, string group) + """ def __get__(self): return self.file_get() @@ -126,8 +141,13 @@ return elm_bg_option_get(self.obj) property option: - """Mode of display. + """The mode of display for a given background widget's image. + This property reflects how the background widget will display its + image. This will only work if L{file} was previously called with an + image file. The image can be displayed tiled, scaled, centered or + stretched. + @type: Elm_Bg_Option """ @@ -170,10 +190,17 @@ return (r, g, b) property color: - """Set the color for the background. + """The color on a given background widget. - @type: tuple (int r, int g, int b) + This property reflects the color used for the background rectangle, + in RGB format. Each color component's range is from 0 to 255. + @note: You probably only want to use this property if you haven't + previously set L{file}, so that you just want a solid color + background. + + @type: (int r, int g, int b) + """ def __get__(self): return self.color_get() @@ -207,10 +234,24 @@ elm_bg_load_size_set(self.obj, w, h) property load_size: - """Size of the pixmap representation. + """The size of the pixmap representation of the image set on a given + background widget. - @type: tuple (Evas_Coord w, Evas_Coord h) + This property sets a new size for pixmap representation of the + given bg image. It allows for the image to be loaded already in the + specified size, reducing the memory usage and load time (for + example, when loading a big image file with its load size set to a + smaller size) + @note: This is just a hint for the underlying system. The real size + of the pixmap may differ depending on the type of image being + loaded, being bigger than requested. + + @warning: This function just makes sense if an image file was set with + L{file}. + + @type: (Evas_Coord w, Evas_Coord h) + """ def __set__(self, value): self.load_size_set(*value) Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_box.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_box.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_box.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -71,7 +71,7 @@ will be placed within the space given to the box widget itself. The size hints of each object also affect how they are placed and sized - within the box. C{size_hint_min_set()} will give the minimum + within the box. L{size_hint_min_set()} will give the minimum size the object can have, and the box will use it as the basis for all latter calculations. Elementary widgets set their own minimum size as needed, so there's rarely any need to use it manually. @@ -88,7 +88,7 @@ Besides how much space each object is allocated, it's possible to control how the widget will be placed within that space using - C{size_hint_align_set()}. By default, this value will be 0.5 + L{size_hint_align_set()}. By default, this value will be 0.5 for both axis, meaning the object will be centered, but any value from 0.0 (left or top, for the C{x} and C{y} axis, respectively) to 1.0 (right or bottom) can be used. The special value C{EVAS_HINT_FILL}, which @@ -113,8 +113,8 @@ By default, the box will be in vertical mode and non-homogeneous. @param parent: The parent object - @type parent: Evas_Object - @return: The new object or NULL if it cannot be created + @type parent: L{Object} + @return: The new object or None if it cannot be created @rtype: L{Object} """ @@ -150,6 +150,12 @@ property horizontal: """The horizontal orientation. + By default, box object arranges their contents vertically from top to + bottom. By setting this property as C{True}, the box will become + horizontal, arranging contents from left to right. + + @note: This flag is ignored if a custom layout function is set. + @type: bool """ @@ -182,8 +188,13 @@ return bool(elm_box_homogeneous_get(self.obj)) property homogeneous: - """Homogeneous mode. + """Whether the box is using homogeneous mode or not + If enabled, homogeneous layout makes all items the same size, according + to the size of the largest of its children. + + @note: This flag is ignored if a custom layout function is set. + @type: bool """ @@ -349,8 +360,11 @@ return ret property children: - """A list of the child objects. + """Retrieve a list of the objects packed into the box + Returns a C{tuple} with the child L{Object}s. + The order of the list corresponds to the packing order the box uses. + @type: tuple of L{Object}s """ @@ -376,11 +390,11 @@ def padding_get(self): """Get the space (padding) between the box's elements. + @see: L{padding_set()} + @return: The horizontal and vertical space between elements @rtype: tuple of Evas_Coords (int) - @see: L{padding_set()} - """ cdef int horizontal, vertical @@ -388,10 +402,15 @@ return (horizontal, vertical) property padding: - """Space (padding) between the box's elements. + """The space (padding) between the box's elements. - @type: tuple with Evas_Coord (int) + Extra space in pixels that will be added between a box child and its + neighbors after its containing cell has been calculated. This padding + is set for all elements in the box, besides any possible padding that + individual elements may have through their size hints. + @type: tuple of Evas_Coords (int) + """ def __get__(self): return self.padding_get() @@ -407,9 +426,9 @@ the space given for the whole box widget. @param horizontal: The horizontal alignment of elements - @type horizontal: double + @type horizontal: float @param vertical: The vertical alignment of elements - @type vertical: double + @type vertical: float """ elm_box_align_set(self.obj, horizontal, vertical) @@ -418,7 +437,7 @@ """Get the alignment of the whole bounding box of contents. @return: The horizontal and vertical alignment of elements - @rtype: tuple of doubles + @rtype: tuple of floats @see: L{align_set()} @@ -429,10 +448,14 @@ return (horizontal, vertical) property align: - """Alignment of the whole bounding box of contents. + """Set the alignment of the whole bounding box of contents. - @type: tuple of doubles + Sets how the bounding box containing all the elements of the box, after + their sizes and position has been calculated, will be aligned within + the space given for the whole box widget. + @rtype: tuple of floats + """ def __get__(self): return self.align_get() Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_bubble.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_bubble.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_bubble.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -22,33 +22,33 @@ represented in comics. The bubble widget contains 5 important visual elements: - - The frame is a rectangle with rounded edjes and an "arrow". - - The C{icon} is an image to which the frame's arrow points to. - - The C{label} is a text which appears to the right of the icon if the - corner is B{top_left} or B{bottom_left} and is right aligned to the frame - otherwise. - - The C{info} is a text which appears to the right of the label. Info's - font is of a lighter color than label. - - The C{content} is an evas object that is shown inside the frame. + - The frame is a rectangle with rounded edjes and an "arrow". + - The C{icon} is an image to which the frame's arrow points to. + - The C{label} is a text which appears to the right of the icon if the + corner is B{top_left} or B{bottom_left} and is right aligned to + the frame otherwise. + - The C{info} is a text which appears to the right of the label. Info's + font is of a lighter color than label. + - The C{content} is an evas object that is shown inside the frame. The position of the arrow, icon, label and info depends on which corner is selected. The four available corners are: - - B{top_left} - Default - - B{top_right} - - B{bottom_left} - - B{bottom_right} + - B{top_left} - Default + - B{top_right} + - B{bottom_left} + - B{bottom_right} This widget emits the following signals, besides the ones sent from L{Layout}: - - C{clicked} - This is called when a user has clicked the bubble. + - C{clicked} - This is called when a user has clicked the bubble. Default content parts of the bubble that you can use for are: - - B{default} - A content of the bubble - - B{icon} - An icon of the bubble + - B{default} - A content of the bubble + - B{icon} - An icon of the bubble Default text parts of the button widget that you can use for are: - - B{default} - Label of the bubble - - B{info} - info of the bubble + - B{default} - Label of the bubble + - B{info} - info of the bubble """ @@ -69,9 +69,9 @@ def pos_set(self, pos): """Set the corner of the bubble - This function sets the corner of the bubble. The corner will be used to - determine where the arrow in the frame points to and where label, icon and - info are shown. + This function sets the corner of the bubble. The corner will be used + to determine where the arrow in the frame points to and where label, + icon and info are shown. @param pos: The given corner for the bubble. @type pos: Elm_Bubble_Pos @@ -91,8 +91,12 @@ return elm_bubble_pos_get(self.obj) property pos: - """The corner of the bubble. + """The corner of the bubble + This property reflects the corner of the bubble. The corner will be + used to determine where the arrow in the frame points to and where + label, icon and info are shown. + @type: Elm_Bubble_Pos """ Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_button.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_button.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_button.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -23,54 +23,47 @@ This widget emits the following signals, besides the ones sent from L{Layout}: - - "clicked": the user clicked the button (press/release). - - "repeated": the user pressed the button without releasing it. - - "pressed": button was pressed. - - "unpressed": button was released after being pressed. + - "clicked": the user clicked the button (press/release). + - "repeated": the user pressed the button without releasing it. + - "pressed": button was pressed. + - "unpressed": button was released after being pressed. Also, defined in the default theme, the button has the following styles available: - - default: a normal button. - - anchor: Like default, but the button fades away when the mouse is not - over it, leaving only the text or icon. - - hoversel_vertical: Internally used by L{Hoversel} to give a - continuous look across its options. - - hoversel_vertical_entry: Another internal for L{Hoversel}. - - naviframe: Internally used by L{Naviframe} for its back button. - - colorselector: Internally used by L{Colorselector} - for its left and right buttons. + - default: a normal button. + - anchor: Like default, but the button fades away when the mouse is not + over it, leaving only the text or icon. + - hoversel_vertical: Internally used by L{Hoversel} to give a + continuous look across its options. + - hoversel_vertical_entry: Another internal for L{Hoversel}. + - naviframe: Internally used by L{Naviframe} for its back button. + - colorselector: Internally used by L{Colorselector} + for its left and right buttons. Default content parts of the button widget that you can use for are: - - "icon" - An icon of the button + - "icon" - An icon of the button Default text parts of the button widget that you can use for are: - - "default" - Label of the button + - "default" - Label of the button """ def __init__(self, c_evas.Object parent): - """Add a new button to the parent's canvas - - @param parent: The parent object - @type parent: L{Object} - @return: The new object or None if it cannot be created - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_button_add(parent.obj)) def autorepeat_set(self, on): - """Turn on/off the autorepeat event generated when the button is kept pressed + """Turn on/off the autorepeat event generated when the button is + kept pressed - When off, no autorepeat is performed and buttons emit a normal C{clicked} - signal when they are clicked. + When off, no autorepeat is performed and buttons emit a normal + C{clicked} signal when they are clicked. - When on, keeping a button pressed will continuously emit a C{repeated} - signal until the button is released. The time it takes until it starts - emitting the signal is given by - L{autorepeat_initial_timeout_set()}, and the time between each - new emission by L{autorepeat_gap_timeout_set()}. + When on, keeping a button pressed will continuously emit a + C{repeated} signal until the button is released. The time it takes + until it starts emitting the signal is given by + L{autorepeat_initial_timeout_set()}, and the time between each new + emission by L{autorepeat_gap_timeout_set()}. @param on: A bool to turn on/off the event @type on: bool @@ -90,8 +83,18 @@ return bool(elm_button_autorepeat_get(self.obj)) property autorepeat: - """Whether the autorepeat feature is enabled + """Turn on/off the autorepeat event generated when the button is + kept pressed + When off, no autorepeat is performed and buttons emit a normal + C{clicked} signal when they are clicked. + + When on, keeping a button pressed will continuously emit a + C{repeated} signal until the button is released. The time it takes + until it starts emitting the signal is given by + L{autorepeat_initial_timeout_set()}, and the time between each new + emission by L{autorepeat_gap_timeout_set()}. + @type: bool """ @@ -108,31 +111,39 @@ won't be any delay and the event will be fired the moment the button is pressed. - @param t: Timeout in seconds - @type t: double - @see: L{autorepeat_set()} @see: L{autorepeat_gap_timeout_set()} + @param t: Timeout in seconds + @type t: float + """ elm_button_autorepeat_initial_timeout_set(self.obj, t) def autorepeat_initial_timeout_get(self): """Get the initial timeout before the autorepeat event is generated + @see: L{autorepeat_initial_timeout_set()} + @return: Timeout in seconds - @rtype: double + @rtype: float - @see: L{autorepeat_initial_timeout_set()} - """ return elm_button_autorepeat_initial_timeout_get(self.obj) property autorepeat_initial_timeout: """The initial timeout before the autorepeat event is generated - @type: double + Reflects the timeout, in seconds, since the button is pressed until the + first C{repeated} signal is emitted. If C{t} is 0.0 or less, there + won't be any delay and the event will be fired the moment the button is + pressed. + @see: L{autorepeat} + @see: L{autorepeat_gap_timeout} + + @type: float + """ def __get__(self): return self.autorepeat_initial_timeout_get() @@ -145,11 +156,11 @@ After the first C{repeated} event is fired, all subsequent ones will follow after a delay of C{t} seconds for each. + @see: L{autorepeat_initial_timeout_set()} + @param t: Interval in seconds - @type t: double + @type t: float - @see: L{autorepeat_initial_timeout_set()} - """ elm_button_autorepeat_gap_timeout_set(self.obj, t) @@ -157,7 +168,7 @@ """Get the interval between each generated autorepeat event @return: Interval in seconds - @rtype: double + @rtype: float """ return elm_button_autorepeat_gap_timeout_get(self.obj) @@ -165,8 +176,13 @@ property autorepeat_gap_timeout: """The interval between each generated autorepeat event - @type: double + After the first C{repeated} event is fired, all subsequent ones will + follow after a delay of C{t} seconds for each. + @see: L{autorepeat_initial_timeout} + + @type: float + """ def __get__(self): return self.autorepeat_gap_timeout_get() Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_calendar.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_calendar.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_calendar.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -46,29 +46,18 @@ date, year and month. Applications are able to set specific dates to be reported back, when selected, in the smart callbacks of the calendar widget. The API of this widget lets the applications perform other functions, like: - - placing marks on specific dates - - setting the bounds for the calendar (minimum and maximum years) - - setting the day names of the week (e.g. "Thu" or "Thursday") - - setting the year and month format. + - placing marks on specific dates + - setting the bounds for the calendar (minimum and maximum years) + - setting the day names of the week (e.g. "Thu" or "Thursday") + - setting the year and month format. This widget emits the following signals, besides the ones sent from L{Layout}: - - C{changed} - emitted when the date in the calendar is changed. + - C{changed} - emitted when the date in the calendar is changed. """ def __init__(self, c_evas.Object parent): - """Add a new calendar widget to the given parent Elementary (container) - object. - - This function inserts a new calendar widget on the canvas. - - @param parent: The parent object. - @type parent: L{Object} - @return: a new calendar widget handle or C{None}, on errors. - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_calendar_add(parent.obj)) @@ -96,15 +85,13 @@ The first string should be related to Sunday, the second to Monday... - The usage should be like this: - C{ - const char *weekdays[] = - { - "Sunday", "Monday", "Tuesday", "Wednesday", - "Thursday", "Friday", "Saturday" - }; - elm_calendar_weekdays_names_set(calendar, weekdays); - } + The usage should be like this:: + weekdays = + ( + "Sunday", "Monday", "Tuesday", "Wednesday", + "Thursday", "Friday", "Saturday" + ) + calendar.weekdays_names_set(weekdays) @see: L{weekdays_name_get()} @@ -213,18 +200,16 @@ that will be freed by the widget after usage. A pointer to the string and a pointer to the time struct will be provided. - Example: - C{ - static char * - _format_month_year(struct tmselected_time) - { - char buf[32]; - if (!strftime(buf, sizeof(buf), "%B %Y", selected_time)) return NULL; - return strdup(buf); - } + Example:: + static char * + _format_month_year(struct tm selected_time) + { + char buf[32]; + if (!strftime(buf, sizeof(buf), "%B %Y", selected_time)) return NULL; + return strdup(buf); + } - elm_calendar_format_function_set(calendar, _format_month_year); - } + elm_calendar_format_function_set(calendar, _format_month_year); @param format_func: Function to set the month-year string given the selected date @@ -246,22 +231,20 @@ Marks created with this method can be deleted with L{mark_del()}. - Example: - C{ - struct tm selected_time; - time_t current_time; + Example:: + struct tm selected_time; + time_t current_time; - current_time = time(NULL) + 5 84600; - localtime_r(¤t_time, &selected_time); - elm_calendar_mark_add(cal, "holiday", selected_time, - ELM_CALENDAR_ANNUALLY); + current_time = time(NULL) + 5 84600; + localtime_r(¤t_time, &selected_time); + elm_calendar_mark_add(cal, "holiday", selected_time, + ELM_CALENDAR_ANNUALLY); - current_time = time(NULL) + 1 84600; - localtime_r(¤t_time, &selected_time); - elm_calendar_mark_add(cal, "checked", selected_time, ELM_CALENDAR_UNIQUE); + current_time = time(NULL) + 1 84600; + localtime_r(¤t_time, &selected_time); + elm_calendar_mark_add(cal, "checked", selected_time, ELM_CALENDAR_UNIQUE); - elm_calendar_marks_draw(cal); - } + elm_calendar_marks_draw(cal); @see: L{marks_draw()} @see L{mark_del()} @@ -344,7 +327,7 @@ @see: L{interval_get()} @param interval: The (first) interval value in seconds - @type interval: double + @type interval: float """ elm_calendar_interval_set(self.obj, interval) @@ -356,7 +339,7 @@ @see: L{interval_set()} for more details @return: The (first) interval value, in seconds, set on it - @rtype: double + @rtype: float """ return elm_calendar_interval_get(self.obj) Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_check.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_check.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_check.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -20,36 +20,27 @@ """The check widget allows for toggling a value between true and false. - Check objects are a lot like radio objects in layout and - functionality, except they do not work as a group, but - independently, and only toggle the value of a boolean between false - and true. L{state_set()} sets the boolean state and - L{state_get()} returns the current state. + Check objects are a lot like radio objects in layout and functionality, + except they do not work as a group, but independently, and only toggle + the value of a boolean between false and true. L{state_set()} sets the + boolean state and L{state_get()} returns the current state. This widget emits the following signals, besides the ones sent from L{Layout}: - - C{changed} - This is called whenever the user changes the state of - the check objects. + - C{changed} - This is called whenever the user changes the state of + the check objects. Default content parts of the check widget that you can use for are: - - "icon" - An icon of the check + - "icon" - An icon of the check Default text parts of the check widget that you can use for are: - - "default" - A label of the check - - "on" - On state label of the check - - "off" - Off state label of the check + - "default" - A label of the check + - "on" - On state label of the check + - "off" - Off state label of the check """ def __init__(self, c_evas.Object parent): - """Add a new Check object - - @param parent: The parent object - @type parent: L{Object} - @return: The new object or None if it cannot be created - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_check_add(parent.obj)) @@ -83,8 +74,11 @@ return True property state: - """The state of the check object + """The of/off state of the check object + This property reflects the state of the check. Setting it B{doesn't} + cause the "changed" signal to be emitted. + @type: bool """ @@ -95,7 +89,8 @@ self.state_set(value) def callback_changed_add(self, func, *args, **kwargs): - """This is called whenever the user changes the state of the check objects.""" + """This is called whenever the user changes the state of the check + objects.""" self._callback_add("changed", func, *args, **kwargs) def callback_changed_del(self, func): Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_clock.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_clock.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_clock.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -18,51 +18,38 @@ cdef public class Clock(Object) [object PyElementaryClock, type PyElementaryClock_Type]: - """This is a B{digital} clock widget. + """This is a digital clock widget. In its default theme, it has a vintage "flipping numbers clock" appearance, which will animate sheets of individual algarisms individually as time goes by. - A newly created clock will fetch system's time (already - considering local time adjustments) to start with, and will tick - accordingly. It may or may not show seconds. + A newly created clock will fetch system's time (already considering + local time adjustments) to start with, and will tick accordingly. It may + or may not show seconds. - Clocks have an B{edition} mode. When in it, the sheets will - display extra arrow indications on the top and bottom and the - user may click on them to raise or lower the time values. After - it's told to exit edition mode, it will keep ticking with that - new time set (it keeps the difference from local time). + Clocks have an B{edition} mode. When in it, the sheets will display + extra arrow indications on the top and bottom and the user may click on + them to raise or lower the time values. After it's told to exit edition + mode, it will keep ticking with that new time set (it keeps the + difference from local time). - Also, when under edition mode, user clicks on the cited arrows - which are B{held} for some time will make the clock to flip the - sheet, thus editing the time, continuously and automatically for - the user. The interval between sheet flips will keep growing in - time, so that it helps the user to reach a time which is distant - from the one set. + Also, when under edition mode, user clicks on the cited arrows which are + B{held} for some time will make the clock to flip the sheet, thus + editing the time, continuously and automatically for the user. The + interval between sheet flips will keep growing in time, so that it helps + the user to reach a time which is distant from the one set. - The time display is, by default, in military mode (24h), but an - am/pm indicator may be optionally shown, too, when it will - switch to 12h. + The time display is, by default, in military mode (24h), but an am/pm + indicator may be optionally shown, too, when it will switch to 12h. This widget emits the following signals, besides the ones sent from L{Layout}: - - C{changed} - the clock's user changed the time + - C{changed} - the clock's user changed the time """ def __init__(self, c_evas.Object parent): - """Add a new clock widget to the given parent Elementary - (container) object - - This function inserts a new clock widget on the canvas. - - @param parent: The parent object - @type parent: L{Object} - @return: a new clock widget handle or C{None}, on errors - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_clock_add(parent.obj)) @@ -73,9 +60,9 @@ widget. Values B{must} be set within the following ranges: - - 0 - 23, for hours - - 0 - 59, for minutes - - 0 - 59, for seconds, + - 0 - 23, for hours + - 0 - 59, for minutes + - 0 - 59, for seconds, even if the clock is not in "military" mode. @warning: The behavior for values set out of those ranges is @@ -106,10 +93,21 @@ return (hrs, min, sec) property time: - """Clock widget's time values. + """The clock widget's time - @type: tuple of ints + This property reflects the time that is showed by the clock widget. + Values B{must} be set within the following ranges: + - 0 - 23, for hours + - 0 - 59, for minutes + - 0 - 59, for seconds, + even if the clock is not in "military" mode. + + @warning: The behavior for values set out of those ranges is + B{undefined}. + + @type: (int h, int m, int s) + """ def __get__(self): return self.time_get() @@ -121,14 +119,13 @@ """Set whether a given clock widget is under B{edition mode} or under (default) displaying-only mode. - This function makes a clock's time to be editable or not B{by - user interaction}. When in edition mode, clocks B{stop} - ticking, until one brings them back to canonical mode. The - L{edit_mode_set()} function will influence which digits - of the clock will be editable. + This function makes a clock's time to be editable or not B{by user + interaction}. When in edition mode, clocks B{stop} ticking, until + one brings them back to canonical mode. The L{edit_mode_set()} + function will influence which digits of the clock will be editable. @note: am/pm sheets, if being shown, will B{always} be editable - under edition mode. + under edition mode. @see: L{edit_get()} @@ -140,11 +137,11 @@ elm_clock_edit_set(self.obj, edit) def edit_get(self, edit): - """Retrieve whether a given clock widget is under editing mode - or under (default) displaying-only mode. + """Retrieve whether a given clock widget is under editing mode or + under (default) displaying-only mode. - This function retrieves whether the clock's time can be edited - or not by user interaction. + This function retrieves whether the clock's time can be edited or + not by user interaction. @see: L{edit_set()} for more details @@ -155,11 +152,17 @@ return elm_clock_edit_get(self.obj) property edit: - """Whether a given clock widget is under editing mode or under (default) - displaying-only mode. + """Whether a given clock widget is under B{edition mode} or under + (default) displaying-only mode. - C{True}, if it's in edition mode, C{False} otherwise + This property reflects whether the clock editable or not B{by user + interaction}. When in edition mode, clocks B{stop} ticking, until + one brings them back to canonical mode. The L{edit_mode} + property will influence which digits of the clock will be editable. + @note: am/pm sheets, if being shown, will B{always} be editable + under edition mode. + @type: bool """ @@ -194,7 +197,7 @@ return elm_clock_edit_mode_get(self.obj) property edit_mode: - """What digits of the given clock widget should be editable when in + """Which digits of the given clock widget should be editable when in edition mode. @type: Elm_Clock_Edit_Mode @@ -236,8 +239,16 @@ return elm_clock_show_am_pm_get(self.obj) property show_am_pm: - """Whether the given clock widget shows hours in military or am/pm mode. + """Whether the given clock widget must show hours in military or + am/pm mode + This property reflects if the clock must show hours in military or + am/pm mode. In some countries like Brazil the military mode + (00-24h-format) is used, in opposition to the USA, where the + am/pm mode is more commonly used. + + C{True}, if in am/pm mode, C{False} if in military + @type: bool """ @@ -274,8 +285,10 @@ return elm_clock_show_seconds_get(self.obj) property show_seconds: - """Whether the given clock widget is showing time with seconds or not. + """Whether the given clock widget must show time with seconds or not + By default, they are B{not} shown. + @type: bool """ @@ -307,7 +320,7 @@ @see: L{first_interval_get()} @param interval: The first interval value in seconds - @type interval: double + @type interval: float """ elm_clock_first_interval_set(self.obj, interval) @@ -319,7 +332,7 @@ @see: L{first_interval_set()} for more details @return: The first interval value, in seconds, set on it - @rtype: double + @rtype: float """ return elm_clock_first_interval_get(self.obj) @@ -328,8 +341,23 @@ """The first interval on time updates for a user mouse button hold on clock widgets' time edition. - @type: double + This interval value is B{decreased} while the user holds the + mouse pointer either incrementing or decrementing a given the + clock digit's value. + This helps the user to get to a given time distant from the + current one easier/faster, as it will start to flip quicker and + quicker on mouse button holds. + + The calculation for the next flip interval value, starting from + the one set with this call, is the previous interval divided by + 1.05, so it decreases a little bit. + + The default starting interval value for automatic flips is + B{0.85} seconds. + + @type: float + """ def __get__(self): return self.first_interval_get() Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_colorselector.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_colorselector.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_colorselector.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -47,31 +47,25 @@ """A Colorselector is a color selection widget. - It allows application to set a series of colors. It also allows to load/save - colors from/to config with a unique identifier, by default, the colors are - loaded/saved from/to config using "default" identifier. The colors - can be picked by user from the color set by clicking on individual - color item on the palette or by selecting it from selector. + It allows application to set a series of colors. It also allows to + load/save colors from/to config with a unique identifier, by default, + the colors are loaded/saved from/to config using "default" identifier. + The colors can be picked by user from the color set by clicking on + individual color item on the palette or by selecting it from selector. This widget emits the following signals, besides the ones sent from L{Layout}: - - @c "changed" - When the color value changes on selector - - @c "color,item,selected" - When user clicks on color item. - The event_info parameter of the callback will be the selected color item. - - @c "color,item,longpressed" - When user long presses on color item. - The event_info parameter of the callback will be the selected color item. + - C{"changed"} - When the color value changes on selector + - C{"color,item,selected"} - When user clicks on color item. + The event_info parameter of the callback will be the selected + color item. + - C{"color,item,longpressed"} - When user long presses on color item. + The event_info parameter of the callback will be the selected + color item. """ def __init__(self, c_evas.Object parent): - """Add a new colorselector to the parent - - @param parent: The parent object - @type parent: L{Object} - @return: The new object or None if it cannot be created - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_colorselector_add(parent.obj)) @@ -157,7 +151,7 @@ @param a: a-value of color @type a: int @return: A new color palette Item. - @rtype: L{ColorSelectorPaletteItem} + @rtype: L{ColorselectorPaletteItem} """ return ColorselectorPaletteItem(self, r, g, b, a) @@ -169,9 +163,9 @@ def palette_name_set(self, palette_name): """Set current palette's name - When colorpalette name is set, colors will be loaded from and saved to config - using the set name. If no name is set then colors will be loaded from or - saved to "default" config. + When colorpalette name is set, colors will be loaded from and saved + to config using the set name. If no name is set then colors will be + loaded from or saved to "default" config. @param palette_name: Name of palette @type palette_name: string @@ -192,8 +186,12 @@ return elm_colorselector_palette_name_get(self.obj) property palette_name: - """Current palette's name. + """The current palette's name + When colorpalette name is set, colors will be loaded from and saved + to config using the set name. If no name is set then colors will be + loaded from or saved to "default" config. + @type: string """ @@ -210,20 +208,16 @@ self._callback_del("selected", func) def callback_color_item_selected_add(self, func, *args, **kwargs): - """When user clicks on color item. - The event_info parameter of the callback will be the selected color item. - - """ + """When user clicks on color item. The event_info parameter of the + callback will be the selected color item.""" self._callback_add_full("color,item,selected", _colorselector_item_conv, func, *args, **kwargs) def callback_color_item_selected_del(self, func): self._callback_del_full("color,item,selected", _colorselector_item_conv, func) def callback_color_item_longpressed_add(self, func, *args, **kwargs): - """When user long presses on color item. - The event_info parameter of the callback will be the selected color item. - - """ + """When user long presses on color item. The event_info parameter of + the callback will be the selected color item.""" self._callback_add_full("color,item,longpressed", _colorselector_item_conv, func, *args, **kwargs) def callback_color_item_longpressed_del(self, func): Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_ctxpopup.pxi =================================================================== --- trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_ctxpopup.pxi 2012-06-06 21:31:32 UTC (rev 71767) +++ trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_ctxpopup.pxi 2012-06-06 23:29:57 UTC (rev 71768) @@ -47,38 +47,30 @@ """Context popup widget. - A ctxpopup is a widget that, when shown, pops up a list of items. - It automatically chooses an area inside its parent object's view to - optimally fit into it. In the default theme, it will also point an - arrow to it's top left position at the time one shows it. Ctxpopup - items have a label and/or an icon. It is intended for a small - number of items (hence the use of list, not genlist). + A ctxpopup is a widget that, when shown, pops up a list of items. It + automatically chooses an area inside its parent object's view to + optimally fit into it. In the default theme, it will also point an arrow + to it's top left position at the time one shows it. Ctxpopup items have + a label and/or an icon. It is intended for a small number of items + (hence the use of list, not genlist). - @note: Ctxpopup is a specialization of L{Hover}. - Signals that you can add callbacks for are: "dismissed" - the ctxpopup was dismissed Default content parts of the ctxpopup widget that you can use for are: - - "default" - A content of the ctxpopup + - "default" - A content of the ctxpopup Default content parts of the ctxpopup items that you can use for are: - - "icon" - An icon in the title area + - "icon" - An icon in the title area Default text parts of the ctxpopup items that you can use for are: - - "default" - Title label in the title area + - "default" - Title label in the title area + @note: Ctxpopup is a specialization of L{Hover}. + """ def __init__(self, c_evas.Object parent): - """Add a new Ctxpopup object to the parent. - - @param parent: Parent object - @type parent: L{Object} - @return: New object or C{None}, if it cannot be created - @rtype: L{Object} - - """ Object.__init__(self, parent.evas) self._set_obj(elm_ctxpopup_add(parent.obj)) @@ -145,8 +137,9 @@ def item_append(self, label, c_evas.Object icon, func, *args, **kwargs): """Add a new item to a ctxpopup object. - @warning: Ctxpopup can't hold both an item list and a content at the same - time. When an item is added, any previous content will be removed. + @warning: Ctxpopup can't hold both an item list and a content at the + same time. When an item is added, any previous content will be + removed. @see: L{Object.content_set()} @@ -166,8 +159,8 @@ """Set the direction priority order of a ctxpopup. This functions gives a chance to user to set the priority of ctxpopup - showing direction. This doesn't guarantee the ctxpopup will appear in the - requested direction. + showing direction. This doesn't guarantee the ctxpopup will appear + in the requested direction. @param first: 1st priority of direction @type first: Elm_Ctxpopup_Direction @@ -197,7 +190,8 @@ def direction_get(self): """Get the current direction of a ctxpopup. - @warning: Only once the ctxpopup is shown can the direction be determined + @warning: Only once the ctxpopup is shown can the direction be + determined @return: current direction of a ctxpopup @rtype: Elm_Ctxpopup_Direction @@ -208,9 +202,9 @@ def dismiss(self): """Dismiss a ctxpopup object - Use this function to simulate clicking outside the ctxpopup to dismiss it. - In this way, the ctxpopup will be hidden and the "clicked" signal will be - emitted. + Use this function to simulate clicking outside the ctxpopup to + dismiss it. In this way, the ctxpopup will be hidden and the + "clicked" signal will be emitted. """ elm_ctxpopup_dismiss(self.obj) Modified: trunk/BINDINGS/python/python-elementary/elementary/elementary.c_elementary_entry.pxi =====... [truncated message content] |