Commit Graph

94 Commits

Author SHA1 Message Date
Jonathan Kew
2e91c61468 Bug 1377328 - part 2 - Annotate raw pointers used for refcounted objects in font-related code. r=milan 2017-06-29 17:52:43 -07:00
Jonathan Kew
4ea7df6c56 Bug 1377328 - part 1 - Annotate some font-related helper classes as MOZ_STACK_CLASS. r=milan 2017-06-29 17:52:38 -07:00
Jonathan Kew
5133782794 Bug 1364224 - Reduce refcount churn on gfxFont by using raw pointers where no strong ownership is needed. r=jrmuizel 2017-06-29 15:37:52 -07:00
Ryan Hunt
cfc792bc4c Bug 1351783 part 1 - Add includes for unified build issues. r=kats
MozReview-Commit-ID: D57bbW4pmPZ

--HG--
extra : rebase_source : 9af2973a112c7ea641876c1f945797f2c7c945ce
2017-06-05 18:03:02 -05:00
Jonathan Kew
fd5dc7dd5e Bug 1364089 - Eliminate some unnecessary virtual calls in gfxFont-related code. r=jrmuizel 2017-06-01 15:42:07 +01:00
Jonathan Kew
b1d22b8fd2 Bug 734008 - DeCOMtaminate nsILanguageAtomService, make it a non-refcounted singleton and clean up various call sites. r=m_kato 2015-04-03 21:39:23 +02:00
Jonathan Kew
4b5525bbf7 Bug 1362167 - Use strongly-typed enum classes instead of generic uint16_t fields for the gfxShapedText and gfxTextRun flags. r=jrmuizel 2017-05-04 22:27:05 +01:00
Jonathan Kew
6fc5313103 Bug 1362167 - Split gfxShapedText.mFlags into two 16-bit flags fields, and arrange storage more compactly to reduce size of gfxShapedWord and gfxTextRun objects. r=jrmuizel 2017-05-04 22:25:16 +01:00
Jonathan Kew
4a357a8f76 Bug 1361395 - Use ConvertFromGlyphRunArray to implement ResetGlyphRuns. r=jrmuizel 2017-05-04 18:31:28 +01:00
Jonathan Kew
afaf811234 Bug 1360620 - Optimize GlyphRun storage strategy in gfxTextRun, to reduce the overall size of the gfxTextRun object. r=jrmuizel 2017-05-02 11:14:53 +01:00
Jeff Muizelaar
da3210576b Bug 1119128. Eliminate gfxPangoFontGroup and gfxFontconfigUtils. r=lsalzman 2017-03-22 14:58:19 -04:00
Jeremy Chen
9a60f77d80 Bug 1343516 - clean up the mess of PropertyProvider and its implementations. r=jfkthame
The cleanup work includes:

part 1: make all methods 'const' for the abstract class of PropertyProvider.

part 2: make nsFontMetrics's StubPropertyProvider final.

part 3: make nsTextFrame's PropertyProvider final.

  Make some methods 'const' and some variables 'mutable', so we could let all the
  overridden methods stay const.

  We also need to make the pass-in parameter of gfxFontGroup's GetHyphenWidth const.
  Note that the comment of GetHyphenWidth seem outdated, so I fixed it as well.

part 4: make the member variables in nsTextFrame's PropertyProvider to be 'const'.

  Make all the member variables 'const' except mStart, mLength,
  mJustificationArrayStart, and mJustificationSpacings.

  The static function AdvanceToNextTab is fixed since we only use 2 of the 4 parameters.

part 5: coding style fix for nsTextFrame's PropertyProvider.

MozReview-Commit-ID: 1kbWPwx27aQ
2017-03-17 18:53:15 +08:00
Jeremy Chen
0316fede8c Bug 1056516 - let auto hyphen honor manual hyphen when hyphens:auto is set. r=jfkthame
MozReview-Commit-ID: F3ALAJRHned
2017-03-13 12:54:05 +08:00
Jeremy Chen
2e09040e6e Bug 1056516 - use HyphenType to store different types of hyphenations. r=jfkthame
MozReview-Commit-ID: AX3NNDS4hxP
2017-03-13 12:54:05 +08:00
Ryan VanderMeulen
b035220d0f Backed out 5 changesets (bug 1056516) for suspicion of causing Linux/OSX topcrashes.
Backed out changeset 70586dbb509c (bug 1056516)
Backed out changeset 753067cc11f7 (bug 1056516)
Backed out changeset 0bcf5f91b014 (bug 1056516)
Backed out changeset 41d39e1e440b (bug 1056516)
Backed out changeset aaec04f76481 (bug 1056516)
2017-03-10 11:56:50 -05:00
jeremychen@mozilla.com
2cb71eafe4 Bug 1056516 - let auto hyphen honor manual hyphen when hyphens:auto is set. r=jfkthame
MozReview-Commit-ID: BWzg3pb2lDH

