Tom Hacohen
1128519838
Evas textblock: Fixed issue with char/line_coord_set with valign. #2 .
...
After adding some tests, I found out that my previous fix was not enough.
SVN revision: 61362
2011-07-14 08:00:23 +00:00
Tom Hacohen
218042176b
Evas textblock: Fixed issue with char/line_coord_set with valign.
...
SVN revision: 61360
2011-07-14 07:36:45 +00:00
Tom Hacohen
70da0ccdbe
Evas textblock: Fixed a bug in line_coord_set with y<0.
...
SVN revision: 61344
2011-07-13 15:16:38 +00:00
Tom Hacohen
3b71290152
Evas textblock: Fixed a bug in cursor_char_coord_set with coords < 0.
...
SVN revision: 61341
2011-07-13 14:35:12 +00:00
Tom Hacohen
6c48f6f881
Evas textblock: Fixed a bug with scaling items.
...
SVN revision: 61334
2011-07-13 12:49:29 +00:00
Tom Hacohen
9d6d6cedc9
Evas textblock: Fixed style padding calculation.
...
SVN revision: 61253
2011-07-11 16:39:45 +00:00
Tom Hacohen
b55c9032aa
Evas textblock: Fixed an issue with escaped-html-like chars.
...
SVN revision: 61251
2011-07-11 15:56:47 +00:00
Tom Hacohen
5c0443cf79
Evas textblock: Removed useless function.
...
SVN revision: 61238
2011-07-11 12:30:15 +00:00
Tom Hacohen
7c14357161
Evas textblock: Fixed an issue with string_escaped_get.
...
SVN revision: 61235
2011-07-11 11:20:42 +00:00
Tom Hacohen
e01d587617
Evas textblock: Fixed evas_textblock_cursor_format_prev.
...
SVN revision: 61232
2011-07-11 08:56:17 +00:00
Tom Hacohen
8fe3776f8a
Evas textblock: Deprecated evas_textblock_cursor_set_at_format.
...
This was a duplicate of evas_textblock_cursor_at_format_set.
The only difference is the name, and this one doesn't conform to the naming
conventions.
SVN revision: 61231
2011-07-11 08:56:13 +00:00
Tom Hacohen
181eda995a
Evas textblock: Hopefully eliminate all issues with uninit cursors.
...
SVN revision: 61227
2011-07-11 07:23:12 +00:00
Tom Hacohen
0aab125684
Evas textblock: Fixed evas_textblock_cursor_eol_get.
...
SVN revision: 61207
2011-07-10 13:22:42 +00:00
Tom Hacohen
9fe4504574
Evas textblock: Fixed cursor_paragraph_text_length_get.
...
SVN revision: 61206
2011-07-10 13:22:38 +00:00
Tom Hacohen
d30603e37f
Evas textblock: Fixed a bug in _paragraph_char_last with the last par.
...
SVN revision: 61205
2011-07-10 13:22:33 +00:00
Tom Hacohen
ad79facc8a
Evas textblock: Fixed returned position of "clean" cursors.
...
Issue reported by Shilpa.
SVN revision: 61203
2011-07-10 12:18:48 +00:00
Tom Hacohen
70f9cf686f
Evas textblock: textblock_cursor_get's return should not be const.
...
This does not break API as it's more permissive and behavior doesn't change.
SVN revision: 61201
2011-07-10 12:18:42 +00:00
Tom Hacohen
a51b5660a2
Evas textblock: Fixed _cursor_char_coord_set with coords after the eol.
...
SVN revision: 61068
2011-07-06 07:32:23 +00:00
Tom Hacohen
3c6a42b04b
Evas textblock: Fixed weird cursor behavior with empty textblocks.
...
SVN revision: 61067
2011-07-06 07:32:14 +00:00
Tom Hacohen
c357c362fb
Evas textblock: Yet another coord_set fix.
...
SVN revision: 60750
2011-06-28 08:27:26 +00:00
Tom Hacohen
c81a71d18d
Evas textblock: Fixed coord_set and line_coord set in a couple of cases.
...
SVN revision: 60749
2011-06-28 08:13:45 +00:00
Tom Hacohen
4d13de35e9
Evas textblock: Should invalidate before declaring the object as changed.
...
SVN revision: 60353
2011-06-15 14:57:38 +00:00
Tom Hacohen
2da2cd7611
Evas textblock: Fixed scale update.
...
SVN revision: 60352
2011-06-15 14:57:21 +00:00
Tom Hacohen
b403eb49e0
Evas textblock: Fixed a rare issue with line wrapping and white stripping.
...
SVN revision: 60275
2011-06-13 16:04:55 +00:00
Tom Hacohen
04207db6b7
Evas textblock: Fixed charwrap for very small textblocks.
...
SVN revision: 60185
2011-06-10 10:12:51 +00:00
Tom Hacohen
59a22ad090
Evas textblock: Fixed two ellipsis issues.
...
1. If there's no wrapping enabled, do ellipsis even if we still have vertical
room left.
2. Fixed updating of o->have_ellipsis.
SVN revision: 60038
2011-06-07 11:38:07 +00:00
Tom Hacohen
2e28418051
Evas textblock: make charwrap not force wrap in an illegal position.
...
SVN revision: 59965
2011-06-05 10:51:39 +00:00
Tom Hacohen
9bd8ccae80
Evas textblock: Fixed an issue with min size calculation introduced in 59899
...
SVN revision: 59901
2011-06-02 14:52:43 +00:00
Tom Hacohen
5311e3de70
Evas textblock: Fixed min size calculation with right aligned paragraphs.
...
SVN revision: 59899
2011-06-02 14:02:31 +00:00
Tom Hacohen
1dfe691a36
Evas textblock: Start splitting layouting and layouting with rendering.
...
The difference is that we can now avoid doing some things when layouting but
not actually drawing, for example: bidi stuff.
SVN revision: 59871
2011-06-01 14:25:15 +00:00
Tom Hacohen
3e1727f7b1
Evas textblock: Use advance when calculating line breaks and widths.
...
SVN revision: 59870
2011-06-01 14:25:11 +00:00
Tom Hacohen
0a5b27c1bd
Evas textblock: Added a paragraph property to indicate if bidi.
...
SVN revision: 59869
2011-06-01 14:25:08 +00:00
Tom Hacohen
bebbe2253a
Evas textblock: Only use paragraph bidi props in the layout code.
...
Next commits will clear them outside of it. I.e paragraph bidi props are only
valid in the layout code.
SVN revision: 59861
2011-06-01 08:35:25 +00:00
Tom Hacohen
2b23129955
Evas textblock: Paragraphs don't need a x coordinate - remove.
...
SVN revision: 59860
2011-06-01 08:35:21 +00:00
Tom Hacohen
87d196e4bb
Evas textblock: Split _layout to _layout and _layout_pre.
...
This cleans the code a bit and will soon let us do smarter native size
calculation.
SVN revision: 59845
2011-05-31 12:55:57 +00:00
Tom Hacohen
7cdf099d5c
Evas textblock: Remove calc_only from layout, not needed anymore.
...
SVN revision: 59844
2011-05-31 12:55:54 +00:00
Tom Hacohen
71fe0782d9
Evas textblock: Move native size calculation out of the regular layout.
...
SVN revision: 59843
2011-05-31 12:55:51 +00:00
Tom Hacohen
b1d889a1df
Evas textblock: There can be only one ellipsis item per textblock.
...
SVN revision: 59816
2011-05-30 13:19:13 +00:00
Tom Hacohen
5a785e86bf
Evas textblock: Use Evas_Coord instead of int for coords.
...
SVN revision: 59815
2011-05-30 13:19:10 +00:00
Tom Hacohen
6d66a59333
Evas textblock: Removed some fat. Format should be a stringshare.
...
SVN revision: 59814
2011-05-30 13:19:07 +00:00
Tom Hacohen
943145d125
Evas textblock: Don't try to move text if the length to be moved is 0.
...
SVN revision: 59813
2011-05-30 13:19:03 +00:00
Tom Hacohen
56b6e2ed28
Evas textblock: Remove a bit of useless fat.
...
SVN revision: 59812
2011-05-30 13:19:00 +00:00
Tom Hacohen
a403ca75c2
Evas text/textblock: init cur_fi to NULL.
...
SVN revision: 59808
2011-05-30 10:55:31 +00:00
Tom Hacohen
884eaf1c63
Evas textblock: Fix casting of font when calling pipe op.
...
SVN revision: 59807
2011-05-30 09:03:46 +00:00
Tom Hacohen
a3719b21f9
Evas text/textblock: Check we actually found a font instance.
...
Currently we only check we have a font_set which is not enough.
Having a fontset and not having an fi should never happen, but it can.
SVN revision: 59804
2011-05-30 08:42:26 +00:00
Tom Hacohen
7e01aebd17
Evas textblock: clean up text_append, and possibly solve infinite loop.
...
I removed the workaround that solved it, for this cleaner, solution that
should work.
SVN revision: 59802
2011-05-30 08:16:35 +00:00
Tom Hacohen
0967176b12
Evas textblock: Removed ununeeded allocation.
...
SVN revision: 59801
2011-05-30 08:16:32 +00:00
Tom Hacohen
6b894e69fa
Evas textblock: Fix an issue with empty textblocks.
...
SVN revision: 59800
2011-05-30 07:52:44 +00:00
Tom Hacohen
599d9992b6
Evas textblock: Possible workaround for the infinite loop morlenxus is having.
...
SVN revision: 59791
2011-05-29 21:11:58 +00:00
Tom Hacohen
60aa86a0ef
Evas font-engine: Added two font opaque types.
...
Added Evas_Font_Instance and Evas_Font_Set which correspond to
RGBA_Font_Int and RGBA_Font. This is very important for strict type
checking which we now finally have.
This commit does not include logic changes, only casting and changing
types of pointers to the opaque pointer types.
SVN revision: 59782
2011-05-29 13:00:54 +00:00
Tom Hacohen
b7e2277ef0
Evas textblock/font-engine: Fix compiler warnings with -Wshadow.
...
SVN revision: 59781
2011-05-29 12:03:20 +00:00
Tom Hacohen
dbe7a9800e
Evas textblock: Added support for numeric escape sequences.
...
Patch by Raoul Hecky.
SVN revision: 59780
2011-05-29 11:47:53 +00:00
Tom Hacohen
81b217f8c4
Evas font-engine: Fixed font fallback in the same script run.
...
SVN revision: 59777
2011-05-29 09:20:18 +00:00
Tom Hacohen
359e67f68a
Evas textblock: Added an rbtree index for the layout paragraphs.
...
This can be used with both coordinates and line numbers, this is a
faster way to find layout paragraphs in the textblock which means
we should now be a lot faster with big textblocks.
SVN revision: 59527
2011-05-19 09:54:30 +00:00
Tom Hacohen
3227929fcf
Evas textblock: Use the saved paragraph pointer instead of searching.
...
SVN revision: 59526
2011-05-19 09:54:19 +00:00
Tom Hacohen
dd503b47fd
Evas textblock: Fix a potential bug in wrapping.
...
SVN revision: 59464
2011-05-17 07:08:33 +00:00
Tom Hacohen
e4dada93e6
Evas textblock: Set cursor position if not already set when inserting text.
...
This was always the meaning of cur->node=NULL, but here it explicitly
does it, which makes things easier in the long run.
SVN revision: 59406
2011-05-15 15:36:04 +00:00
Tom Hacohen
1e542a0d47
Evas textblock: Fixed a possible bug with wordwrap.
...
SVN revision: 59405
2011-05-15 13:57:47 +00:00
Tom Hacohen
353ce0f48a
Evas textblock: Speed up rendering. Find the start paragraph for all.
...
Until now all the format/text drawing loops went through all the
paragraphs skipping all the ones that are outside the clipping/object
zone. This changeset find the first paragraph to be renedred first so we
don't walk all the paragraphs for nothing. This speeds up rendering of
the ends of very big textblocks in a very noticable manner.
SVN revision: 59404
2011-05-15 12:00:01 +00:00
Tom Hacohen
8315f9879c
Evas textblock: Fix segfault with evas_textblock_cursor_content_get.
...
Patch by Brian Wang.
SVN revision: 59347
2011-05-12 15:12:10 +00:00
Tom Hacohen
13d032d0b1
Evas textblock: Added _format_list_get for fast retrieval of anchors.
...
This is very useful in edje_entry that keeps a list of anchors.
Currently only "a" and "item" are supported, and unless something
drastic will happen, it will stay this way.
SVN revision: 59325
2011-05-11 10:18:24 +00:00
Tom Hacohen
faba2810b4
Evas textblock: Don't allow overwriting the format stack.
...
SVN revision: 59320
2011-05-11 08:35:09 +00:00
Tom Hacohen
fd25efda3a
Evas textblock: Only parse formats that can change the format stack.
...
No need to parse all the newlines when all we want is just to modify the
format stack.
SVN revision: 59319
2011-05-11 08:34:57 +00:00
Tom Hacohen
730bfce44e
Evas textblock: Do a bit of uchar -> Eina_Bool and setting as bitfield.
...
SVN revision: 59281
2011-05-08 15:33:23 +00:00
Tom Hacohen
1a0fba718f
Evas textblock: Remove unused alloca.
...
SVN revision: 59280
2011-05-08 15:33:20 +00:00
Tom Hacohen
edafdf5323
Evas textblock: Clean up clipping and render a bit.
...
SVN revision: 59279
2011-05-08 14:54:27 +00:00
Tom Hacohen
9f29ea18d3
Evas textblock: Break on mandatory and allowed break options.
...
SVN revision: 59274
2011-05-08 11:20:19 +00:00
Tom Hacohen
8214888f83
Evas textblock: Moved format text_node invalidation to it's own function.
...
SVN revision: 59273
2011-05-08 11:20:16 +00:00
Tom Hacohen
47a59417d2
Evas textblock: Move ellipsis handling to a different function.
...
SVN revision: 59272
2011-05-08 11:20:13 +00:00
Tom Hacohen
6d14277c6d
Evas textblock: clean up mixed/word wrap a bit.
...
SVN revision: 59271
2011-05-08 09:13:59 +00:00
Tom Hacohen
4851a57f92
Evas textblock: Fix possible issues with charwrap not wrapping correctly.
...
SVN revision: 59270
2011-05-08 09:13:56 +00:00
Tom Hacohen
2d0304019d
Evas textblock: Fix seg with empty textblocks that cause wrapping.
...
Revert "evas: don't assume anymore that text_node is != NULL."
This reverts commit 59231
Thanks to cedric for the report + initial fix.
SVN revision: 59237
2011-05-06 10:00:21 +00:00
Cedric BAIL
139e49792d
evas: don't assume anymore that text_node is != NULL.
...
SVN revision: 59231
2011-05-06 09:00:44 +00:00
Tom Hacohen
53a6bbeb8b
Evas textblock: Fix linewrap to only wrap if there's a wrap point.
...
For example before the fix, "aaa<b>cccc</>aaa" would have 2 possible
wrap points, <b> and </>, after the fix, those are no longer valid.
Also fixed another issue with wrapping not working.
SVN revision: 59219
2011-05-05 16:35:39 +00:00
Tom Hacohen
4c9b729cd3
Evas textblock: Updated a FIXME.
...
SVN revision: 59218
2011-05-05 16:35:36 +00:00
Tom Hacohen
31c8b4d7f7
Evas textblock: Until we actually use it in charwrap, don't malloc line_breaks.
...
SVN revision: 59217
2011-05-05 16:35:32 +00:00
Tom Hacohen
9677320259
Evas textblock: Wrapping is now absolute to the paragraph.
...
This is not yet noticable, still need to use the new info.
SVN revision: 59215
2011-05-05 13:38:09 +00:00
Tom Hacohen
c6751884b0
Evas textblock: Use more relevant replacement chars for formats.
...
For example we use 0x2029 (PS char) for paragraph separator, \n for newline
and \t for tab. This lets us handle their bidi and line break properties
in a more correct manner.
SVN revision: 59214
2011-05-05 13:38:04 +00:00
Tom Hacohen
921067869c
Evas textblock: Clean up word/mixed wrap and add liblinebreak support.
...
SVN revision: 59208
2011-05-05 11:06:06 +00:00
Tom Hacohen
e93f10b8aa
Evas font-engine: Remove passing of strings to font_draw.
...
This is not needed anymore because we have working string objects.
SVN revision: 59133
2011-05-02 15:33:46 +00:00
Tom Hacohen
4fafc63d0f
Evas textblock: Remove obsolete comment.
...
SVN revision: 59130
2011-05-02 15:33:31 +00:00
Tom Hacohen
0bf964a221
Evas textblock: We finally cache fi - remove related hacks.
...
SVN revision: 59129
2011-05-02 15:33:27 +00:00
Tom Hacohen
1ce96a62e0
Evas textblock: Unified the wmax calculation into one place.
...
SVN revision: 59097
2011-05-02 07:27:48 +00:00
Tom Hacohen
8991e90293
Evas textblock: Fixed a bug with drawing formats when clipped.
...
SVN revision: 59001
2011-04-28 12:12:57 +00:00
Tom Hacohen
ff0bcef2db
Evas textblock: Added "password" tag - toggle password mode.
...
This lets you toggle the password mode inside the text. Especially
useful for implementing "show last char" in password entries.
Patch by Shilpaonkar Singh
SVN revision: 59000
2011-04-28 11:08:20 +00:00
Tom Hacohen
368a77aea0
Evas textblock: Fixed *_format_remove_pair to invalidate the text nodes.
...
SVN revision: 58991
2011-04-28 08:18:44 +00:00
Tom Hacohen
3e5cb0ac98
Evas textblock: Use strncmp instead of strncpy and strcmp.
...
SVN revision: 58963
2011-04-27 14:59:22 +00:00
Tom Hacohen
722707547a
Evas textblock: Implement format invalidation points support.
...
This lets us only relayout what's needed also when inserting formats.
This means inserting <b> </> for example is now as fast as inserting any
other char and doesn't cause a complete relayout.
SVN revision: 58958
2011-04-27 12:41:26 +00:00
Tom Hacohen
902d94afb9
Evas textblock: Added a temp fix for repch until implemented nicely.
...
This fix is just until we finally split to scripts and cache fi all
the time, i.e in all the possible paths (regular, fribidi and harfbuzz).
SVN revision: 58806
2011-04-21 15:34:44 +00:00
Tom Hacohen
3f86ed9349
Evas textblock: Clean repch code a bit. No logic changes.
...
SVN revision: 58801
2011-04-21 14:04:46 +00:00
Tom Hacohen
cb19804054
Evas bidi: Fixed spelling errors: NATURAL -> NEUTRAL (Macro name).
...
SVN revision: 58760
2011-04-20 14:35:37 +00:00
Tom Hacohen
b59156c788
Evas text/textblock: Change item size calculation to use advance again.
...
We don't need to do any tricks anymore because size calculation is now
very fast, as fast as the tricks we did, so it's best to just do what
we really want to do.
SVN revision: 58757
2011-04-20 14:20:54 +00:00
Tom Hacohen
e6be4f7deb
Evas textblock: Fixed an invalid read.
...
In some cases an invalid read would occur. This was because we didn't
handle node merging appropriately.
SVN revision: 58701
2011-04-17 08:38:29 +00:00
Tom Hacohen
f5e7165a65
Evas text/textblock: Add setting bidi_delimiter API.
...
SVN revision: 58669
2011-04-14 15:34:01 +00:00
Tom Hacohen
d0e889fbe7
Evas textblock: Clean up a bit.
...
SVN revision: 58663
2011-04-14 12:34:29 +00:00
Tom Hacohen
2a7b919cd7
Evas textblock: Move bidi props to the layout paragraphs.
...
This will let us do cool overrides more control via higher level protocol
when we'll want to.
SVN revision: 58662
2011-04-14 12:13:20 +00:00
Tom Hacohen
86fd95e80e
Evas textblock: Fixed invalid reads with ellipsis in some cases.
...
SVN revision: 58659
2011-04-14 11:37:09 +00:00
Tom Hacohen
e6edd2ce7f
Evas textblock: Fixed ellipsis.
...
It's actually just a workaround until we finally fix draw to not need
the text.
SVN revision: 58658
2011-04-14 11:37:06 +00:00
Tom Hacohen
46beed0916
Evas bidi: Added a way to ask for bidi segmentation indexes.
...
This lets you pass the bidi engine a list of indexes in the paragraph,
that will segment it bidi-wise. I.e the bidi algorithm will be applied to
each segment individually. This implements HL4 of the bidi algorithm.
SVN revision: 58652
2011-04-14 07:40:42 +00:00
Tom Hacohen
9de9eca278
Evas textblock: Reformat if not valid in some cases we forgot.
...
SVN revision: 58651
2011-04-14 07:34:06 +00:00