Etk
Main Page Object Hierarchy Data Structures Related Pages
Etk

etk_textblock2.c File Reference


Detailed Description


Functions

Etk_Textblock2 * etk_textblock2_new (void)
 Creates a new textblock.
void etk_textblock2_text_set (Etk_Textblock2 *tb, const char *text, Etk_Bool markup)
 Sets the text of the textblock. The current text will be replaced by text.
Etk_String * etk_textblock2_text_get (Etk_Textblock2 *tb, Etk_Bool markup)
 Gets the text of the textblock.
Etk_String * etk_textblock2_range_text_get (Etk_Textblock2_Iter *iter1, Etk_Textblock2_Iter *iter2, Etk_Bool markup)
 Gets the text of the textblock, between iter1 and iter2.
void etk_textblock2_insert (Etk_Textblock2_Iter *iter, const char *text, int length)
 Inserts length bytes of text at iter in the textblock. If you want to use tags to format the inserted text, you should use etk_textblock2_insert_markup() instead.
void etk_textblock2_insert_markup (Etk_Textblock2_Iter *iter, const char *markup_text, int length)
 Inserts length bytes of text at iter in the textblock. Tags can be used to format the text.
void etk_textblock2_clear (Etk_Textblock2 *tb)
 Clears the text of the given textblock. After this operation, the textblock will only have one paragraph, with one line made up of one empty node. All the iterators will still be valid and will be placed at the start of the empty textblock.
Etk_Bool etk_textblock2_delete_before (Etk_Textblock2_Iter *iter)
 Deletes the character before the iterator.
Etk_Bool etk_textblock2_delete_after (Etk_Textblock2_Iter *iter)
 Deletes the character after the iterator.
void etk_textblock2_delete_range (Etk_Textblock2_Iter *iter1, Etk_Textblock2_Iter *iter2)
 Deletes the text between iter1 and iter2.
void etk_textblock2_printf (Etk_Textblock2 *tb)
 Prints the textblock's structure to stdout. This function is for debug-purpose only and should be deleted soon.
Etk_Textblock2_Paragraph * etk_textblock2_paragraph_add (Etk_Textblock2_Iter *iter)
 Adds a new paragraph to the textblock at . The new paragraph will contain the content of the current paragraph located after the iterator. The iterator will be placed at the start of the new paragraph. The new paragraph will have the same properties as the current one.
Etk_Bool etk_textblock2_paragraph_delete (Etk_Textblock2_Paragraph *paragraph)
 Deletes an existing paragraph of a textblock. If the paragraph was the last remaining paragraph of the textblock, a new empty paragraph will be created (a textblock always has to have at least one paragraph in order to remain valid). The iterators will be moved to the start of the next paragraph if there is one, or to the end of the textblock otherwise.
Etk_Textblock2_Paragraph * etk_textblock2_paragraph_first_get (Etk_Textblock2 *tb)
 Gets the first paragraph of the textblock.
Etk_Textblock2_Paragraph * etk_textblock2_paragraph_last_get (Etk_Textblock2 *tb)
 Gets the last paragraph of the textblock.
Etk_Textblock2_Paragraph * etk_textblock2_paragraph_prev_get (Etk_Textblock2_Paragraph *paragraph)
 Gets the paragraph before paragraph.
Etk_Textblock2_Paragraph * etk_textblock2_paragraph_next_get (Etk_Textblock2_Paragraph *paragraph)
 Gets the paragraph after paragraph.
Etk_Textblock2_Line * etk_textblock2_line_add (Etk_Textblock2_Iter *iter)
 Adds a new line to the textblock at . The new line will contain the content of the current line located after the iterator. The iterator will be placed at the start of the new line.
Etk_Bool etk_textblock2_line_delete (Etk_Textblock2_Line *line)
 Deletes an existing line of a paragraph. If the line was the last remaining line of the paragraph, a new empty line will be created (a paragraph always has to have at least one line in order to remain valid). The iterators will be moved to the start of the next line if there is one, or to the end of the textblock otherwise.
Etk_Textblock2_Line * etk_textblock2_line_first_get (Etk_Textblock2_Paragraph *paragraph)
 Gets the first line of the paragraph.
Etk_Textblock2_Line * etk_textblock2_line_last_get (Etk_Textblock2_Paragraph *paragraph)
 Gets the last line of the paragraph.
Etk_Textblock2_Line * etk_textblock2_line_prev_get (Etk_Textblock2_Line *line)
 Gets the line before node in the current paragraph.
Etk_Textblock2_Line * etk_textblock2_line_next_get (Etk_Textblock2_Line *line)
 Gets the line after node in the current paragraph.
Etk_Textblock2_Line * etk_textblock2_line_walk_prev (Etk_Textblock2_Line *line)
 Walks to the previous line of the textblock. Unlike etk_textblock2_line_prev_get(), this function will not return NULL if the line is the first line of the paragraph. In this case, it will return the last line of the previous paragraph of the textblock.
