add doc, thanks to Mike Blumenkrantz (zmike)
SVN revision: 47801
This commit is contained in:
parent
0e56acdbcb
commit
97dfb904e9
|
@ -17,7 +17,8 @@
|
|||
@author Christopher Michael <devilhorns@devilhorns.us>
|
||||
@author Marco Trevisan (Treviño) <mail@3v1n0.net>
|
||||
@author Michael Bouchaud <michael.bouchaud@gmail.com>
|
||||
@date 2008-2009
|
||||
@author Mike Blumenkrantz (zmike) <mike@zentific.com>
|
||||
@date 2008-2010
|
||||
|
||||
@section intro What is Elementary?
|
||||
|
||||
|
|
|
@ -1,12 +1,25 @@
|
|||
/*
|
||||
/**
|
||||
* @defgroup Fileselector Fileselector
|
||||
*
|
||||
* A fileselector is a widget that allows a user to navigate through a tree
|
||||
* of files. It contains buttons for Home(~) and Up(..) as well as cancel/ok
|
||||
* buttons to confirm/cancel a selection. This widget is currently very much
|
||||
* in progress.
|
||||
*
|
||||
* TODO
|
||||
* userdefined icon/label cb
|
||||
* show/hide/add buttons ???
|
||||
* need a background ???
|
||||
* show/Hide hidden files
|
||||
* double click to choose a file
|
||||
* multiselection
|
||||
* write docs
|
||||
* userdefined icon/label cb
|
||||
* show/hide/add buttons ???
|
||||
* need a background ???
|
||||
* show/Hide hidden files
|
||||
* double click to choose a file
|
||||
* multiselection
|
||||
* make variable/function names that are sensible
|
||||
*
|
||||
* Signals that you can add callbacks for are:
|
||||
*
|
||||
* "selected" - the user clicks on a file
|
||||
* "directory,open" - the list is populated with a new content. event_info is a directory.
|
||||
* "done" - the user clicks on the ok or cancel button
|
||||
*/
|
||||
|
||||
#include <Elementary.h>
|
||||
|
@ -323,6 +336,14 @@ _populate(Evas_Object *obj, const char *path, Elm_Genlist_Item *parent)
|
|||
}
|
||||
|
||||
/*** API ***/
|
||||
/**
|
||||
* Add a new Fileselector object
|
||||
*
|
||||
* @param parent The parent object
|
||||
* @return The new object or NULL if it cannot be created
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI Evas_Object *
|
||||
elm_fileselector_add(Evas_Object *parent)
|
||||
{
|
||||
|
@ -436,6 +457,16 @@ elm_fileselector_add(Evas_Object *parent)
|
|||
return obj;
|
||||
}
|
||||
|
||||
/**
|
||||
* This enables/disables the file name entry box where the user can
|
||||
* type in the name of a file to be selected.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @param is_save If true, creates the entry object in the fileselector.
|
||||
* If false, deletes the entry object in the fileselector.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI void
|
||||
elm_fileselector_is_save_set(Evas_Object *obj, Eina_Bool is_save)
|
||||
{
|
||||
|
@ -461,6 +492,16 @@ elm_fileselector_is_save_set(Evas_Object *obj, Eina_Bool is_save)
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* This gets the state of the file name entry box where the user can
|
||||
* type in the name of a file to be selected.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return If true, the entry object exists in the fileselector.
|
||||
* If false, it does not exist.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_fileselector_is_save_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -470,6 +511,16 @@ elm_fileselector_is_save_get(const Evas_Object *obj)
|
|||
return wd->entry2 ? EINA_TRUE : EINA_FALSE;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This enables/disables folder-only view in the fileselector.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @param only If true, the fileselector will only display directories.
|
||||
* If false, files are displayed also.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI void
|
||||
elm_fileselector_folder_only_set(Evas_Object *obj, Eina_Bool only)
|
||||
{
|
||||
|
@ -480,6 +531,16 @@ elm_fileselector_folder_only_set(Evas_Object *obj, Eina_Bool only)
|
|||
wd->only_folder = only;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This gets the state of file display in the fileselector.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return If true, files are not being shown in the fileselector.
|
||||
* If false, files are being shown.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_fileselector_folder_only_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -489,6 +550,17 @@ elm_fileselector_folder_only_get(const Evas_Object *obj)
|
|||
return wd->only_folder;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This enables/disables the file name entry box where the user can
|
||||
* type in the name of a file to be selected.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @param only If true, a box containing ok and cancel buttons is created.
|
||||
* If false, the box and the buttons are destroyed.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI void
|
||||
elm_fileselector_buttons_ok_cancel_set(Evas_Object *obj, Eina_Bool only)
|
||||
{
|
||||
|
@ -534,6 +606,16 @@ elm_fileselector_buttons_ok_cancel_set(Evas_Object *obj, Eina_Bool only)
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This gets the state of the box containing ok and cancel buttons.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return If true, the box exists.
|
||||
* If false, the box does not exist.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_fileselector_buttons_ok_cancel_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -543,6 +625,17 @@ elm_fileselector_buttons_ok_cancel_get(const Evas_Object *obj)
|
|||
return wd->buttons.bx ? EINA_TRUE : EINA_FALSE;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This enables tree view in the fileselector. Arrows are created on the
|
||||
* sides of directories, allowing them to expand in place.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @param expand If true, tree view is enabled.
|
||||
* If false, tree view is disabled.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI void
|
||||
elm_fileselector_expandable_set(Evas_Object *obj, Eina_Bool expand)
|
||||
{
|
||||
|
@ -552,6 +645,15 @@ elm_fileselector_expandable_set(Evas_Object *obj, Eina_Bool expand)
|
|||
wd->expand = expand;
|
||||
}
|
||||
|
||||
/**
|
||||
* This gets the state of tree view in the fileselector.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return If true, tree view is enabled and folders will be expandable.
|
||||
* If false, tree view is disabled.
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_fileselector_expandable_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -561,12 +663,28 @@ elm_fileselector_expandable_get(const Evas_Object *obj)
|
|||
return wd->expand;
|
||||
}
|
||||
|
||||
/**
|
||||
* This sets the path that the fileselector will display.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @param path The path of the fileselector
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI void
|
||||
elm_fileselector_path_set(Evas_Object *obj, const char *path)
|
||||
{
|
||||
_populate(obj, path, NULL);
|
||||
}
|
||||
|
||||
/**
|
||||
* This gets the path that the fileselector displays.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return The path that the fileselector is displaying
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI const char *
|
||||
elm_fileselector_path_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -576,6 +694,14 @@ elm_fileselector_path_get(const Evas_Object *obj)
|
|||
return wd->path;
|
||||
}
|
||||
|
||||
/**
|
||||
* This gets the currently selected object in the fileselector.
|
||||
*
|
||||
* @param obj The fileselector object
|
||||
* @return The absolute path of the selected object in the fileselector
|
||||
*
|
||||
* @ingroup Fileselector
|
||||
*/
|
||||
EAPI const char *
|
||||
elm_fileselector_selected_get(const Evas_Object *obj)
|
||||
{
|
||||
|
|
|
@ -267,7 +267,8 @@ elm_hoversel_add(Evas_Object *parent)
|
|||
/**
|
||||
* Set the Hover parent
|
||||
*
|
||||
* Sets the hover parent object. See Hover objects for more information.
|
||||
* Sets the hover parent object. Should probably be the window that the hoversel
|
||||
* is in. See Hover objects for more information.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
* @param parent The parent to use
|
||||
|
@ -309,24 +310,6 @@ elm_hoversel_label_set(Evas_Object *obj, const char *label)
|
|||
elm_button_label_set(wd->btn, label);
|
||||
}
|
||||
|
||||
EAPI void
|
||||
elm_hoversel_horizontal_set(Evas_Object *obj, Eina_Bool horizontal)
|
||||
{
|
||||
ELM_CHECK_WIDTYPE(obj, widtype);
|
||||
Widget_Data *wd = elm_widget_data_get(obj);
|
||||
if (!wd) return;
|
||||
wd->horizontal = !!horizontal;
|
||||
}
|
||||
|
||||
EAPI Eina_Bool
|
||||
elm_hoversel_horizontal_get(const Evas_Object *obj)
|
||||
{
|
||||
ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE;
|
||||
Widget_Data *wd = elm_widget_data_get(obj);
|
||||
if (!wd) return EINA_FALSE;
|
||||
return wd->horizontal;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the hoversel button label
|
||||
*
|
||||
|
@ -344,6 +327,42 @@ elm_hoversel_label_get(const Evas_Object *obj)
|
|||
return elm_button_label_get(wd->btn);
|
||||
}
|
||||
|
||||
/**
|
||||
* This sets the hoversel to expand horizontally. The initial button
|
||||
* will display horizontally regardless of this setting.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
* @param horizontal If true, the hover will expand horizontally to the right.
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
*/
|
||||
EAPI void
|
||||
elm_hoversel_horizontal_set(Evas_Object *obj, Eina_Bool horizontal)
|
||||
{
|
||||
ELM_CHECK_WIDTYPE(obj, widtype);
|
||||
Widget_Data *wd = elm_widget_data_get(obj);
|
||||
if (!wd) return;
|
||||
wd->horizontal = !!horizontal;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This returns whether the hoversel is set to expand horizontally.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
* @return If true, the hover will expand horizontally to the right.
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_hoversel_horizontal_get(const Evas_Object *obj)
|
||||
{
|
||||
ELM_CHECK_WIDTYPE(obj, widtype) EINA_FALSE;
|
||||
Widget_Data *wd = elm_widget_data_get(obj);
|
||||
if (!wd) return EINA_FALSE;
|
||||
return wd->horizontal;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the icon of the hoversel button
|
||||
*
|
||||
|
@ -385,9 +404,8 @@ elm_hoversel_icon_get(const Evas_Object *obj)
|
|||
}
|
||||
|
||||
/**
|
||||
* Trigger the hoversel popup from code
|
||||
*
|
||||
* This makes the hoversel popup activate with the items added being listed.
|
||||
* This triggers the hoversel popup from code, the same as though the
|
||||
* user clicked the button.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
*
|
||||
|
@ -404,9 +422,7 @@ elm_hoversel_hover_begin(Evas_Object *obj)
|
|||
}
|
||||
|
||||
/**
|
||||
* This ends the hoversel popup.
|
||||
*
|
||||
* This will close the hoversel popup, making it disappear, if it was active.
|
||||
* This ends the hoversel popup as though the user clicked outside the hover.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
*
|
||||
|
@ -427,9 +443,9 @@ elm_hoversel_hover_end(Evas_Object *obj)
|
|||
/**
|
||||
* Returns whether the hoversel is expanded.
|
||||
*
|
||||
* This will return EINA_TRUE if the hoversel is expanded or
|
||||
* EINA_FALSE if it is not expanded.
|
||||
* @param obj The hoversel object
|
||||
* @return This will return EINA_TRUE if the hoversel
|
||||
* is expanded or EINA_FALSE if it is not expanded.
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
*/
|
||||
|
@ -443,10 +459,9 @@ elm_hoversel_expanded_get(Evas_Object *obj)
|
|||
}
|
||||
|
||||
/**
|
||||
* Remove all the items from the given hoversel object.
|
||||
*
|
||||
* This will remove all the children items from the hoversel. (should not be
|
||||
* called while the hoversel is active).
|
||||
* called while the hoversel is active; use elm_hoversel_expanded_get()
|
||||
* to check first).
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
*
|
||||
|
@ -464,7 +479,7 @@ elm_hoversel_clear(Evas_Object *obj)
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the list of items.
|
||||
* Get the list of items within the given hoversel.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
* @return Returns a list of Elm_Hoversel_Item*
|
||||
|
@ -488,12 +503,12 @@ elm_hoversel_items_get(const Evas_Object *obj)
|
|||
* right after the this function, and set icon_file to NULL here.
|
||||
*
|
||||
* @param obj The hoversel object
|
||||
* @param label The text abel to use for the item (NULL if not desired)
|
||||
* @param icon_file A image file path on disk to use for the icon or standard
|
||||
* icon name(NULL if not desired)
|
||||
* @param label The text label to use for the item (NULL if not desired)
|
||||
* @param icon_file An image file path on disk to use for the icon or standard
|
||||
* icon name (NULL if not desired)
|
||||
* @param icon_type The icon type if relevant
|
||||
* @param func Convenience function to call when this item is selected
|
||||
* @param data Data to pass to the conveience function
|
||||
* @param data Data to pass to item-related functions
|
||||
* @return A handle to the item added.
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
|
@ -520,7 +535,8 @@ elm_hoversel_item_add(Evas_Object *obj, const char *label, const char *icon_file
|
|||
* Delete an item from the hoversel
|
||||
*
|
||||
* This deletes the item from the hoversel (should not be called while the
|
||||
* hoversel is active).
|
||||
* hoversel is active; use elm_hoversel_expanded_get()
|
||||
* to check first).
|
||||
*
|
||||
* @param it The item to delete
|
||||
*
|
||||
|
@ -542,7 +558,12 @@ elm_hoversel_item_del(Elm_Hoversel_Item *it)
|
|||
}
|
||||
|
||||
/**
|
||||
* Set the function called when an hoversel item is freed.
|
||||
* Set the function called when an item within the hoversel
|
||||
* is freed. That function will receive these parameters:
|
||||
*
|
||||
* void *item_data
|
||||
* Evas_Object *the_item_object
|
||||
* Elm_Hoversel_Item *the_object_struct
|
||||
*
|
||||
* @param it The item to set the callback on
|
||||
* @param func The function called
|
||||
|
@ -557,10 +578,8 @@ elm_hoversel_item_del_cb_set(Elm_Hoversel_Item *it, Evas_Smart_Cb func)
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the data pointer passed to the item add function
|
||||
*
|
||||
* This returns the data pointer supplied with elm_hoversel_item_add() that
|
||||
* will be passed to the select function callback.
|
||||
* will be passed to associated function callbacks.
|
||||
*
|
||||
* @param it The item to get the data from
|
||||
* @return The data pointer set with elm_hoversel_item_add()
|
||||
|
@ -575,12 +594,10 @@ elm_hoversel_item_data_get(Elm_Hoversel_Item *it)
|
|||
}
|
||||
|
||||
/**
|
||||
* Get the text label of an hoversel item
|
||||
*
|
||||
* This returns the text of the label of the given hoversel item
|
||||
* This returns the label text of the given hoversel item.
|
||||
*
|
||||
* @param it The item to get the label
|
||||
* @return The text label of the hoversel item
|
||||
* @return The label text of the hoversel item
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
*/
|
||||
|
@ -592,10 +609,8 @@ elm_hoversel_item_label_get(Elm_Hoversel_Item *it)
|
|||
}
|
||||
|
||||
/**
|
||||
* Set the icon of the hoversel item
|
||||
*
|
||||
* This set the icon for the given hoversel item. The icon can be loaded from
|
||||
* the standard set, from an image file or from an edje file.
|
||||
* This sets the icon for the given hoversel item. The icon can be loaded from
|
||||
* the standard set, from an image file, or from an edje file.
|
||||
*
|
||||
* @param it The item to set the icon
|
||||
* @param icon_file An image file path on disk to use for the icon or standard
|
||||
|
@ -620,10 +635,10 @@ elm_hoversel_item_icon_set(Elm_Hoversel_Item *it, const char *icon_file, const c
|
|||
*
|
||||
* @param it The item to get the icon from
|
||||
* @param icon_file The image file path on disk used for the icon or standard
|
||||
* icon name. return
|
||||
* icon name
|
||||
* @param icon_group The edje group used if @p icon_file is an edje file. NULL
|
||||
* if the icon is not an edje file. return
|
||||
* @param icon_type The icon type. return
|
||||
* if the icon is not an edje file
|
||||
* @param icon_type The icon type
|
||||
*
|
||||
* @ingroup Hoversel
|
||||
*/
|
||||
|
|
|
@ -11,9 +11,9 @@
|
|||
* NONE
|
||||
*
|
||||
* A notepad object contains a scroller and an entry. It is a convenience
|
||||
* widget that loads a text file indicated, puts it int he scrollable entry
|
||||
* widget that loads a text file indicated, puts it in the scrollable entry
|
||||
* and allows the user to edit it. Changes are written back to the original
|
||||
* file after a short delay. The file to load and save to is specificed by
|
||||
* file after a short delay. The file to load and save to is specified by
|
||||
* elm_notepad_file_set().
|
||||
*/
|
||||
typedef struct _Widget_Data Widget_Data;
|
||||
|
@ -305,14 +305,13 @@ elm_notepad_add(Evas_Object *parent)
|
|||
}
|
||||
|
||||
/**
|
||||
* Set the file to load text from and save text back to
|
||||
* This sets the file (and implicitly loads it) for the text to display and
|
||||
* then edit. All changes are written back to the file after a short delay.
|
||||
*
|
||||
* @param obj The notepad object
|
||||
* @param file The path to the file to load and save
|
||||
* @param format The file format
|
||||
*
|
||||
* This sets the file (and implicitly loads it) for the text to display and
|
||||
* then edit. All changes are written back to the file after a short delay.
|
||||
*
|
||||
* @ingroup Notepad
|
||||
*/
|
||||
|
@ -334,8 +333,6 @@ elm_notepad_file_set(Evas_Object *obj, const char *file, Elm_Text_Format format)
|
|||
}
|
||||
|
||||
/**
|
||||
* Set bounce mode
|
||||
*
|
||||
* This will enable or disable the scroller bounce mode for the notepad. See
|
||||
* elm_scroller_bounce_set() for details
|
||||
*
|
||||
|
|
|
@ -1,6 +1,35 @@
|
|||
#include <Elementary.h>
|
||||
#include "elm_priv.h"
|
||||
|
||||
/**
|
||||
* @defgroup Scrolled_Entry Scrolled_Entry
|
||||
*
|
||||
* A scrolled entry is a convenience widget which shows
|
||||
* a box that the user can enter text into. Unlike an
|
||||
* @ref Entry widget, scrolled entries scroll with user
|
||||
* input so that the window will not expand if the length
|
||||
* of text inside the entry exceeds the initial size of the
|
||||
* widget.
|
||||
*
|
||||
* Signals that you can add callbacks for are:
|
||||
* "changed" - The text within the entry was changed
|
||||
* "activated" - The entry has received focus and the cursor
|
||||
* "press" - The entry has been clicked
|
||||
* "longpressed" - The entry has been clicked for a couple seconds
|
||||
* "clicked" - The entry has been clicked
|
||||
* "clicked,double" - The entry has been double clicked
|
||||
* "focused" - The entry has received focus
|
||||
* "unfocused" - The entry has lost focus
|
||||
* "selection,paste" - A paste action has occurred
|
||||
* "selection,copy" - A copy action has occurred
|
||||
* "selection,cut" - A cut action has occurred
|
||||
* "selection,start" - A selection has begun
|
||||
* "selection,changed" - The selection has changed
|
||||
* "selection,cleared" - The selection has been cleared
|
||||
* "cursor,changed" - The cursor has changed
|
||||
* "anchor,clicked" - The anchor has been clicked
|
||||
*/
|
||||
|
||||
typedef struct _Widget_Data Widget_Data;
|
||||
|
||||
struct _Widget_Data
|
||||
|
@ -194,6 +223,15 @@ _entry_unfocused(void *data, Evas_Object *obj __UNUSED__, void *event_info __UNU
|
|||
evas_object_smart_callback_call(data, SIG_UNFOCUSED, NULL);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This adds a scrolled entry to @p parent object.
|
||||
*
|
||||
* @param parent The parent object
|
||||
* @return The new object or NULL if it cannot be created
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Evas_Object *
|
||||
elm_scrolled_entry_add(Evas_Object *parent)
|
||||
{
|
||||
|
@ -249,6 +287,16 @@ elm_scrolled_entry_add(Evas_Object *parent)
|
|||
return obj;
|
||||
}
|
||||
|
||||
/**
|
||||
* This sets the scrolled entry object not to line wrap. All input will
|
||||
* be on a single line, and the entry box will scroll with user input.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param single_line If true, the text in the scrolled entry
|
||||
* will be on a single line.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_single_line_set(Evas_Object *obj, Eina_Bool single_line)
|
||||
{
|
||||
|
@ -271,6 +319,16 @@ elm_scrolled_entry_single_line_set(Evas_Object *obj, Eina_Bool single_line)
|
|||
_sizing_eval(obj);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns true if the scrolled entry has been set to single line mode.
|
||||
* See also elm_scrolled_entry_single_line_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return single_line If true, the text in the scrolled entry is set to display
|
||||
* on a single line.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_single_line_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -280,6 +338,16 @@ elm_scrolled_entry_single_line_get(const Evas_Object *obj)
|
|||
return elm_entry_single_line_get(wd->entry);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This sets the scrolled entry object to password mode. All text entered
|
||||
* and/or displayed within the widget will be replaced with asterisks (*).
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param password If true, password mode is enabled.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_password_set(Evas_Object *obj, Eina_Bool password)
|
||||
{
|
||||
|
@ -289,6 +357,16 @@ elm_scrolled_entry_password_set(Evas_Object *obj, Eina_Bool password)
|
|||
elm_entry_password_set(wd->entry, password);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns whether password mode is enabled.
|
||||
* See also elm_scrolled_entry_password_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return If true, the scrolled entry is set to display all characters
|
||||
* as asterisks (*).
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_password_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -298,6 +376,15 @@ elm_scrolled_entry_password_get(const Evas_Object *obj)
|
|||
return elm_entry_password_get(wd->entry);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This sets the text displayed within the scrolled entry to @p entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param entry The text to be displayed
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_entry_set(Evas_Object *obj, const char *entry)
|
||||
{
|
||||
|
@ -307,6 +394,15 @@ elm_scrolled_entry_entry_set(Evas_Object *obj, const char *entry)
|
|||
elm_entry_entry_set(wd->entry, entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns the text currently shown in object @p entry.
|
||||
* See also elm_scrolled_entry_entry_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return The currently displayed text or NULL on failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI const char *
|
||||
elm_scrolled_entry_entry_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -316,6 +412,14 @@ elm_scrolled_entry_entry_get(const Evas_Object *obj)
|
|||
return elm_entry_entry_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns all selected text within the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return The selected text within the scrolled entry or NULL on failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI const char *
|
||||
elm_scrolled_entry_selection_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -325,6 +429,15 @@ elm_scrolled_entry_selection_get(const Evas_Object *obj)
|
|||
return elm_entry_selection_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This inserts text in @p entry at the beginning of the scrolled entry
|
||||
* object.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param entry The text to insert
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_entry_insert(Evas_Object *obj, const char *entry)
|
||||
{
|
||||
|
@ -334,6 +447,19 @@ elm_scrolled_entry_entry_insert(Evas_Object *obj, const char *entry)
|
|||
elm_entry_entry_insert(wd->entry, entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This enables word line wrapping in the scrolled entry object. It is the opposite
|
||||
* of elm_scrolled_entry_single_line_set(). Additionally, setting this disables
|
||||
* character line wrapping.
|
||||
* See also elm_scrolled_entry_line_char_wrap_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param wrap If true, the scrolled entry will be wrapped once it reaches the end
|
||||
* of the object. Wrapping will occur at the end of the word before the end of the
|
||||
* object.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_line_wrap_set(Evas_Object *obj, Eina_Bool wrap)
|
||||
{
|
||||
|
@ -343,6 +469,18 @@ elm_scrolled_entry_line_wrap_set(Evas_Object *obj, Eina_Bool wrap)
|
|||
elm_entry_line_wrap_set(wd->entry, wrap);
|
||||
}
|
||||
|
||||
/**
|
||||
* This enables character line wrapping in the scrolled entry object. It is the opposite
|
||||
* of elm_scrolled_entry_single_line_set(). Additionally, setting this disables
|
||||
* word line wrapping.
|
||||
* See also elm_scrolled_entry_line_wrap_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param wrap If true, the scrolled entry will be wrapped once it reaches the end
|
||||
* of the object. Wrapping will occur immediately upon reaching the end of the object.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_line_char_wrap_set(Evas_Object *obj, Eina_Bool wrap)
|
||||
{
|
||||
|
@ -352,6 +490,15 @@ elm_scrolled_entry_line_char_wrap_set(Evas_Object *obj, Eina_Bool wrap)
|
|||
elm_entry_line_char_wrap_set(wd->entry, wrap);
|
||||
}
|
||||
|
||||
/**
|
||||
* This sets the editable attribute of the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param editable If true, the scrolled entry will be editable by the user.
|
||||
* If false, it will be set to the disabled state.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_editable_set(Evas_Object *obj, Eina_Bool editable)
|
||||
{
|
||||
|
@ -361,6 +508,16 @@ elm_scrolled_entry_editable_set(Evas_Object *obj, Eina_Bool editable)
|
|||
elm_entry_editable_set(wd->entry, editable);
|
||||
}
|
||||
|
||||
/**
|
||||
* This gets the editable attribute of the scrolled entry.
|
||||
* See also elm_scrolled_entry_editable_set().
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return If true, the scrolled entry is editable by the user.
|
||||
* If false, it is not editable by the user
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_editable_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -370,6 +527,14 @@ elm_scrolled_entry_editable_get(const Evas_Object *obj)
|
|||
return elm_entry_editable_get(wd->entry);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* This drops any existing text selection within the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_select_none(Evas_Object *obj)
|
||||
{
|
||||
|
@ -379,6 +544,13 @@ elm_scrolled_entry_select_none(Evas_Object *obj)
|
|||
elm_entry_select_none(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This selects all text within the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_select_all(Evas_Object *obj)
|
||||
{
|
||||
|
@ -388,6 +560,14 @@ elm_scrolled_entry_select_all(Evas_Object *obj)
|
|||
elm_entry_select_all(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor one place to the right within the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return EINA_TRUE upon success, EINA_FALSE upon failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_next(Evas_Object *obj)
|
||||
{
|
||||
|
@ -397,6 +577,14 @@ elm_scrolled_entry_cursor_next(Evas_Object *obj)
|
|||
return elm_entry_cursor_next(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor one place to the left within the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return EINA_TRUE upon success, EINA_FALSE upon failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_prev(Evas_Object *obj)
|
||||
{
|
||||
|
@ -406,6 +594,14 @@ elm_scrolled_entry_cursor_prev(Evas_Object *obj)
|
|||
return elm_entry_cursor_prev(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor one line up within the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return EINA_TRUE upon success, EINA_FALSE upon failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_up(Evas_Object *obj)
|
||||
{
|
||||
|
@ -415,6 +611,14 @@ elm_scrolled_entry_cursor_up(Evas_Object *obj)
|
|||
return elm_entry_cursor_up(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor one line down within the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return EINA_TRUE upon success, EINA_FALSE upon failure
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_down(Evas_Object *obj)
|
||||
{
|
||||
|
@ -424,6 +628,13 @@ elm_scrolled_entry_cursor_down(Evas_Object *obj)
|
|||
return elm_entry_cursor_down(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor to the beginning of the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_begin_set(Evas_Object *obj)
|
||||
{
|
||||
|
@ -433,6 +644,13 @@ elm_scrolled_entry_cursor_begin_set(Evas_Object *obj)
|
|||
elm_entry_cursor_begin_set(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor to the end of the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_end_set(Evas_Object *obj)
|
||||
{
|
||||
|
@ -442,6 +660,13 @@ elm_scrolled_entry_cursor_end_set(Evas_Object *obj)
|
|||
elm_entry_cursor_end_set(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor to the beginning of the current line.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_line_begin_set(Evas_Object *obj)
|
||||
{
|
||||
|
@ -451,6 +676,13 @@ elm_scrolled_entry_cursor_line_begin_set(Evas_Object *obj)
|
|||
elm_entry_cursor_line_begin_set(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This moves the cursor to the end of the current line.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_line_end_set(Evas_Object *obj)
|
||||
{
|
||||
|
@ -460,6 +692,14 @@ elm_scrolled_entry_cursor_line_end_set(Evas_Object *obj)
|
|||
elm_entry_cursor_line_end_set(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This begins a selection within the scrolled entry as though
|
||||
* the user were holding down the mouse button to make a selection.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_selection_begin(Evas_Object *obj)
|
||||
{
|
||||
|
@ -469,6 +709,14 @@ elm_scrolled_entry_cursor_selection_begin(Evas_Object *obj)
|
|||
elm_entry_cursor_selection_begin(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This ends a selection within the scrolled entry as though
|
||||
* the user had just released the mouse button while making a selection.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_cursor_selection_end(Evas_Object *obj)
|
||||
{
|
||||
|
@ -478,6 +726,14 @@ elm_scrolled_entry_cursor_selection_end(Evas_Object *obj)
|
|||
elm_entry_cursor_selection_end(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO: fill this in
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return TODO: fill this in
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_is_format_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -487,6 +743,14 @@ elm_scrolled_entry_cursor_is_format_get(const Evas_Object *obj)
|
|||
return elm_entry_cursor_is_format_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns whether the cursor is visible.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return If true, the cursor is visible.
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_cursor_is_visible_format_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -496,6 +760,14 @@ elm_scrolled_entry_cursor_is_visible_format_get(const Evas_Object *obj)
|
|||
return elm_entry_cursor_is_visible_format_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO: fill this in
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return TODO: fill this in
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI const char *
|
||||
elm_scrolled_entry_cursor_content_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -505,6 +777,13 @@ elm_scrolled_entry_cursor_content_get(const Evas_Object *obj)
|
|||
return elm_entry_cursor_content_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This executes a "cut" action on the selected text in the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_selection_cut(Evas_Object *obj)
|
||||
{
|
||||
|
@ -514,6 +793,13 @@ elm_scrolled_entry_selection_cut(Evas_Object *obj)
|
|||
elm_entry_selection_cut(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This executes a "copy" action on the selected text in the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_selection_copy(Evas_Object *obj)
|
||||
{
|
||||
|
@ -523,6 +809,13 @@ elm_scrolled_entry_selection_copy(Evas_Object *obj)
|
|||
elm_entry_selection_copy(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This executes a "paste" action in the scrolled entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_selection_paste(Evas_Object *obj)
|
||||
{
|
||||
|
@ -532,6 +825,13 @@ elm_scrolled_entry_selection_paste(Evas_Object *obj)
|
|||
elm_entry_selection_paste(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This clears and frees the items in a scrolled entry's contextual (right click) menu.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_context_menu_clear(Evas_Object *obj)
|
||||
{
|
||||
|
@ -541,6 +841,18 @@ elm_scrolled_entry_context_menu_clear(Evas_Object *obj)
|
|||
elm_entry_context_menu_clear(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This adds an item to the scrolled entry's contextual menu.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param label The item's text label
|
||||
* @param icon_file The item's icon file
|
||||
* @param icon_type The item's icon type
|
||||
* @param func The callback to execute when the item is clicked
|
||||
* @param data The data to associate with the item for related functions
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_context_menu_item_add(Evas_Object *obj, const char *label, const char *icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, const void *data)
|
||||
{
|
||||
|
@ -550,6 +862,14 @@ elm_scrolled_entry_context_menu_item_add(Evas_Object *obj, const char *label, co
|
|||
elm_entry_context_menu_item_add(wd->entry, label, icon_file, icon_type, func, data);
|
||||
}
|
||||
|
||||
/**
|
||||
* This disables the scrolled entry's contextual (right click) menu.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param disabled If true, the menu is disabled
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_context_menu_disabled_set(Evas_Object *obj, Eina_Bool disabled)
|
||||
{
|
||||
|
@ -559,6 +879,14 @@ elm_scrolled_entry_context_menu_disabled_set(Evas_Object *obj, Eina_Bool disable
|
|||
elm_entry_context_menu_disabled_set(wd->entry, disabled);
|
||||
}
|
||||
|
||||
/**
|
||||
* This returns whether the scrolled entry's contextual (right click) menu is disabled.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @return If true, the menu is disabled
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI Eina_Bool
|
||||
elm_scrolled_entry_context_menu_disabled_get(const Evas_Object *obj)
|
||||
{
|
||||
|
@ -568,6 +896,15 @@ elm_scrolled_entry_context_menu_disabled_get(const Evas_Object *obj)
|
|||
return elm_entry_context_menu_disabled_get(wd->entry);
|
||||
}
|
||||
|
||||
/**
|
||||
* This sets the scrolled entry's scrollbar policy (ie. enabling/disabling them).
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param h The horizontal scrollbar policy to apply
|
||||
* @param v The vertical scrollbar policy to apply
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_scrollbar_policy_set(Evas_Object *obj, Elm_Scroller_Policy h, Elm_Scroller_Policy v)
|
||||
{
|
||||
|
@ -579,6 +916,15 @@ elm_scrolled_entry_scrollbar_policy_set(Evas_Object *obj, Elm_Scroller_Policy h,
|
|||
elm_scroller_policy_set(wd->scroller, h, v);
|
||||
}
|
||||
|
||||
/**
|
||||
* This enables/disables bouncing within the entry.
|
||||
*
|
||||
* @param obj The scrolled entry object
|
||||
* @param h The horizontal bounce state
|
||||
* @param v The vertical bounce state
|
||||
*
|
||||
* @ingroup Scrolled_Entry
|
||||
*/
|
||||
EAPI void
|
||||
elm_scrolled_entry_bounce_set(Evas_Object *obj, Eina_Bool h_bounce, Eina_Bool v_bounce)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue