Commit Graph

63 Commits

Author SHA1 Message Date
Julia Lavrova
62f07d262c Like breaking for a single line text
Change-Id: Ib9955d56bcf658aa78eb8dc8d5c48e8ccdf01581
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/528440
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2022-04-15 14:47:49 +00:00
Kevin Lubick
83cee23c98 [bazel] Run buildifier on BUILD.bazel files
buildifier --lint=fix -r .

Change-Id: I6a41858270d20137978f8271c8f6160b51120777
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/529751
Reviewed-by: Ben Wagner <bungeman@google.com>
2022-04-14 18:13:43 +00:00
Kevin Lubick
b98328a27b [bazel] Add license to all our BUILD.bazel files
find -name "BUILD.bazel" -exec sed -i -e '1i licenses(["notice"])\n' {} +

Change-Id: Ie48f163b7d8d6ede9ba5f952e87232dd5c9fa8e6
Bug: skia:12541
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/529808
Reviewed-by: Ben Wagner <bungeman@google.com>
2022-04-13 19:50:29 +00:00
Julia Lavrova
55c56abac3 Simplify the most commont paint case
Change-Id: Ie6efa0cdcf682ad7ea5c1d4ca6232af6224a68f4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/527282
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2022-04-08 14:20:38 +00:00
Julia Lavrova
cf3e1c4fe9 Remove DrawOptions (except direct drawing)
That would allow us not to query glyph bounds

Change-Id: Ibee53446e33fd6a54affc1ded438191186cd21be
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/526296
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2022-04-01 15:46:39 +00:00
Julia Lavrova
7f57bceae2 Ellipsis in RTL
For entirely RTL text the ellipsis expected to be on the left side.

Bug: skia:13069
Change-Id: I853687e1e741dd57af950f17717fa8553648b477
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/523856
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2022-03-24 20:27:49 +00:00
Julia Lavrova
85a7045856 Fixing some getRectsForRange issues
This fix only affects 2 very specific cases used for text selection
in Flutter (via getRectsForRange).

bug: skia:12785
Change-Id: I22d141210d129d78ed028592162fef02b9120292
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/491450
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2022-01-06 18:53:23 +00:00
Kevin Lubick
4bd08c52c0 [infra] Add SkParagraph (harfbuzz, ICU) to Canvaskit Bazel build.
As a follow-up to https://skia-review.googlesource.com/c/skia/+/476219,
this sketches out how we can maybe use cc_library for the things
in //modules to make sure something in //src doesn't depend on
anything in //modules, for example.

The following succeeds:
bazel build //modules/skparagraph:skparagraph --config=clang \
  --shaper_backend=harfbuzz_shaper --with_icu

As does `make bazel_canvaskit_debug` in //modules/canvaskit

Suggested Review Order:
 - third_party/BUILD.bazel for ICU and harfbuzz rules. Pay
   special attention to the genrules used to call the python
   script for turning the icu .dat file into .S or .cpp.
 - bazelrc and bazel/ for new flags and defines that control
   use of ICU and harfbuzz. Unlike GN, with the public_defines
   that get added in automatically if icu or harfbuzz is
   depended upon, we need to set the defines at the top level.
   This necessity might go away if we change the atoms to
   depend on //modules/skshaper, which could define that flag.
 - Top level BUILD.bazel files in //modules/skparagraph,
   //modules/skshaper, //modules/skunicode, //modules/canvaskit
 - All other .bazel file changes are automatic.

Bug: skia:12541
Change-Id: I38a9e0a9261d7e142eeb271c2ddb23f362f91473
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/478116
Reviewed-by: Ben Wagner <bungeman@google.com>
Reviewed-by: Leandro Lovisolo <lovisolo@google.com>
2021-11-30 21:01:06 +00:00
Julia Lavrova
8a4ba51fa7 Flutter RTL/LTR positioning fix
Bug: skia:12647
Change-Id: I7de8931183c3ed9ae82864ed766fff9a196e856c
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/471777
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-11-16 20:23:05 +00:00
Julia Lavrova
0c1f6e5dab Implementing baseline shift for JetBrains
Bug: skia:12390
Change-Id: I90d99e1ca18c1274ac53ab35a3f63b716d26cb5d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/457097
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-10-12 14:35:33 +00:00
John Stiles
13c9f6690e Fix additional cases of variable shadowing.
These changes will allow us to enable shadowed-variable warnings.