Etk_Textblock2_Line * etk_textblock2_line_walk_next (Etk_Textblock2_Line *line)
 Walks to the next line of the textblock. Unlike etk_textblock2_line_next_get(), this function will not return NULL if the line is the last line of the paragraph. In this case, it will return the first line of the next paragraph of the textblock.
Etk_Textblock2_Node * etk_textblock2_node_add (Etk_Textblock2_Iter *iter)
 Adds an empty node to the textblock at .
Etk_Bool etk_textblock2_node_delete (Etk_Textblock2_Node *node)
 Deletes an existing node of a line. If the node was the last remaining node of the line, a new empty node will be created (a line always has to have at least one node in order to remain valid). The iterators will be moved to the start of the next node if there is one, or to the end of the textblock otherwise.
Etk_Textblock2_Node * etk_textblock2_node_first_get (Etk_Textblock2_Line *line)
 Gets the first node of the line.
Etk_Textblock2_Node * etk_textblock2_node_last_get (Etk_Textblock2_Line *line)
 Gets the last node of the line.
Etk_Textblock2_Node * etk_textblock2_node_prev_get (Etk_Textblock2_Node *node)
 Gets the node before node in the current line.
Etk_Textblock2_Node * etk_textblock2_node_next_get (Etk_Textblock2_Node *node)
 Gets the node after node in the current line.
Etk_Textblock2_Node * etk_textblock2_node_walk_prev (Etk_Textblock2_Node *node)
 Walks to the previous node of the textblock. Unlike etk_textblock2_node_prev_get(), this function will not return NULL if the node is the first node of the line. In this case, it will return the last node of the previous line of the textblock.
Etk_Textblock2_Node * etk_textblock2_node_walk_next (Etk_Textblock2_Node *node)
 Walks to the next node of the textblock. Unlike etk_textblock2_node_next_get(), this function will not return NULL if the node is the last node of the line. In this case, it will return the first node of the next line of the textblock.
void etk_textblock2_node_format_set (Etk_Textblock2_Node *node, const Etk_Textblock2_Format *format)
 TODOC.
const Etk_Textblock2_Format * etk_textblock2_node_format_get (Etk_Textblock2_Node *node)
 TODOC.
void etk_textblock2_node_format_apply (Etk_Textblock2_Node *node, const char *format)
 TODOC.
Etk_Textblock2_Format * etk_textblock2_format_new (void)
 TODOC.
void etk_textblock2_format_free (Etk_Textblock2_Format *format)
 TODOC.
void etk_textblock2_format_reset (Etk_Textblock2_Format *format)
 TODOC.
void etk_textblock2_format_copy (Etk_Textblock2_Format *format1, const Etk_Textblock2_Format *format2)
 TODOC.
Etk_Textblock2_Iter * etk_textblock2_iter_new (Etk_Textblock2 *tb)
 Creates a new iterator for the textblock. The new iterator will be placed at the start of the textblock. Iterators Are used to insert or delete text section at specific places.
void etk_textblock2_iter_free (Etk_Textblock2_Iter *iter)
 Destroys the given iterator. It will no longer be usable.
void etk_textblock2_iter_copy (Etk_Textblock2_Iter *dest, Etk_Textblock2_Iter *src)
 Copies the iterator src to the iterator dest.
int etk_textblock2_iter_compare (Etk_Textblock2_Iter *iter1, Etk_Textblock2_Iter *iter2)
 Compare the position of the two iterators.
void etk_textblock2_iter_backward_start (Etk_Textblock2_Iter *iter)
 Moves the iterator at the start of the textblock.
void etk_textblock2_iter_forward_end (Etk_Textblock2_Iter *iter)
 Moves the iterator at the end of the textblock.
Etk_Bool etk_textblock2_iter_backward_char (Etk_Textblock2_Iter *iter)
 Moves the iterator backward by one character offset.
Etk_Bool etk_textblock2_iter_forward_char (Etk_Textblock2_Iter *iter)
 Moves the iterator fortward by one character offset.
Evas_Object * etk_textblock2_object_add (Etk_Textblock2 *tb, Evas *evas)
 Creates a new textblock-object that will be used to render the textblock's content. A textblock can have several textblock-objects.
Etk_Textblock2_Iter * etk_textblock2_object_cursor_get (Evas_Object *tbo)
 Gets the cursor's iterator of the given textblock-object.
Etk_Textblock2_Iter * etk_textblock2_object_selection_bound_get (Evas_Object *tbo)
 Gets the selection-bound's iterator of the given textblock-object.
void etk_textblock2_object_offset_set (Evas_Object *tbo, int xoffset, int yoffset)
 TODOC.
void etk_textblock2_object_offset_get (Evas_Object *tbo, int *xoffset, int *yoffset)
 TODOC.