--HG--
extra : rebase_source : 069dc3091bf7600d4675fe9ea5d0b41bc70744ba
2017-03-10 00:30:11 +08:00
jeremychen@mozilla.com
f4ac16bb05 Bug 1056516 - use HyphenType to store different types of hyphenations. r=jfkthame
MozReview-Commit-ID: 22ICYSaY1I2

--HG--
extra : rebase_source : 05e0a442dec8a8ac7f1b663808fc016ee3385aa2
2017-03-10 00:30:11 +08:00
Jeremy Chen
213197e5e1 Bug 1328540 - trim trailing whitespaces. r=jeremychen
Trim trailing whitespaces for files that are touched in this bug:

  gfxTextRun.h
  gfxTextRun.cpp
  nsTextFrame.cpp
  nsCSSProps.cpp

MozReview-Commit-ID: FmiW2QiCoFv

--HG--
extra : rebase_source : cbc9ae8c3c4410d1fe79c027d4ccf11b45c8bd19
2017-01-04 23:55:16 +08:00
Jeremy Chen
f735dd2d2c Bug 1328540 - convert NS_STYLE_HYPHENS_* to an enum class. r=xidorn
MozReview-Commit-ID: BwTzbA29Y3H

--HG--
extra : rebase_source : fc07d2c881a8ccc618fd1776d1e977c051b0032f
2017-01-04 23:55:16 +08:00
Jonathan Kew
061ab35e2b Bug 1308502 followup, add missing const-ness to gfxTextRun::SetPotentialLineBreaks param, tidy up a bit. r=m_kato 2016-10-11 13:47:11 +01:00
Jason Woofenden
77865e4a08 Bug 1008019 - Allow whitespace to "hang" at soft-wrap boundaries when white-space:pre-wrap is in effect. r=jfkthame 2016-03-20 17:54:00 -04:00
Ryan VanderMeulen
ce55e7b71a Merge m-c to inbound. a=merge 2016-08-19 09:59:49 -04:00
Mats Palmgren
ddef8b6119 Bug 1280887 - patch 4 - Remove (unused) class gfxTextRun::ClusterIterator. r=jfkthame 2016-08-19 13:14:45 +01:00
Jonathan Kew
95a82f84cc Bug 1280887 - patch 2 - Make gfxTextRun refcounted, replace usage of UniquePtr<> with RefPtr<> for textruns, and make nsTextFrame hold a strong reference to its run(s). r=mats 2016-08-19 13:14:22 +01:00
Jonathan Kew
76f40e7bdc Bug 1280887 - patch 1 - Declare a bunch of gfxTextRun* variables as const pointers, for clarity. r=mats 2016-07-07 13:51:24 +01:00
Xidorn Quan
09f09b5e7b Bug 1288255 - Clear hyphen width cache when user fonts update. r=jfkthame
MozReview-Commit-ID: 66zUQIFafdh

--HG--
extra : rebase_source : c8deb44e0f2eb6de0aedc7041bb79435d18ca354
2016-08-18 11:26:50 +10:00
Jonathan Watt
db80f397f6 Bug 1058040, part 2 - Rename gfxTextContextPaint to SVGContextPaint and add some code comments. r=dholbert 2016-07-22 14:56:09 +01:00
Andi-Bogdan Postelnicu
a40e2399f2 Bug 1282408 - add ignore initialization check flag for variables from GlyphRunIterator. r=jrmuizel
MozReview-Commit-ID: 1KAlxDtZyMe
2016-07-28 11:30:09 +03:00
Kevin Chen
cac9daeb79 Bug 1275693 - Refactor <canvas> strokeText drawing to re-use gfxTextRun::Draw. r=jfkthame 2016-07-14 02:00:00 +02:00
Jonathan Kew
48c59f0c3d Bug 1282248 - Declare a bunch of gfxTextRun measurement/drawing methods and related helpers as const. r=m_kato 2016-06-27 17:41:55 +01:00
Thomas Wisniewski
9b377bb0ef Bug 955857 - Replace CSS word-wrap with overflow-wrap, and add it back as a CSS_PROP_ALIAS. r=dbaron
MozReview-Commit-ID: FiZJvm25rNN

--HG--
extra : rebase_source : c7b16fc302e5c7905beea98353faa960db0a9248
2016-05-23 20:27:21 -04:00
Xidorn Quan
74d7d74ae8 Bug 1275059 followup - Use MOZ_ASSERT for methods of gfxTestRun. r=jfkthame
MozReview-Commit-ID: 9etLeUprAic