Change-Id: I24ee7e198c1c77b58836237c37557c00452680e1
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/439476
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Ben Wagner <bungeman@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
2021-08-16 17:47:14 +00:00
Julia Lavrova
8343e003ca SkText: implement select via styles
Change-Id: I047f7fc4027572892433d759f4098f5da9da4662
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/438657
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-08-11 19:49:35 +00:00
John Stiles
1be6cbbb96 Fix cases of variable shadowing in module/.
These were reviewed last year at http://review.skia.org/312480 but never
landed. Splitting into small chunks to land individually.

If we manage to fix all the existing cases of variable shadowing, we
could enable -Wshadow.

Change-Id: If993bfe66969d2278009d3a3aba999467f4ac3a4
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/435719
Commit-Queue: John Stiles <johnstiles@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Auto-Submit: John Stiles <johnstiles@google.com>
Reviewed-by: Julia Lavrova <jlavrova@google.com>
2021-08-02 19:13:02 +00:00
Florin Malita
40f3db41af Reland "Experimental ICU runtime linking"
This is a reland of f4aab0584d

Original change's description:
> Experimental ICU runtime linking
>
> Introduce a build config option where ICU symbols are resolved at
> runtime, against existing system libs.
>
> Change-Id: I2325537438de0063fcc4a7c0f8411764cf550f09
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/431037
> Commit-Queue: Florin Malita <fmalita@chromium.org>
> Commit-Queue: Florin Malita <fmalita@google.com>
> Reviewed-by: Ben Wagner <bungeman@google.com>

Change-Id: I6f67a5eb842743d2486ccc4519e2d8cb9fac3458
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/433277
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
2021-07-27 19:51:31 +00:00
Florin Malita
6cce9615a0 Revert "Experimental ICU runtime linking"
This reverts commit f4aab0584d.

Reason for revert: build failures

Original change's description:
> Experimental ICU runtime linking
>
> Introduce a build config option where ICU symbols are resolved at
> runtime, against existing system libs.
>
> Change-Id: I2325537438de0063fcc4a7c0f8411764cf550f09
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/431037
> Commit-Queue: Florin Malita <fmalita@chromium.org>
> Commit-Queue: Florin Malita <fmalita@google.com>
> Reviewed-by: Ben Wagner <bungeman@google.com>

TBR=djsollen@google.com,bungeman@google.com,fmalita@chromium.org,fmalita@google.com,jlavrova@google.com,skcq-be@skia-corp.google.com.iam.gserviceaccount.com

Change-Id: Ic252af1d7ba0a72b3c596e61f86746c27a0685b7
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/433276
Reviewed-by: Florin Malita <fmalita@google.com>
Commit-Queue: Florin Malita <fmalita@google.com>
2021-07-27 12:13:39 +00:00
Florin Malita
f4aab0584d Experimental ICU runtime linking
Introduce a build config option where ICU symbols are resolved at
runtime, against existing system libs.

Change-Id: I2325537438de0063fcc4a7c0f8411764cf550f09
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/431037
Commit-Queue: Florin Malita <fmalita@chromium.org>
Commit-Queue: Florin Malita <fmalita@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-07-26 21:18:17 +00:00
Julia Lavrova
fb4d380747 Wrong line metrics in case of a force text wrapping
Change-Id: I8fb6530c46ba8fb7f6fa2894227193ca6a9e391b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/430220
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-07-20 17:22:40 +00:00
John Stiles
55f0d7acfa Always enforce format specifiers on SkDebugf.
Change-Id: Icba60060ab4dec45c8ef1b1e2f35056626adc0a7
Bug: skia:12143, 192062380
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/428616
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Derek Sollenberger <djsollen@google.com>
2021-07-15 20:11:24 +00:00
Julia Lavrova
3a44eb92e9 Apparently, line metrics should not include newlines
(Flutter doc is wrong)
Bug: skia:12127

Change-Id: I422a870d3cf6346cf8b37834fe89c846f804e236
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/423586
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-07-13 17:16:23 +00:00
Julia Lavrova
f3ee264564 Count trailing spaces when calculating glyph position
Bug: skia:12126
Change-Id: I1431ef3e63f8f07785a39887fa4ac6f60685c549
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/423636
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-07-13 14:54:13 +00:00
John Stiles
7bf799956d Reland "Add format-specifier warnings to SkDebugf."
This is a reland of e58831cd95

