Gary Qian
185087a65f
Manually draw remainder curve for wavy decorations ( #9468 )
2019-06-27 10:33:13 -07:00
Gary Qian
8591bd32e6
Handle ambiguous directionality of final trailing whitespace in mixed bidi text ( #9489 )
2019-06-26 15:08:36 -07:00
Jason Simmons
b188479981
Remove variants of ParagraphBuilder::AddText that are not used within the engine ( #9403 )
2019-06-24 12:41:01 -07:00
Jason Simmons
14c3c79f57
libtxt: remove obsolete font_manager_available defines ( #9376 )
2019-06-20 11:04:59 -07:00
Chinmay Garde
96a1a843cb
Replace lock_guard with scoped_lock and use class template argument deduction. ( #9338 )
2019-06-17 10:08:45 -07:00
Gary Qian
c5c0da1bfd
Build txt_benchmarks, make benches compile again ( #9330 )
2019-06-14 17:20:44 -07:00
Chinmay Garde
54ff3c5183
Avoid using std::unary_function ( #9314 )
2019-06-13 12:56:54 -07:00
Zachary Anderson
0a2e28d797
Revert tracing changes ( #9296 )
...
* Revert "[fuchsia] Fix alignment of Fuchsia/non-Fuchsia tracing (#9289 )"
This reverts commit f80ac5f571479053b134e60bca77603269b2ce2a.
* Revert "Align fuchsia and non-fuchsia tracing (#9199 )"
This reverts commit 78265484623037c6544dfd5380367bca29fa27b0.
2019-06-12 10:25:49 -07:00
Gary Qian
3371da1e09
Add platform_fuchsia.cc for default font on fuchsia ( #9204 )
2019-06-05 16:01:58 -07:00
Dan Field
7826548462
Align fuchsia and non-fuchsia tracing ( #9199 )
2019-06-05 15:14:27 -07:00
Gary Qian
a4abfb2333
Text inline widget LibTxt/dart:ui implementation ( #8207 )
2019-06-03 10:32:46 -07:00
Gary Qian
0932008480
Remove outdated TODOs ( #9114 )
2019-05-28 17:06:57 -07:00
Chris Bracken
a44cbbf492
Delete BSDiff sources ( #9086 )
...
BSDiff is no longer used as of flutter/engine#8663 . This removes the
unused Java import and sources.
2019-05-25 13:49:28 -07:00
Chris Bracken
0f1ff3bdb3
Correct typos, adopt US spellings ( #9081 )
...
Corects a bnuch of typeos throughout teh engien codebsae. Also makes
a couple minor Commonwealth -> US spelling adjustments for consistency
with the rest of Flutter's codebase.
Made use of `misspell` tool:
https://github.com/client9/misspell
2019-05-25 13:14:46 -07:00
Jason Simmons
82ccba3030
libtxt: have GetRectsForRange(strut) fall back to tight bounds if layout isn't forcing use of the strut ( #9058 )
2019-05-22 13:57:59 -07:00
Jason Simmons
135a140591
Add font features (such as tabular numbers) as an option in text styles ( #8823 )
...
Fixes https://github.com/flutter/flutter/issues/31691
2019-05-21 16:47:57 -07:00
Jason Simmons
424940f171
Add support for the Fontconfig-based Skia font manager ( #8977 )
2019-05-16 15:22:22 -07:00
Jason Simmons
aa63f090fd
libtxt: add a BoxHeightStyle option based on the height of the strut ( #8927 )
...
See https://github.com/flutter/flutter/issues/32332
2019-05-16 11:17:20 -07:00
Chinmay Garde
5ac2d02645
Avoid disabling sources assignment filters are these have been removed. ( #8954 )
2019-05-13 18:38:28 -07:00
bungeman
f4d23ef694
Replace Skia font macros with enums. ( #8920 )
...
This mechanically replaces kXXX_SkTextEncoding with SkTextEncoding::kXXX
and kXXX_SkFontHinting with SkFontHinting::kXXX. This will allow Skia to
remove these old macro constants and get everyone on the new enums.
2019-05-13 11:11:49 -07:00
Gary Qian
3822aeccd9
Prevent redundant layouts when floor(width) is the same ( #8867 )
2019-05-10 09:58:53 -07:00
Dan Field
7ce2666e54
Guard Android logs ( #8824 )
2019-05-03 14:32:29 -07:00
Justin McCandless
3493dcfbae
Rename tightWidth to longestLine ( #8706 )
...
Renaming a brand new and unused parameter due to some discussion about connecting with the framework.
2019-04-26 16:06:12 -07:00
Brian Osman
e4c439d370
Fix include paths in libtxt to prepare for upcoming Skia build change ( #8723 )
...
* Fix include paths in libtxt to prepare for upcoming Skia build change
Red test results are due to a different change. This PR fixes compile issues on the Skia side, and ensures that the next Skia -> Flutter roll can land properly.
2019-04-24 13:50:21 -04:00
Gary Qian
ea28bfa13e
Custom RTL handling for ghost runs, NotoNaskhArabic test font ( #8683 )
...
Relands #8638
2019-04-22 11:09:43 -07:00
liyuqian
1c9457cedc
Revert "Only allow mappings for ICU initialization. ( #8656 )" ( #8682 )
...
This reverts commit bd8c5b135e4d41842d0d5d42ff4943a18b8f4f0c.
Reverts flutter/engine#8656
Reason: https://github.com/flutter/engine/pull/8656 seems to break the framework windows tests and the engine roll (see https://cirrus-ci.com/task/4704667236827136 and https://github.com/flutter/flutter/pull/31330 ). The failure has been consistent for 7 consecutive engine-to-framework auto-rolls.
TBR: @chinmaygarde
2019-04-22 10:28:54 -07:00
liyuqian
b4ed3039fa
Revert "RTL handling for ghost runs, NotoNaskhArabic test font ( #8638 )" ( #8681 )
...
This reverts commit 6e79dcd0cfd9df08b4240a5aa158659c34e4154f.
Reverts flutter/engine#8638
Reason: flutter/engine#8638 breaks the post-submit Cirrus tests. See https://cirrus-ci.com/build/5143341531398144 and subsequent post-submit failures. Specifically, ParagraphTest.RightAlignParagraph is failing.
TBR: @GaryQian
2019-04-22 10:18:32 -07:00
Gary Qian
6e79dcd0cf
RTL handling for ghost runs, NotoNaskhArabic test font ( #8638 )
2019-04-21 00:30:53 -07:00
Chinmay Garde
bd8c5b135e
Only allow mappings for ICU initialization. ( #8656 )
...
If the mapping callback is not set or it the callback returns invalid data, ICU initialization will be embedder responsibility.
This affects all embedders and the following have been audited:
* Android: Via a symbol mapping.
* iOS: Via a file mapping.
* Embedder: Via a file mapping.
* Fuchsia: Via a VMO mapping
* Test shells and Flutter tester: Via file mapping with ICU data needing to be next to the executable.
2019-04-19 15:01:40 -07:00
Jason Simmons
4b9966f5cb
Add an adjustment to the line width check in LineBreaker::addWordBreak ( #8623 )
...
currentLineWidth is the width passed into Paragraph layout, which comes
from the maxIntrinsicWidth returned by a previous call to Paragraph layout.
That width is calculated by Layout::measureText.
postBreak is calculated from the character widths in the LineBreaker.
A slight mismatch between these two widths may unnecessarily cause the
insertion of desperate breaks in addWordBreak. Adding some slack to
currentLineWidth works around this.
Fixes https://github.com/flutter/flutter/issues/30347
2019-04-18 09:44:22 -07:00
Justin McCandless
a144f17aee
Tight Paragraph Width ( #8530 )
...
Calculate and expose paragraph tightWidth to the framework to allow drawing Text based on this.
2019-04-18 09:08:41 -07:00
Justin McCandless
06fea14e58
Glitchiness with Tab Characters ( #8591 )
...
Fix a bug that caused jumping and flashing when entering tab characters into a TextField.
2019-04-18 08:16:07 -07:00
Chris Bracken
82e6d68994
Eliminate unused write to local ( #8541 )
...
In GraphemeBreak::isGraphemeBreak() p0 is never read and
tailoredGraphemeClusterBreak() has no side-effects, so the call can be
eliminated.
2019-04-11 09:59:20 -07:00
Zachary Anderson
c00364a6c8
[font_collection] Add missing semicolon ( #8546 )
2019-04-11 09:45:24 -07:00
liyuqian
9bfa96dee9
Add trace events for creating minikin fonts ( #8477 )
...
Creating fonts can take a long time (50ms+) during frame build in the UI
thread. Trace them to help us understand when it's causing a jank.
2019-04-09 10:21:12 -07:00
Zachary Anderson
efbecd7e8e
[txt] Add back FontCollection::SetDefaultFontManager ( #8410 )
2019-04-02 10:22:12 -07:00
Jason Simmons
1339011991
libtxt: track the start and end x positions of glyph blobs for more accurate rendering of text decorations ( #8368 )
...
Fixes https://github.com/flutter/flutter/issues/30041
Fixes https://github.com/flutter/flutter/issues/24337
2019-03-29 13:01:37 -07:00
Jason Simmons
6d1a6a4f47
Allow per-platform customization of the default Skia font manager ( #8358 )
...
The font manager returned by SkFontMgr::RefDefault is determined by Skia's
build configuration flags. Embedders may want to use a default font manager
other than the one selected by their build of Skia.
2019-03-29 09:52:29 -07:00
Jason Simmons
7cbbdb4002
libtxt: more accurate tracking of run positioning and width for justified text ( #8214 )
...
Fixes https://github.com/flutter/flutter/issues/28891
2019-03-19 14:43:54 -07:00
Gary Qian
52b67fdd5a
Expose decorationThickness to dart:ui ( #8008 )
2019-03-11 16:43:11 -07:00
Core
302e2e9d2d
Fix cursor jumping when typing some special characters. ( #7964 )
2019-02-28 17:44:49 -08:00
Jason Simmons
1d0615af4e
libtxt: remove a debug log message in ComputeStrut ( #7953 )
2019-02-25 17:43:32 -08:00
Gary Qian
21c59197e7
[re-land] Use all font managers to discover fonts for strut. ( #7803 )
2019-02-22 13:44:02 -08:00
Stanislav Baranov
aa2b287cbf
Reland #7777 with proper LICENSE ( #7888 )
2019-02-21 13:45:24 -08:00
Jason Simmons
a5773d1211
Do not add ghost runs for trailing whitespace if the text is ellipsized ( #7906 )
2019-02-21 13:36:33 -08:00
Gary Qian
1263d28abf
Fix caret being at left edge when newline pressed on centered text ( #7875 )
2019-02-19 16:25:42 -08:00
Gary Qian
af39e22c31
Fix tests that were committed after cirrus ran ( #7819 )
2019-02-13 16:27:15 -08:00
Gary Qian
033f2072c3
Add space metrics tracking for trailing whitespace "ghost" runs. ( #7791 )
...
* Begin space tracking metrics in LibTxt.
* Add tracking for trailing whitespace.
* Store is_ghost in BidiRun
* Add comments
2019-02-13 15:19:53 -08:00
Gary Qian
74d94e52c6
Revert "Use all font managers to discover fonts for strut. ( #7734 )" ( #7801 )
...
This reverts commit c4a55552b5f07fdb0bb1db73df08a1843dd7e5a8.
2019-02-12 13:11:16 -08:00
Gary Qian
c4a55552b5
Use all font managers to discover fonts for strut. ( #7734 )
2019-02-12 03:32:59 -08:00