--HG--
extra : source : 109f6c2cdf31850a36f8c0cc251e9bbc2bb48606
2016-05-25 09:54:37 +10:00
Jeremy Chen
f7a19af3e7 Bug 1248708 - Part2.2: render -webkit-text-stroke property. r=jfkthame 2016-04-23 01:40:39 +08:00
Jonathan Kew
c60f6a1ae4 Bug 1266391 - Introduce an enum class mozilla::unicode::Script, and use this instead of bare integers to specify script codes for better type checking. r=masayuki 2016-04-21 18:58:59 +01:00
Jonathan Kew
97936698fe Bug 1265648 - Remove the global nsTextFrameTextRunCache, as it no longer serves any useful purpose. r=mats 2016-04-20 10:54:43 +01:00
Jonathan Kew
cb1c20b3c3 Bug 1265459 - Replace uses of nsAutoPtr<gfxTextRun> with UniquePtr, and let MakeTextRun and similar methods return a UniquePtr. r=jrmuizel 2016-04-19 17:13:28 +01:00
Jonathan Kew
28a9e2cf14 Bug 1265452 - Remove use of nsAutoPtr from gfx/thebes. r=jrmuizel 2016-04-15 20:45:37 +01:00
Jonathan Kew
f269e60c82 Bug 1119619 - Allow font-selection to fall back to an alternative face within the same family if the first-found face was not Regular, to handle cases where some styled faces have a reduced character set. r=m_kato 2016-04-14 21:02:12 +01:00
Xidorn Quan
1a5d64446b Bug 1251995 part 3 - Use struct to pass params for gfxTextRun::Draw. r=jfkthame
MozReview-Commit-ID: HAqtS3VXPHH

--HG--
extra : source : e6a45ca0a21666b4e01c217e0bb42772e4dd918f
2016-03-08 15:56:18 +08:00
Xidorn Quan
b3ea3fa801 Bug 1251995 part 2 - Add gfxTextRun::Range to replace parameter pairs like (offset, length) and (start, end). r=jfkthame
Although this makes some places more complicated, code should generally
be simpler and clearer. It could slightly improve performance on x64 for
functions with more than four parameters, since it makes more data be
passed via registers rather than the stack.

MozReview-Commit-ID: D0GM2Jyrr6W

--HG--
extra : source : bd88a2e478e23edf1845f724a32fef908c8cc007
2016-03-08 15:56:18 +08:00
Xidorn Quan
ab357753a9 Bug 1251995 part 1 - Add helper functions to simplify code. r=jfkthame
MozReview-Commit-ID: 6UBvmEpo12f

--HG--
extra : source : d14cafc0e378ab7356c32a0b469ed783244aa48b
2016-03-08 15:56:18 +08:00
Carsten "Tomcat" Book
41a0c1ddb8 Backed out changeset d88221aad093 (bug 1251995) for reftest failures 2016-03-07 12:18:40 +01:00
Carsten "Tomcat" Book
b9f86983b1 Backed out changeset bf004c055beb (bug 1251995) 2016-03-07 12:18:19 +01:00
Carsten "Tomcat" Book
1d0a6281ac Backed out changeset 3f9fbbef0294 (bug 1251995) 2016-03-07 12:18:17 +01:00
Xidorn Quan
11bea4b5a2 Bug 1251995 part 3 - Use struct to pass params for gfxTextRun::Draw. r=jfkthame
MozReview-Commit-ID: HAqtS3VXPHH

--HG--
extra : rebase_source : de01c02d3baf3e8c648d6301bd6ff283d76ae212
2016-02-29 19:06:05 +08:00
Xidorn Quan
8e3206382b Bug 1251995 part 2 - Add gfxTextRun::Range to replace parameter pairs like (offset, length) and (start, end). r=jfkthame
Although this makes some places more complicated, code should generally
be simpler and clearer. It could slightly improve performance on x64 for
functions with more than four parameters, since it makes more data be
passed via registers rather than the stack.

MozReview-Commit-ID: D0GM2Jyrr6W

--HG--
extra : rebase_source : 29961e56b5fe14b244046b3dc52b1f922c206218
2016-02-29 16:50:17 +08:00
Xidorn Quan
5b1f34e2f6 Bug 1251995 part 1 - Add helper functions to simplify code. r=jfkthame
MozReview-Commit-ID: 6UBvmEpo12f

--HG--
extra : rebase_source : e967015366b727f199fe3febedc70f1f43f19725
2016-03-04 19:20:43 +08:00
Birunthan Mohanathas
d7371d07d0 Bug 1235261 - Part 1: Rename nsAutoTArray to AutoTArray. r=froydnj 2016-02-02 17:36:30 +02:00
Phil Ringnalda
d381b4bca6 Back out 7 changesets (bug 1235261) for cpptest failures in TestTArray
CLOSED TREE

Backed out changeset d66c3f19a210 (bug 1235261)
Backed out changeset 467d945426bb (bug 1235261)
Backed out changeset 32b61df13142 (bug 1235261)
Backed out changeset c50bb8ed4196 (bug 1235261)
Backed out changeset 0ff0fa6fe81f (bug 1235261)
Backed out changeset df70e89669da (bug 1235261)
Backed out changeset 064969357fc9 (bug 1235261)
2016-01-31 10:10:57 -08:00
Birunthan Mohanathas
373593275e Bug 1235261 - Part 1: Rename nsAutoTArray to AutoTArray. r=froydnj 2016-01-31 17:12:12 +02:00