Original change's description:
> Add format-specifier warnings to SkDebugf.
>
> This CL fixes up many existing format-specifier violations in Skia.
> Note that GCC has a warning for formatting nothing, so existing calls to
> `SkDebugf("")` have been removed, or replaced with `SkDebugf("%s", "")`.
> These were apparently meant to be used as a place to set a breakpoint.
>
> Some of our clients also use SkDebug with bad format specifiers, so this
> check is currently only enabled when SKIA_IMPLEMENTATION is true.
>
> Change-Id: I8177a1298a624c6936adc24e0d8f481362a356d0
> Bug: skia:12143
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/420902
> Auto-Submit: John Stiles <johnstiles@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

Bug: skia:12143
Change-Id: Id3c0c21436ebd13899908d5ed5d44c42a0e23921
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/421918
Commit-Queue: John Stiles <johnstiles@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-06-25 17:57:43 +00:00
Tyler Denniston
283dba5785 Revert "Add format-specifier warnings to SkDebugf."
This reverts commit e58831cd95.

Reason for revert: looks like breaking a few build bots

Original change's description:
> Add format-specifier warnings to SkDebugf.
>
> This CL fixes up many existing format-specifier violations in Skia.
> Note that GCC has a warning for formatting nothing, so existing calls to
> `SkDebugf("")` have been removed, or replaced with `SkDebugf("%s", "")`.
> These were apparently meant to be used as a place to set a breakpoint.
>
> Some of our clients also use SkDebug with bad format specifiers, so this
> check is currently only enabled when SKIA_IMPLEMENTATION is true.
>
> Change-Id: I8177a1298a624c6936adc24e0d8f481362a356d0
> Bug: skia:12143
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/420902
> Auto-Submit: John Stiles <johnstiles@google.com>
> Commit-Queue: Brian Osman <brianosman@google.com>
> Reviewed-by: Brian Osman <brianosman@google.com>

TBR=brianosman@google.com,ethannicholas@google.com,johnstiles@google.com

Change-Id: I07848c1bf8992925c9498e916744d0840355a077
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:12143
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/421917
Reviewed-by: Tyler Denniston <tdenniston@google.com>
Commit-Queue: Tyler Denniston <tdenniston@google.com>
2021-06-25 13:33:10 +00:00
John Stiles
e58831cd95 Add format-specifier warnings to SkDebugf.
This CL fixes up many existing format-specifier violations in Skia.
Note that GCC has a warning for formatting nothing, so existing calls to
`SkDebugf("")` have been removed, or replaced with `SkDebugf("%s", "")`.
These were apparently meant to be used as a place to set a breakpoint.

Some of our clients also use SkDebug with bad format specifiers, so this
check is currently only enabled when SKIA_IMPLEMENTATION is true.

Change-Id: I8177a1298a624c6936adc24e0d8f481362a356d0
Bug: skia:12143
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/420902
Auto-Submit: John Stiles <johnstiles@google.com>
Commit-Queue: Brian Osman <brianosman@google.com>
Reviewed-by: Brian Osman <brianosman@google.com>
2021-06-25 11:05:59 +00:00
Mike Reed
a46fe7d587 Return shapedlines for text api
Change-Id: I8f9aa6e0cffb3441706bd0efeb0886209cac012a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/403256
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Mike Reed <reed@google.com>
2021-05-03 14:21:11 +00:00
Julia Lavrova
b2a2e7c9e3 Empty paragraph height in case of HeightOverride
bug: skia:11920
Change-Id: I65caa14b775d49680f140b3b70e64bf03f6dfffb
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/402277
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-04-28 20:08:36 +00:00
Mike Reed
9eaae183ab An attempt to fix the last glyph position problem
Change-Id: I5d3eed412df024b93457a0f4e0ca0d13bc250e46
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/401919
Reviewed-by: Mike Reed <reed@google.com>
2021-04-28 00:48:45 +00:00
Julia Lavrova
db10b0e802 Float error and positioning
(Hiding the fix from Flutter for now because we need to test it in
Google3 first)

