Commit graph

74 commits

Author SHA1 Message Date
Andrea Bogazzi
b89bc01847 Fix misplacement of some iText 2015-03-01 19:05:50 +01:00
Andrea Bogazzi
0e09961c64 Update to text, rendering and optimization 2015-01-26 02:49:37 +01:00
Ulrich Sossou
dc7266bc1d Fix coding style 2014-08-24 18:25:58 +01:00
Ulrich Sossou
2541b7b69b Properly calculate width of whitespace characters when text is justified 2014-08-24 15:41:51 +01:00
Ulrich Sossou
a9933a5450 Use _getTopOffset to calculate top cursor boundary
Left cursor boundary is calculated with _getLeftOffset,
top cursor boundary should also be calculated with the corresponding offset method
2014-08-20 13:51:17 +01:00
kangax
818ab118b3 JSCS changes; Prepare for JSCS ignore support; down to 51 failures 2014-08-03 16:47:27 +02:00
Stefan Kienzle
b34387d10e JSDoc + JSCS tweaks - Part 1 2014-07-17 16:18:57 +02:00
Mike Shaver
825bec65df More doc-comment fixes. 2014-07-15 15:59:53 -07:00
Mike Shaver
095ee86e37 Fix some doc comment errors that were preventing build. 2014-07-15 15:34:06 -07:00
Chris Buergi
9a867f893f Fire 'selection:changed' on IText object.
Previously the 'text:selection:changed' was only fired on the canvas, but not on the object.
2014-07-03 10:02:47 +02:00
Chris Buergi
dda68b44dd Render IText correctly when only fontWeight or fontStyle changes
Fixes rendering of characters that only have the styles "fontWeight" and/or "fontStyle" set. Previously _hasStyleChanged() did not detect a change if only one of those two styles have been set.
2014-06-30 16:19:35 +02:00
kangax
d2f6a9033e Add JSCS validation & change bunch of things for conformance. Down to 333 failures from ~1000. 2014-02-16 16:36:14 -05:00
kangax
512b0186c8 Tweak iText after PR 2014-02-01 14:24:25 -05:00
Juriy Zaytsev
4a967b7ddf Merge pull request #1114 from GordoRank/Improve-IText-performance
Improve overall IText performance with varying styles > 1000%
2014-02-01 11:22:20 -08:00
kangax
68d4a74def Tweak few things in iText; build distribution 2014-02-01 13:18:22 -05:00
Juriy Zaytsev
93bd41f356 Merge pull request #1113 from GordoRank/Reduce-calls-to-fillText/strokeText-for-IText
Reduce calls to fillText/fillStroke in IText
2014-02-01 10:15:39 -08:00
Juriy Zaytsev
213b99eb9f Merge pull request #1127 from GordoRank/Optimize-searchPossibleTargets-for-IText
Optimize searchPossibleTargets for I-text
2014-01-27 12:54:02 -08:00
kangax
e977372236 Remove node 0.6 from travis until jsdom fixes it 2014-01-23 11:25:04 -05:00
Juriy Zaytsev
b600c39119 Merge pull request #1112 from GordoRank/Add-textselected-event
Add "text:selection:changed" event
2014-01-22 21:48:36 -08:00
GordoRank
f6108963b2 switch to 'text:selection:changed' 2014-01-23 01:31:20 +00:00
GordoRank
4631a8929a Update itext.class.js 2014-01-20 20:59:04 +00:00
GordoRank
ab67a7d1d6 Update itext.class.js 2014-01-20 15:28:50 +00:00
GordoRank
394732f3a3 Update renderCursor/renderSelection
Update renderCursor()/renderSelection() to draw to separate canvas
2014-01-20 14:54:41 +00:00
GordoRank
e3dd37ff22 remove IText _render()
The ```the _render()``` method for IText objects is no longer needed when since rendering cursor/selection is now handled elsewhere
2014-01-20 14:51:21 +00:00
GordoRank
40b04c7b11 Let _getWidthOfChar() return cached values 2014-01-20 11:19:01 +00:00
GordoRank
cec2a17a47 Remove clashing 'selected' event firing 2014-01-20 09:43:00 +00:00
GordoRank
8cf567522d Update itext.class.js 2014-01-20 08:50:02 +00:00
GordoRank
72e1b91ee4 Reduce calls to fillText/fillStroke in IText 2014-01-20 08:42:24 +00:00
GordoRank
3e1433acb1 Add text:selected event 2014-01-20 08:21:00 +00:00
GordoRank
d088bb1fb7 Fix IText selection with varying font widths 2014-01-20 07:28:33 +00:00
kangax
4761c2527c Build distribution 2014-01-14 12:57:13 -05:00
Juriy Zaytsev
d4ea2c6f1e Merge pull request #1097 from GordoRank/master
Rewrite renderSelection to only draw once per line
2014-01-14 09:46:16 -08:00
GordoRank
0abc547d6b Fixed formatting and cache start.lineIndex 2014-01-14 17:37:40 +00:00
kangax
166dc60716 Fix JSHint warnings, build distribution 2014-01-14 12:34:32 -05:00
GordoRank
9f2c678a66 Formatting fixed and end.lineIndex cached 2014-01-14 17:23:40 +00:00
GordoRank
350261437a Rewrite renderSelection to only draw once per line
Previously RenderSelection performed a fillRect() command for every character.  This resulted in poor performance on large bodies of text.  This rewrite calculates the selection box for each line of text and draws a single rectangle for each line, dramatically improving performance.
2014-01-14 17:09:19 +00:00
GordoRank
90a97e6272 Fix click cursor placement on center/right text
This clamps the click cursor placement so that clicking to the left of a short first line of centered/right aligned text positions the cursor to the left of the first character in the line....

Previously in that instance it would move to the left boundary instead
2014-01-14 15:48:59 +00:00
GordoRank
272859b8f1 Formatting fixes 2014-01-14 11:03:27 +00:00
GordoRank
55bc6a990b Make flashing cursor behave like MSWord 2014-01-13 12:04:46 +00:00
Kienz
da0866429a Initialize fabric.IText canvas handlers only once. Closes #1076
Qunit additions
2014-01-12 15:32:50 +01:00
kangax
ec629c6b59 Update text events 2013-12-18 11:28:06 +01:00
kangax
032cc05bd1 Fix background offset in iText. Closes #1029 2013-12-14 14:55:47 +01:00
kangax
79b4474e77 Mention that itext supports ctrl/cmd+a 2013-12-14 12:04:26 +01:00
kangax
0f23f14a44 Add fabric.IText#caching 2013-11-27 19:48:35 +01:00
kangax
435f3933ac Fix i-text line-through offset 2013-11-26 14:58:53 +01:00
kangax
ae11740f82 Fix i-text style copy-pasting (doesn't work with multiline yet) 2013-11-25 21:32:00 +01:00
kangax
82509dc8d8 More IText tests 2013-11-23 13:45:53 +01:00
kangax
673fa39eba Start adding i-text unit tests; add additional util and color tests 2013-11-22 17:30:55 +01:00
kangax
942b5cfd8d Add "editing:entered" and "editing:exited" events 2013-11-20 20:25:18 +01:00
kangax
81e9535ef0 Small code cleanup 2013-11-20 12:47:03 +01:00