1. 14 3月, 2017 1 次提交
    • S
      Make SparseBitSet serializable. · fbbc5a6b
      Seigo Nonaka 提交于
      To share the calculated coverage information across the processes, make
      SparseBitSet serializable.
      
      Bug: 34042446
      Test: minikin_tests passes
      Change-Id: I0463138adcf234739bb3ce1cdadf382021921f3e
      fbbc5a6b
  2. 07 3月, 2017 1 次提交
    • R
      Customizable min suffix/prefix length for hyphenation in Minikin · d78f260a
      Roozbeh Pournader 提交于
      With this change, different languages can have a different minimum
      length for suffix and prefixes when hyphenating. Previously, the
      defaults used for English, 2 and 3, were used for every language.
      
      Bug: 35712376
      Test: Minikin unit tests were updated and the pass
      Change-Id: Iffaf11c6b208c57d28d45b17246e177572dc1210
      d78f260a
  3. 03 3月, 2017 1 次提交
    • R
      Correct hyphenation for various complex cases · c7ef4000
      Roozbeh Pournader 提交于
      This adds better support for Arabic script languages, Armenian,
      Catalan, Hebrew, Kannada, Malayalam, Polish, Tamil, and Telugu by
      adding various hyphenation types and edits appropriate for the
      locales.
      
      For Arabic script languages, soft hyphens act transparently with
      regard to joining: If a line is broken at a soft hyphen where the two
      characters around the soft hyphen were joining each other before,
      they will continue to appear joining if the line is broken at the
      soft hyphen and a hyphen glyph is inserted.  This is needed for
      Central Asian languages such as Uighur.
      
      For Armenian, U+058A ARMENIAN HYPHEN is used for line breaks caused
      by either automatic hyphenation or soft hyphens.
      
      For Catalan, nonstandard line breaks are implemented for "l·l", which
      hyphenates as "l-/l".
      
      For Polish, when there is a line break at a hyphen, the hyphen is
      repeated at the next line.
      
      For the South Indic languages, when breaks happen due to soft breaks
      or automatic hyphenation, no visible hyphen is inserted, although a
      penalty is added.
      
      For Hebrew, support for using U+05BE HEBREW PUNCTUATION MAQAF has
      been implemented, but it's turned off pending confirmation of
      desirability.
      
      Also, hard hyphens, which previously had no penalty added for
      breaking the line after them, now have the same penalty as an
      automatic or soft break, with the difference that no hyphen is
      inserted when they break.
      
      Finally, some bugs have been fixed with hyphenating multiscript and
      multi-font words.
      
      Bug: 19950445
      Bug: 19955011
      Bug: 25623243
      Bug: 26154469
      Bug: 26154471
      Bug: 33387871
      Bug: 33560754
      Bug: 33752592
      Bug: 33754204
      Test: Unit tests added, plus thorough manual testing
      Change-Id: Iaccf776ce8d1d434ee8b1c534ff3659d80fdc338
      c7ef4000
  4. 24 2月, 2017 1 次提交
    • S
      Remove MinikinRefCounted and use shared_ptr instead · dfbc6e37
      Seigo Nonaka 提交于
      Let's use shared_ptr since manual ref counting can be a bug-prone and
      using the global mutex inside destructor is not useful for some time.
      
      To remove raw pointer manipulation, needed to change Layout
      constructors. Layout is no longer copyable and need to pass
      FontCollection to constructor.
      
      Bug: 28119474
      Test: minikin_tests passed
      Test: hwui_unit_tests passed
      Test: No performance regression in minikin_perftest.
      Change-Id: I8824593206ecba74cbc9731e298f045e1ae442a3
      dfbc6e37
  5. 22 2月, 2017 1 次提交
  6. 15 2月, 2017 1 次提交
    • S
      Pass region code to HarfBuzz. · 22462be7
      Seigo Nonaka 提交于
      Keep the region code and pass it to HarfBuzz during doing layout.
      
      Test: minikin_tests
      Bug: 30746293
      Change-Id: I7c908701ca677238f663c82c597f8615d190e055
      22462be7
  7. 08 2月, 2017 1 次提交
    • S
      Introduce unittests for flag sequence. · e05034f3
      Seigo Nonaka 提交于
      The Flag sequence is well handled by latest ICU.
      Just add unit tests for catching regression in future.
      
      Test: ran minikin_tests
      Change-Id: I78d5461de8ff4d002ca06fb5bb81fcd7bc45d95e
      e05034f3
  8. 07 2月, 2017 1 次提交
    • S
      Update the instruction to run tests. · f980baa2
      Seigo Nonaka 提交于
      "adb sync data" pushes test data as well as test executables.
      
      Test: ran minikin_perftests
      Test: ran minikin_tests
      Change-Id: I08219f8abc4b59bd26d8f9155975b65b56a88b7b
      f980baa2
  9. 31 1月, 2017 1 次提交
    • S
      Introduce createCollectionWithVariation. · 065c46a6
      Seigo Nonaka 提交于
      This is 2nd attempt of I08e9b74192f8af1d045f1276498fa4e60d73863e.
      The original CL was reverted due to conflicting with another CL submitted
      before.
      
      Here is the original commit message of reverted change.
      
      This lays the groundwork for variation settings support.
      Since we should regard different variations of a font as different fonts, we
      need to create new typefaces. To reuse the same instance of MinikinFont, as
      much as possible, FontFamily::createFamilyWithVariation now reuses an
      existence instance, while incrementing the reference count.
      
      Test: minikin_tests
      Bug: 33062398
      Change-Id: Ib25bf1bb5a5191e15a6523954146521464c91906
      065c46a6
  10. 20 1月, 2017 3 次提交
    • S
      Remove FontFamily.addFont and make FontFamily immutable. · 41718c77
      Seigo Nonaka 提交于
      This is 2nd attempt of 41e02e96
      The difference is adding clearElementsEithLock to Font class which
      is necessary to delete Fonts object outside of minikin. This method
      should be removed once http://b/28119474 is fixed.
      
      Here is original commit message of reverted change.
      
      This lays the groundwork for making SparseBitSet serializable.
      FontFamily.addFont is only used when the FontFamily is constructed.
      Thus, instead of calling FontFamily.addFont multiple time, passes
      Font list to the constructor. By this change, FontFamily can be
      immutable now.
      
      By making FontFamily immutable, We can create FontFamily with
      pre-calculated SparseBitSet.
      
      Bug: 34042446
      Bug: 28119474
      Bug: 34378805
      Test: minikin_tests has passed
      Change-Id: Ice433931196f5ae79a1a7ee0c98020f914aeb5f2
      41718c77
    • S
      Revert "Remove FontFamily.addFont and make FontFamily immutable." · cc0352cc
      Siyamed Sinir 提交于
      This reverts commit 41e02e96.
      
      Bug: 34378805
      Change-Id: I8f1ee00b365c8b17c6140e9e286fbea082e31364
      cc0352cc
    • S
      Revert "Introduce createCollectionWithVariation." · 1c7b0261
      Siyamed Sinir 提交于
      This reverts commit 90e6b188.
      
      Bug: 34378805
      Change-Id: I22b683f774813724f220b1b8584ab188f3cf4fa7
      1c7b0261
  11. 12 1月, 2017 2 次提交
    • S
      Introduce createCollectionWithVariation. · 90e6b188
      Seigo Nonaka 提交于
      This lays the groundwork for variation settings support.
      Since we should regard different variations of a font as different fonts, we
      need to create new typefaces. To reuse the same instance of MinikinFont, as
      much as possible, FontFamily::createFamilyWithVariation now reuses an
      existence instance, while incrementing the reference count.
      
      Test: minikin_tests
      Bug: 33062398
      Change-Id: I08e9b74192f8af1d045f1276498fa4e60d73863e
      90e6b188
    • S
      Remove FontFamily.addFont and make FontFamily immutable. · 41e02e96
      Seigo Nonaka 提交于
      This lays the groundwork for making SparseBitSet serializable.
      FontFamily.addFont is only used when the FontFamily is constructed.
      Thus, instead of calling FontFamily.addFont multiple time, passes
      Font list to the constructor. By this change, FontFamily can be
      immutable now.
      
      By making FontFamily immutable, We can create FontFamily with
      pre-calculated SparseBitSet.
      
      Bug: 34042446
      Test: minikin_tests has passed
      Change-Id: I2576789fba6cb27687e920e2488e8bedbcf7d36f
      41e02e96
  12. 10 1月, 2017 1 次提交
  13. 28 12月, 2016 1 次提交
    • M
      minikin: Replace cutils/log.h with android/log.h or log/log.h · 555d84c6
      Mark Salyzyn 提交于
      - replace cutils/log.h with android/log.h (main buffer logging)
      - replace cutils/log.h with log.log.h (+SafetyNet logging)
      - define LOG_TAG before use.
      
      Test: compile
      Bug: 26552300
      Bug: 31289077
      Change-Id: I7a4803dd66f31b7103e09e5ff5b8fa523fa0fd60
      555d84c6
  14. 16 12月, 2016 1 次提交
    • D
      Use LOCAL_TEST_DATA to install test data · 068eab8f
      Dan Willemsen 提交于
      This will handle installation for local builds as well as for the test
      bundles.
      
      Test: m -j minikin_tests; ls $OUT/data/nativetest*/minikin_tests
      Test: m -j continous_native_tests dist; zipinfo -1 out/dist/*continuous_native_tests*.zip
      Test: /data/nativetest{,64}/minikin_tests/minikin_tests
      Change-Id: Iafd31fa119e7c4d92937ca8ae8346e268a6c1f38
      Merged-In: Iafd31fa119e7c4d92937ca8ae8346e268a6c1f38
      068eab8f
  15. 14 12月, 2016 1 次提交
    • D
      Use LOCAL_TEST_DATA to install test data · 549e2315
      Dan Willemsen 提交于
      This will handle installation for local builds as well as for the test
      bundles.
      
      Test: m -j minikin_tests; ls $OUT/data/nativetest*/minikin_tests
      Test: m -j continous_native_tests dist; zipinfo -1 out/dist/*continuous_native_tests*.zip
      Test: /data/nativetest{,64}/minikin_tests/minikin_tests
      Change-Id: Iafd31fa119e7c4d92937ca8ae8346e268a6c1f38
      549e2315
  16. 06 12月, 2016 1 次提交
    • Y
      Change language score calculation · d478da32
      Yirui Huang 提交于
      Change language score calculation in the calculation of the font family.
      Instead of language and script matching, a match in subtag is added.
      In addition, a match in subtag has a higher priority than a match in
      script. The score levels are divided into 5 score levels and the limit
      of the number of font languages is changed to 12 from 17. Multiple
      languages selection rule could to be added in the future.
      
      Bug: 31608997
      Test: Done by unittests.
      Change-Id: I1e7177095f604fd1794bc99ca36c705dcb4c56e7
      d478da32
  17. 03 12月, 2016 1 次提交
    • C
      Move LOCAL_PICKUP_FILES out of $OUT/data · 2e621342
      Colin Cross 提交于
      minikin_tests was copying its test data to
      $OUT/data/DATA/nativetest/minikin_test, and then packaging that with
      LOCAL_PICKUP_FILES=$OUT/data/DATA, which would also pick up anything
      any other module copyied to $OUT/data/DATA.  $OUT/data/DATA isn't
      where the tests expect to find their data, they look in
      /data/nativetest/minikin_test.  Copy the files to the intermediates
      directory instead.
      
      A future change will install LOCAL_PICKUP_FILES for local builds
      to the correct place, so adb sync and
      adb shell /data/nativetest/minikin_tests/minikin_tests will run the
      tests.
      
      Test: mma -j
      Change-Id: I808ce743f51e5ccac711e22821e7e0d7cd94ffdf
      2e621342
  18. 21 11月, 2016 1 次提交
    • Y
      Parse Emoji subtag and store it to FontLanguage · e1d7f616
      yirui 提交于
      Parse Emoji subtag and store into 4 different styles: default, text,
      color and empty. Replace hasEmojiFlag function with getEmojiStyle to
      get effective status according to script and subtag. However, score
      calculation for the font selection needs to be completed in the next
      stage. No performance regression is observed with this CL.
      
      Bug: 31608997
      Test: Done by unittests.
      Change-Id: I923243641c946248dd5a0aa9fb9c940515310d34
      e1d7f616
  19. 17 11月, 2016 1 次提交
    • S
      Clean Up: Removing unused interface GetTable from MinikinFont. · fd77b01f
      Seigo Nonaka 提交于
      This is 2nd attempt of Ifcd7a348d7fb5af081192899dbcdfc7fb4eebbf9
      
      After Id766ab16a8d342bf7322a90e076e801271d527d4, GetTable is no longer
      used in production due to poor performance and it is now only used in
      tests. This CL removes GetTable interface from MinikinFont and update
      tests code to use new interfaces, GetFontData, GetFontSize and
      GetFontIndex.
      
      Bug: 27860101
      Test: Manually done
      Change-Id: Ib48973ff25cdc61a4c666d28128266df0aaea83e
      fd77b01f
  20. 16 11月, 2016 2 次提交
    • M
      Fix calls to deprecated range_x. · 815bc4a8
      Martijn Coenen 提交于
      Test: fixes master build.
      Change-Id: I8b2822d310c0cf423b15834e6d6ae3a9ea64233b
      815bc4a8
    • S
      Implement word spacing · acd401d0
      Seigo Nonaka 提交于
      Add a wordSpacing paint parameter, which will be used for
      justification.
      
      Bug: 31707212
      Test: ran minikin_tests
      Change-Id: I91224ab8ef882ac0c87425c28ab731fead283612
      acd401d0
  21. 25 10月, 2016 1 次提交
  22. 18 10月, 2016 1 次提交
    • S
      Clean Up: Removing unused interface GetTable from MinikinFont. · 1d525df4
      Seigo Nonaka 提交于
      After Id766ab16a8d342bf7322a90e076e801271d527d4, GetTable is no longer
      used in production due to poor performance and it is now only used in
      tests. This CL removes GetTable interface from MinikinFont and update
      tests code to use new interfaces, GetFontData, GetFontSize and
      GetFontIndex.
      
      Bug: 27860101
      Test: Manually done
      
      Change-Id: Ifcd7a348d7fb5af081192899dbcdfc7fb4eebbf9
      1d525df4
  23. 15 9月, 2016 1 次提交
    • S
      Fix lookup order for VS in itemization. · 4a4e6574
      Seigo Nonaka 提交于
      This is partial revert of Iced1349e3ca750821d8882c551551f65bb569794.
      
      Due to sorting of target family vectors, the font family order from XML
      settings file is broken. Making unique operation stable doesn't fix the
      issue completely since some font families are appended for the fallback
      which also breaks the original order.
      
      By this change, itemization becomes 3x slower than before if variation
      selector is appended.
      
      Bug: 29585939
      Change-Id: I7c1a8a57f04111a30cd41a5cd5bec25fcfb3972e
      4a4e6574
  24. 12 8月, 2016 1 次提交
  25. 06 8月, 2016 1 次提交
    • B
      Move SkTypeface::CreateXXX to SkTypeface::MakeXXX. · e6adb66a
      Ben Wagner 提交于
      Skia is moving to returning smart pointers from its factory methods.
      This updates uses of SkTypeface::CreateXXX to SkTypeface::MakeXXX and
      generally updates use of SkTypeface to sk_sp. This will allow for the
      removal of the SK_SUPPORT_LEGACY_TYPEFACE_PTR define.
      
      Change-Id: If3e600c6cb86080576667bc77d427da4f6560afa
      e6adb66a
  26. 14 7月, 2016 3 次提交
    • S
      Lookup glyph from color emoji font before and after ZWJ. · 9431bb96
      Seigo Nonaka 提交于
      Unicode recommends that the zwj sequences should be emoji presentation
      even if they don't have the proper U+FE0F. Thus always lookup the glyph
      for the code point before and after zwj as if they have a U+FE0F
      variation selector.
      
      Bug: 30056627
      Change-Id: I03958a92337eaba4a8dd9c5be824b2665aa4a103
      9431bb96
    • S
      Treat U+2695, U+2640, U+2642 as emoji characters. · c2642f9a
      Seigo Nonaka 提交于
      Bug: 29885295
      Change-Id: I1bf191a46d05e7099265d863bae0523c50817d0b
      c2642f9a
    • S
      Add some gender balanced components in to the sticky whitelist. · fab99dde
      Seigo Nonaka 提交于
      FEMALE SIGN(U+2640), MALE SIGN(U+2642), StAFF OF AESCULAPIUS(U+2695)
      will be used as the ZWJ sequenced in gender balanced emoji sequence.
      To be in the same run with ZWJ, mark these emoji as sticky chracters.
      
      With this fix, Female police officer sequence will be shown correctly
      regardless of VS16.
      
      Bug: 30026374
      Change-Id: I503fc061eaa943d45208bb69e885151610c430ce
      fab99dde
  27. 12 7月, 2016 1 次提交
    • S
      Lookup glyph from color emoji font before and after ZWJ. · 98487de5
      Seigo Nonaka 提交于
      Unicode recommends that the zwj sequences should be emoji presentation
      even if they don't have the proper U+FE0F. Thus always lookup the glyph
      for the code point before and after zwj as if they have a U+FE0F
      variation selector.
      
      Bug: 30056627
      Change-Id: I03958a92337eaba4a8dd9c5be824b2665aa4a103
      98487de5
  28. 11 7月, 2016 1 次提交
  29. 08 7月, 2016 1 次提交
    • S
      Add some gender balanced components in to the sticky whitelist. · 435076ff
      Seigo Nonaka 提交于
      FEMALE SIGN(U+2640), MALE SIGN(U+2642), StAFF OF AESCULAPIUS(U+2695)
      will be used as the ZWJ sequenced in gender balanced emoji sequence.
      To be in the same run with ZWJ, mark these emoji as sticky chracters.
      
      With this fix, Female police officer sequence will be shown correctly
      regardless of VS16.
      
      Bug: 30026374
      Change-Id: I503fc061eaa943d45208bb69e885151610c430ce
      435076ff
  30. 28 6月, 2016 3 次提交
    • S
      Fix build failure of minikin_perftest · 524369b0
      Seigo Nonaka 提交于
      stat.st_size is off_t not size_t, so need to cast to size_t before
      compare it.
      
      Change-Id: I6b742746fbb9f254701fc91e515c293f93f912c5
      524369b0
    • S
      Introduce FontCollection perftest · 5e6bc85d
      Seigo Nonaka 提交于
      This CL introduces performance tests for FontCollection.
      
      To support TTC file in /system/fonts, this CL also extends FontTestUtils
      
      Bug:29142734
      Change-Id: I9d8ad24ca55f61031b85623ab7c26234239e4f41
      5e6bc85d
    • S
      Add more native perf tests to minikin. · 0ca4fb6d
      Seigo Nonaka 提交于
      This CL introduces performance tests for following three modules:
      - Hyphenator
      - WordBreaker
      - GraphemeBreak
      
      During using UnicodeUtils, need to decouple it from gtest since
      perftest doesn't have gtest dependencies.
      
      Bug:29142734
      Change-Id: I700c662fa7d0a52f19d8e93150ad1a85dc28769f
      0ca4fb6d
  31. 21 6月, 2016 1 次提交
    • S
      Fix test utilities · 81c79d6e
      Seigo Nonaka 提交于
      This fixes following three memory leaks in test utilities.
      There is no problem in production code and this CL doesn't affect
      any production behaviors.
      
      - SkTypeface leaks due to forget calling SkSafeUnref in dtor.
      - MinikinFontForTest leaks during constructing FontCollection.
      - FontCollection leaks due to unnecessary AddRef.
      
      Change-Id: I22e1e0307f1b2499296acb1aacc3ef66076a36e9
      81c79d6e
  32. 10 6月, 2016 1 次提交
    • S
      Always use minikin namespace. · 14e2d136
      Seigo Nonaka 提交于
      Here is a new policy of the namespace of minikin.
      - All components should be in minikin namespace.
      - All tests are also in minikin namespace and no anonymous namespace.
      
      Bug: 29233740
      Change-Id: I71a8a35049bb8d624f7a78797231e90fed1e2b8c
      14e2d136