Bug: skia:11100
Change-Id: I51fa37ee16a48de6a636dc857d5ae8650327922f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/391197
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-04-05 19:00:46 +00:00
Julia Lavrova
141b0aec13 Ignore \n metrics so it does not affect the layout
Bug: skia:11370
Change-Id: I17bf1304750be2c98f037bb8aebd65c525d836de
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/388445
Reviewed-by: Herb Derby <herb@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-04-01 16:25:33 +00:00
Julia Lavrova
2381c0b420 Handle the case when one grapheme includes more than one run.
Bug: skia:11743
Change-Id: Id53350845254905be1c5fcb0c2b1f757f5b6319f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/389930
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-03-30 19:58:16 +00:00
Julia Lavrova
5625ef5043 Too long placeholder should start from a new line
Bug: skia:11783
Change-Id: Ide5f0976bc20ababb483ddd10d2f081ad3d13a86
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/388138
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-03-23 14:53:28 +00:00
Julia Lavrova
583a343d9a Line height in case of a single placeholder
Bug: skia:11773
Change-Id: I6f5ff4afa5600d76c973669b35c182f385b6cf7a
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/387818
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-03-22 19:21:48 +00:00
Julia Lavrova
6147424288 Correct the line height
Bug: skia:11370
Change-Id: I72b4a53924d310a907d1851a56f3137dbca1cf6d
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/386859
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-03-19 18:26:12 +00:00
Julia Lavrova
98a76eb6ea Add nbsp info to the cache
Change-Id: I9d4cd6f3d7c2871c1279c3a7190187bbfee1b56b
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/383856
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-03-19 15:40:31 +00:00
Julia Lavrova
c70f8c331d Using non-breaking spaces as a hint to break too long words
Change-Id: Ic88e961ea3fb08e61340895115f514c6f5dec163
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/379798
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-03-08 04:31:04 +00:00
Julia Lavrova
b7b9a23281 Treat control codepoints as resolved
The correct solution will be implemented to fix bug 11380.
https://bugs.chromium.org/p/skia/issues/detail?id=11380

Bug: skia:11370
Change-Id: I15a84e2e785d73a298558e5ef0dedcc69f7b6eef
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/376936
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-03-02 20:38:48 +00:00
Julia Lavrova
8d5ccce163 Glyph positioning in RTL empty lines
Bug: skia:11258
Change-Id: Icbb34e571ba53e893b2887c963a46677b16b43e0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/368754
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-02-10 22:27:18 +00:00
Julia Lavrova
f756979dbf Fixing a crash in Flutter Text Editor
Change-Id: I01b92f7c5f6030afae164ba2999e3aa8168597b0
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/368417
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-02-09 22:10:55 +00:00
Julia Lavrova
efae4d56e1 Glyph positions in empty lines (few places had to be fixed)
Bug: skia:11259
Change-Id: I6aa24f9f1f95698d39dbc2ae0e6836f404fd0b24
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/365491
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-02-03 23:05:38 +00:00
Julia Lavrova
045f87d27f Reasonable results for not styled text in findAllBlocks.
Bug: skia:11256
Change-Id: Ice964f722c3c9f15cf3feab3c74b1c7235bbea7f
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/364636
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2021-02-03 14:40:09 +00:00
Julia Lavrova
d20a1097e8 Round unresolved font blocks to grapheme edges
I had to stage the change with SK_PARAGRAPH_GRAPHEME_EDGES because of
some google3 tests.
Bug: skia:11196

Change-Id: Ic45e43e6c69f649c6bc0fedcc6f303891139b85e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/359566
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2021-01-27 15:39:09 +00:00
Julia Lavrova
b42686ad01 Painting styled text blocks in RTL
Bug: skia:11017
Change-Id: I13bd210a0d38614bab4a5a98c4507150043224cc
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/340317
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-12-03 21:51:40 +00:00
Julia Lavrova
c90084a9a3 Revert "Some testing images in Google3 look slightly different with this change. Need to change them, too."
This reverts commit b776a105e5.

Reason for revert: This will be the first step of a staged change.

Original change's description:
> Some testing images in Google3 look slightly different with this change. Need to change them, too.
>
> Revert "Roll back #10487 fix (so now spaces always resolved in the main font)"
>
> This reverts commit ff5d8700b3.
>
> Reason for revert: <INSERT REASONING HERE>
>
> Original change's description:
> > Roll back #10487 fix (so now spaces always resolved in the main font)
> >
> > Bug: skia:10715
> > Change-Id: I06bb881998d00228c79a218967eda6468cbc5bed
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334053
> > Reviewed-by: Ben Wagner <bungeman@google.com>
> > Commit-Queue: Julia Lavrova <jlavrova@google.com>
>
> TBR=bungeman@google.com,jlavrova@google.com
>
> Change-Id: Icc1f262f60fa2ec9b4425ce3088b5eaac9313374
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Bug: skia:10715
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334158
> Reviewed-by: Julia Lavrova <jlavrova@google.com>
> Commit-Queue: Julia Lavrova <jlavrova@google.com>

