Masayuki Nakano
400a8761f1
Bug 1278014 part.6 Rename SelectionType::SELECTION_SPELLCHECK to SelectionType::eSpellCheck r=smaug
...
MozReview-Commit-ID: 4n2jEVax37O
2016-06-09 18:37:36 +09:00
Masayuki Nakano
09b74b02de
Bug 1278014 part.5 Rename SelectionType::SELECTION_NORMAL to SelectionType::eNormal r=smaug
...
MozReview-Commit-ID: AAdxTTKEvrk
2016-06-09 18:35:22 +09:00
Masayuki Nakano
ad13c60b69
Bug 1278014 part.4 Rename SelectionType::SELECTION_NONE to SelectionType::eNone r=smaug
...
MozReview-Commit-ID: BRfzs8sColP
2016-06-09 18:07:18 +09:00
Masayuki Nakano
4e5926428a
Bug 1278014 part.3 Define 2 constants for number of SelectionType and number of SelectionType except "none" r=smaug
...
This patch defines two constants kSelectionTypeCount and kPresentSelectionTypeCount. The former is same as nsISelectionController::NUM_SELECTIONTYPES. The latter is kSelectionTypeCount - 1 for excluding SELECTION_NONE. The latter is useful in some loops which handle all selection types except SELECTION_NONE.
Note that this patch fixes a bug of nsFrameSelection. That doesn't treat SELECTION_NONE as a selection (see the definition of index), however, it defines redundant item and doesn't use it actually. Additionally, it computes invalid selection type in each loop. Therefore, without this patch, debug build hits MOZ_ASSERT() in ToSelectionType(RawSelectionType).
Note that these constants are defined as anonymous enum because we cannot define as const (or static) even with extern. If we'd try to do it, it caused link error or not available in nsFrameSelection.cpp as constant value since they were not initialized if they were initialized in nsSelection.cpp. Therefore, these constants are defined as enum items but using "k" prefix.
MozReview-Commit-ID: H6sH7NBEXlE
2016-06-11 11:12:26 +09:00
Masayuki Nakano
4b3d1e8406
Bug 1278014 part.2 Define mozilla::SelectionType as an enum class and use it instead of RawSelectionType as far as possible r=smaug
...
This patch defines mozilla::SelectionType as an enum class. This is safer than nsISelectionController::SELECTION_* since setting illegal value to its variable is checked at build time. So, as far as possible, this should be used everywhere (but of course, this isn't available in scriptable interfaces).
And also this implements some useful methods for managing SelectionType and RawSelectionType which are implemented in layout/nsSelection.cpp because nsISelectionController is implemented by both PresShell and nsTextEditorState. Therefore, implementing one of them may make hard to find them. On the other hand, nsSelection.cpp is a better file name to look for them.
Note that this patch creates mozilla::Selection::RawType() for binding. Native code should keep using Selection::Type() but the binding code needs to use RawType() due to impossible to convert from SelectionType to RawSelectionType without explicit cast.
MozReview-Commit-ID: 81vX7A0hHQN
2016-06-11 11:06:37 +09:00
Masayuki Nakano
71befe7dcf
Bug 1278014 part.1 Rename SelectionType in nsISelectionController.idl to mozilla::RawSelectionType r=smaug
...
mozilla::SelectionType will be an enum class. Therefore, we need to rename SelectionType with a word "raw" since it's a type for raw nsISelectionController::SELECTION_*.
MozReview-Commit-ID: K8SO0bbpv0Y
2016-06-07 22:42:06 +09:00
Carsten "Tomcat" Book
e9321e1391
merge mozilla-inbound to mozilla-central a=merge
2016-06-08 11:57:53 +02:00
Nicholas Nethercote
07e48a1ba0
Bug 1278452 - Remove an unnecessary null check in layout/generic/. r=heycam.
...
mLineContainer is dereferenced shortly before and after the check, so it's
obviously not useful.
2016-06-07 14:45:38 +10:00
Xidorn Quan
8b9905ef1a
Bug 1277937 - Fix SELECTION_URLSTRIKEOUT. r=jfkthame
...
MozReview-Commit-ID: LumW94mTX4X
2016-06-07 16:12:15 -07:00
Xidorn Quan
51df4a4c00
Bug 1268342 part 3 - Treat orthogonal text frame as non-text frame when applying justification gap. r=jfkthame
...
Also correct the comment in ComputeJustification.
MozReview-Commit-ID: AWGGuupFLze
2016-05-30 09:24:18 +10:00
Xidorn Quan
7e26fd8f7c
Bug 1275059 - Simple fix for this bug. r=jfkthame
...
MozReview-Commit-ID: IVScO6eV6RP
2016-05-25 09:54:37 +10:00
CJKu
a1dab046b9
Bug 1269971 - Part 7. Clean out unused things created in bug 759568; r=jfkthame
...
MozReview-Commit-ID: 4spLj1fgthI
2016-05-13 00:09:39 +08:00
CJKu
f911bbb803
Bug 1269971 - Part 4. Add text stroke into text mask; r=jfkthame
...
MozReview-Commit-ID: IkaLMEX5q0T
2016-05-13 00:09:05 +08:00
CJKu
2ca6611b52
Bug 1269971 - Part 3. Handle selection text color and selection backgrond painting; r=jfkthame
...
MozReview-Commit-ID: CQmqiCmvygr
2016-05-13 00:08:53 +08:00
CJKu
b5b879d00c
Bug 1269971 - Part 2. From ClipBackgroundByText to GenerateAndPushTextMask; r=jfkthame,mtseng
...
MozReview-Commit-ID: 1PK2Huytq3i
2016-05-13 00:08:41 +08:00
CJKu
17721f6781
Bug 1269971 - Part 1. Rename IsForGenerateGlyphPath to IsForGenerateGlyphMask; r=jfkthame
...
MozReview-Commit-ID: 80DZsEAvXxB
2016-05-13 00:08:30 +08:00
Matt Woodrow
61200a9c5c
Bug 1243610 - Refactor UpdateOverflow to separate out local overflow from that contributed by descendants. r=dbaron
2016-05-04 12:27:43 +12:00
Aryeh Gregor
c00d4b886e
Bug 1193762 part 7 - Use .get() when assigning to variables; r=froydnj
...
Unlike when returning an nsCOMPtr in a ternary operator or passing to a
function, I used .get() here, since the operation is actually unsafe and
deserves to be marked explicitly.
2016-05-01 21:29:23 +03:00
CJKu
647da23a2f
Bug 1266948 - text-decoration-color: currentcolor should not use value from -webkit-text-fill-color; r=jfkthame
...
MozReview-Commit-ID: 2SfENZieSzQ
2016-04-26 23:56:44 +08:00
Jeremy Chen
57063f1344
Bug 1248708 - Part2.2: render -webkit-text-stroke property. r=jfkthame
2016-04-23 01:40:39 +08:00
Xidorn Quan
e3a772c73a
Bug 1097499 part 14 - Draw emphasis marks properly for text-combine-upright. r=jfkthame
...
MozReview-Commit-ID: 2bHWXxZDVGk
2016-04-22 09:18:41 +10:00
Xidorn Quan
0c1ee61704
Bug 1097499 part 13 - Draw decoration line properly for text-combine-upright. r=jfkthame
...
MozReview-Commit-ID: AymG09nvxh1
2016-04-22 09:18:41 +10:00
Xidorn Quan
c420f792b8
Bug 1097499 part 12 - Handle spacing sensibly for text-combine-upright. r=jfkthame
...
MozReview-Commit-ID: DSBMUcccfNi
2016-04-22 09:18:41 +10:00
Xidorn Quan
8f0254cf82
Bug 1097499 part 9 - Transform full-width characters to non-full-width correspondents for combined text. r=jfkthame
...
MozReview-Commit-ID: CXntBz9HPJu
2016-04-22 09:18:41 +10:00
Xidorn Quan
c6293269fd
Bug 1097499 part 5 - Layout text combine upright. r=jfkthame
...
MozReview-Commit-ID: 2HnXJ8bEvJH
2016-04-22 09:18:41 +10:00
Jonathan Kew
cbb738f072
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
c005e4fdbc
Bug 1265648 followup - Use an array of UniquePtr<> for mTextRunsToDelete. r=mats
2016-04-20 10:55:15 +01:00
Jonathan Kew
453ebfaa9e
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
e6846dd2c6
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
Markus Stange
d33e47b3b2
Bug 1265568 - Don't require component alpha layers for text with -moz-osx-font-smoothing:grayscale. r=jfkthame,mattwoodrow
...
MozReview-Commit-ID: KujmkbgadPo
2016-04-18 19:41:50 -04:00
CJKu
3773790ca6
Bug 1261578 - Part 2. Correct text decoration color; r=jfkthame
...
MozReview-Commit-ID: LfZnmTnL5KY
2016-04-19 17:09:54 +08:00
CJKu
1e87bac705
Bug 1261578 - Part 1. Correct text color in selection range; r=jfkthame
...
MozReview-Commit-ID: 9gBWQ00MtNC
2016-04-19 17:09:42 +08:00
CJKu
0c1b7efb87
Bug 759568 - Part 3. Render text-selection beneath background image; r=jfkthame
...
MozReview-Commit-ID: 3VUGqyJOX8Q
2016-04-14 16:28:07 +08:00
CJKu
8eacf30983
Bug 759568 - Part 2. Render background-clip:text; r=jfkthame
...
MozReview-Commit-ID: HQHBe7OioWs
2016-04-14 16:28:07 +08:00
Carsten "Tomcat" Book
3b36687a1f
Backed out changeset 6a2e62e8c861 (bug 759568)
2016-04-14 08:57:41 +02:00
Carsten "Tomcat" Book
5efc53ba0f
Backed out changeset e9fc67d8b0fa (bug 759568)
2016-04-14 08:57:39 +02:00
CJKu
1583a9e5b9
Bug 759568 - Part 3. Render text-selection beneath background image; r=jfkthame
...
MozReview-Commit-ID: 3VUGqyJOX8Q
2016-04-14 12:45:38 +08:00
CJKu
f51f239496
Bug 759568 - Part 2. Render background-clip:text; r=jfkthame
...
MozReview-Commit-ID: HQHBe7OioWs
2016-04-14 12:45:38 +08:00
Mats Palmgren
1a83f57b72
Bug 645647 part 4 - Add an 'm' prefix to some members to follow our naming conventions. r=dholbert
2016-04-14 01:32:12 +02:00
Xidorn Quan
221348b151
Bug 1229743 part 2 - Fix up decoration rect computation for vertical-rl and sideways-lr. r=jfkthame
...
MozReview-Commit-ID: BjJ9jhmBy1X
2016-04-11 17:14:34 +10:00
Xidorn Quan
77173feab4
Bug 1229743 part 1 - Simplify text decoration handling code with lambda function and range-based for loop. r=jfkthame
...
MozReview-Commit-ID: 4q2tetC74Ab
2016-04-11 12:00:43 +10:00
Sebastian Hengst
e99225a2fb
Backed out changeset e64951d74d2a (bug 759568)
2016-04-12 17:55:44 +02:00
Sebastian Hengst
d5954388c7
Backed out changeset 21551ed8f1e1 (bug 759568)
2016-04-12 17:55:36 +02:00
CJKu
91f5f7c0ea
Bug 759568 - Part 3. Render text-selection beneath background image; r=jfkthame
...
MozReview-Commit-ID: 3VUGqyJOX8Q
2016-04-12 21:58:22 +08:00
CJKu
110d895ffb
Bug 759568 - Part 2. Render background-clip:text; r=jfkthame
...
MozReview-Commit-ID: HQHBe7OioWs
2016-04-12 21:58:22 +08:00
Xidorn Quan
a18591f997
Bug 1220438 - Correct baseline offset computation of text decoration for vertical-rl. r=jfkthame
...
MozReview-Commit-ID: 5VHapeQ6mBU
2016-04-01 16:29:31 +11:00
Jeremy Chen
8cf5419958
Bug 1261568 - part1: take -webkit-text-fill-color into consideration while
...
building displaylist for text frame. r=jfkthame
2016-04-05 12:35:44 +08:00
Mats Palmgren
38c3846d7d
Bug 1216001 - Fix a typo that eliminated a possible paint optimization. r=xidorn
2016-04-01 02:08:15 +02:00
Jeremy Chen
33899bc090
Bug 1247777 - Part2: implement -webkit-text-fill-color rendering. r=jfkthame
2016-03-25 15:54:50 +08:00
Xidorn Quan
3f99895d64
Bug 1258636 part 2 - Use struct to pass params for nsTextFrame::PaintDecorationLine. r=jfkthame
...
MozReview-Commit-ID: CICgNSPRrLM
2016-03-22 17:42:18 +08:00