TBR=bungeman@google.com,jlavrova@google.com

Change-Id: I0f2f46fc21eec795026ea98696f68112915f7979
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10715
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334159
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2020-11-12 15:32:48 +00:00
Julia Lavrova
b776a105e5 Some testing images in Google3 look slightly different with this change. Need to change them, too.
Revert "Roll back #10487 fix (so now spaces always resolved in the main font)"

This reverts commit ff5d8700b3.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> Roll back #10487 fix (so now spaces always resolved in the main font)
>
> Bug: skia:10715
> Change-Id: I06bb881998d00228c79a218967eda6468cbc5bed
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334053
> Reviewed-by: Ben Wagner <bungeman@google.com>
> Commit-Queue: Julia Lavrova <jlavrova@google.com>

TBR=bungeman@google.com,jlavrova@google.com

Change-Id: Icc1f262f60fa2ec9b4425ce3088b5eaac9313374
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: skia:10715
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334158
Reviewed-by: Julia Lavrova <jlavrova@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-11-11 20:47:16 +00:00
Julia Lavrova
ff5d8700b3 Roll back #10487 fix (so now spaces always resolved in the main font)
Bug: skia:10715
Change-Id: I06bb881998d00228c79a218967eda6468cbc5bed
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/334053
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-11-11 18:11:25 +00:00
Julia Lavrova
1d1c5c1a18 Yet another workaround Thai \n problem (same as txtlib)
Bug: skia:10881

Change-Id: If451b662646e66e5d699ca0cca3795f5e078b84e
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/332257
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-11-06 19:33:39 +00:00
Julia Lavrova
f857a87d64 Underline decorations with gaps and no text
Bug: Skia:10822
Change-Id: I5ab2f743fe2837070065954bc6f5ba930292f0c8
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/328596
Commit-Queue: Julia Lavrova <jlavrova@google.com>
Reviewed-by: Ben Wagner <bungeman@google.com>
2020-10-21 19:43:33 +00:00
Julia Lavrova
1b44330169 Placeholder at the end of the text right before \n.
Bug: skia:10838
Change-Id: I0f6ebe442d67ba4c91cbef4fcaec6dea02739d34
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/327339
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-10-15 19:15:16 +00:00
Julia Lavrova
69f3cab837 Changing the way we select a grapheme
Selecting only graphemes that are fully inside the
[start:end) range. Hopefully, it's a temporary
solution to simplify SkParagraph vs TxtLib comparison.

Change-Id: Iebc74fb4ae20c232bfae762a04e45f0979cf6236
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/322438
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-10-08 19:02:12 +00:00
Julia Lavrova
b6b7fffc35 Reland "Removing ICU dependencies from skparagraph BUILD.gn file"
This reverts commit 05ce2817f2.

Reason for revert: Fixing the build

Original change's description:
> Revert "Removing ICU dependencies from skparagraph BUILD.gn file"
>
> This reverts commit f1711adb1a.
>
> Reason for revert: Build break
>
> Original change's description:
> > Removing ICU dependencies from skparagraph BUILD.gn file
> >
> > (and from the sources, too)
> >
> > Change-Id: I9d8ff51c91aad4b770b1f183c04734d31252b851
> > Reviewed-on: https://skia-review.googlesource.com/c/skia/+/313148
> > Commit-Queue: Julia Lavrova <jlavrova@google.com>
> > Reviewed-by: Ben Wagner <bungeman@google.com>
>
> TBR=bungeman@google.com,jlavrova@google.com
>
> Change-Id: I1fce2436855e3e2a4cb7d1d7204b3ae49fd530e8
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://skia-review.googlesource.com/c/skia/+/314540
> Reviewed-by: Julia Lavrova <jlavrova@google.com>
> Commit-Queue: Julia Lavrova <jlavrova@google.com>

TBR=bungeman@google.com,jlavrova@google.com

Change-Id: I13d78d75698df47930adc2514d1328abc556a209
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/316444
Reviewed-by: Kevin Lubick <kjlubick@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-09-11 18:31:24 +00:00
Julia Lavrova
0f64e0dfd8 An attempt to make font resolution more predictable.
In case the default font family is not there.
Bug: skia:10701

Change-Id: Ie1155d820bfcc25870bedcd0310b0e779d55e942
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/316087
Reviewed-by: Ben Wagner <bungeman@google.com>
Commit-Queue: Julia Lavrova <jlavrova@google.com>
2020-09-10 20:35:11 +00:00