Граф коммитов

392 Коммитов

Автор SHA1 Сообщение Дата
longsonr b7e4cc0df4 Bug 1695490 - Remove svg.text-spacing.enabled pref r=emilio
Backs out bug 1599173 which landed in Firefox 72. The pref has been enabled since bug 1600855 which landed in Firefox 73

Differential Revision: https://phabricator.services.mozilla.com/D106731
2021-02-28 21:52:21 +00:00
longsonr f3136a33fd Bug 1693032 - SVG text reflow can flow through multiple outer svg elements r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D105350
2021-02-17 14:51:47 +00:00
Butkovits Atila 5d9332dfde Backed out changeset 4b9a80f187e8 (bug 1693032) for causing failures on 1693032.html 2021-02-17 00:09:08 +02:00
longsonr 9b5e3f031e Bug 1693032 - SVG text reflow can flow through multiple outer svg elements r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D105350
2021-02-16 21:06:55 +00:00
longsonr 17abb2b7e9 Bug 1691659 - don't re-enter ScheduleReflowSVG r=emilio
The testcase in the bug does assert under a debug Firefox here: https://searchfox.org/mozilla-central/source/layout/svg/SVGUtils.cpp#156 presumably fuzz testing has not uncovered this because of the mouse over part. I don't know how to write an automated test for this.

Note that scheduling a reflow will cause a repaint especially as we're setting state bits so we don't need to do a paint notify too.

Differential Revision: https://phabricator.services.mozilla.com/D104564
2021-02-13 07:45:31 +00:00
longsonr c04dd7eafa Bug 1689799 - Ensure we move to the next path when displaying multiple adjacent textPaths r=emilio
reverts part of bug 1678756

Differential Revision: https://phabricator.services.mozilla.com/D103558
2021-01-30 21:35:17 +00:00
Mirko Brodesser c0d32bffc5 Bug 1685303: part 10) Annotate `nsFrameSelection::HandleClick` with `MOZ_CAN_RUN_SCRIPT`. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D101598
2021-01-14 13:24:36 +00:00
Bogdan Tara 0700454a9e Backed out 4 changesets (bug 1685303) for bustage complaining about offsets CLOSED TREE
Backed out changeset a4640aac6619 (bug 1685303)
Backed out changeset bd2020c26531 (bug 1685303)
Backed out changeset 3f2e96b93f19 (bug 1685303)
Backed out changeset 8cf49a7677c9 (bug 1685303)
2021-01-14 12:58:25 +02:00
Mirko Brodesser c6272f3a54 Bug 1685303: part 10) Annotate `nsFrameSelection::HandleClick` with `MOZ_CAN_RUN_SCRIPT`. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D101598
2021-01-14 10:21:17 +00:00
longsonr 777beda23d Bug 1678756 - Check we don't run off the end of the textPath while skipping characters r=emilio
The textcase and reference differ by a single space.
We should check that we've not run off the end of the path while we're skipping characters
Also removes a redundant check presumably left over from some earlier refactoring.

Differential Revision: https://phabricator.services.mozilla.com/D97828
2020-12-05 21:05:41 +00:00
Butkovits Atila e82dd032af Backed out changeset 247ecae76586 (bug 1678756) for failures on gfxTextRun.h. CLOSED TREE 2020-12-04 18:16:29 +02:00
longsonr 16a19b1aa8 Bug 1678756 - Check for new clusters or ligature groups in textPaths even in skipped characters r=emilio
The textcase and reference differ by a single space.
We should check for new clusters or ligature groups in textPaths even in skipped characters
Also removes a redundant check presumably left over from some earlier refactoring.

Differential Revision: https://phabricator.services.mozilla.com/D97828
2020-12-04 06:21:37 +00:00
Ting-Yu Lin 545a6376cd Bug 1677635 Part 4 - Rename nsOverflowAreas to OverflowAreas, and move it into mozilla namespace. r=layout-reviewers,emilio
This patch is generated via the rename functionality in my editor; add
`mozilla::` prefix to `OverflowAreas` in headers; and remove the
`OverflowType` alias added in Part 1.

Differential Revision: https://phabricator.services.mozilla.com/D97235
2020-11-18 00:08:12 +00:00
longsonr f1fb147667 Bug 1677187 - ignore x values for vertical and y values for horizontal text in textPaths r=heycam
Differential Revision: https://phabricator.services.mozilla.com/D97086
2020-11-16 10:54:56 +00:00
longsonr 1d904c3e45 Bug 1603629 - fix dominant-baseline hanging and mathematical r=jfkthame
Differential Revision: https://phabricator.services.mozilla.com/D88877
2020-09-04 11:00:40 +00:00
longsonr 226b57059c Bug 1661912 - Convert remaining typedefs in SVG code to 'using' r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D88718
2020-08-29 14:24:37 +00:00
longsonr 4f8808ae6f Bug 1459905 - Merge DOMSVGTranslatePoint and DOMSVGPoint and fix updates r=emilio
SVGSVGElement::SetCurrentScaleTranslate checks that things have changed but if we
manage to update both translate values before we get here then we'll skip the screen update
that we need.

Also
- introduces a tear off for SVGSVGElement.currentTranslate so we hand out the same object as required by the SVG idl
- removes SVGSVGElement::SetCurrentTranslate as dead code
- removes mPreviousScale and mPreviousTranslate from SVGSVGElement as they are no longer necessary

Differential Revision: https://phabricator.services.mozilla.com/D84796
2020-08-25 14:38:32 +00:00
Ting-Yu Lin fdc00547f6 Bug 1637130 - Rename visual overflow to ink overflow. r=dbaron
This patch is generated by:

```
# Rename the nsOverflowType enum.
rg -l "eVisualOverflow" layout/ gfx/ | xargs sed -i "s/eVisualOverflow/eInkOverflow/g"

# Rename and drop the "Get" prefix from various functions.
rg -l "GetVisualOverflowRect" layout/ gfx/ | xargs sed -i "s/GetVisualOverflowRect/InkOverflowRect/g"
rg -l "GetPreEffectsVisualOverflowRect" layout/ gfx/ | xargs sed -i "s/GetPreEffectsVisualOverflowRect/PreEffectsInkOverflowRect/g"
rg -l "GetVisualOverflowFromDeltas" layout/ gfx/ | xargs sed -i "s/GetVisualOverflowFromDeltas/InkOverflowFromDeltas/g"
rg -l "GetScrollableOverflowRect" layout/ gfx/ | xargs sed -i "s/GetScrollableOverflowRect/ScrollableOverflowRect/g"

# Rename, drop the "Get" prefix, and change the suffix "Area" to "Rect"
# (because they return nsRect) for the two methods in nsLineBox.
rg -l "GetVisualOverflowArea" layout/ gfx/ | xargs sed -i "s/GetVisualOverflowArea/InkOverflowRect/g"
rg -l "GetScrollableOverflowArea" layout/ gfx/ | xargs sed -i "s/GetScrollableOverflowArea/ScrollableOverflowRect/g"

# Rename rest of the functions and variables.
rg -l "VisualOverflow" layout/ gfx/ | xargs sed -i "s/VisualOverflow/InkOverflow/g"
rg -l "visual overflow" layout/ gfx/ | xargs sed -i "s/visual overflow/ink overflow/g"
rg -l "visualOverflow" layout/ gfx/ | xargs sed -i "s/visualOverflow/inkOverflow/g"
rg -l "visOverflow" layout/ gfx/ | xargs sed -i "s/visOverflow/inkOverflow/g"
rg -l "vis-overflow" layout/ gfx/ python/ | xargs sed -i "s/vis-overflow/ink-overflow/g"

./mach clang-format
```

Differential Revision: https://phabricator.services.mozilla.com/D84231
2020-07-20 20:17:36 +00:00
longsonr 875f5e88ac Bug 1259861 - Move everything else into the mozilla namespace in layout/svg r=dholbert
Also: adjust include paths to be consistent for usages of various SVG headers,
and remove unused SVG includes (mostly for "utils" classes),
and drop stray "ns" from already-renamed SVG classes in various code comments.

Differential Revision: https://phabricator.services.mozilla.com/D83140
2020-07-11 02:20:20 +00:00
longsonr cc4f307539 Bug 1651404 - Move nsSVGDisplayableFrame and nsISVGSVGFrame to the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D82945
2020-07-09 18:34:54 +00:00
Ting-Yu Lin ffcfb6dcec Bug 1651171 - Convert NS_SUBTREE_DIRTY to an inline method of nsIFrame. r=jfkthame
This is a straightforward conversion except that
`NS_SUBTREE_DIRTY(this)` can be written terser as `IsSubtreeDirty()`.

Differential Revision: https://phabricator.services.mozilla.com/D82811
2020-07-09 18:29:15 +00:00
longsonr 6f5803e27f Bug 1651289 - Move remaining SVG concrete frame classes to the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D82650
2020-07-09 01:33:33 +00:00
longsonr 058049a793 Bug 1649739 - Move SVG paint server and clipPath classes to the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D81858
2020-07-07 13:49:30 +00:00
Kagami Sascha Rosylight 1afcf4d621 Bug 1630704 - Part 27: Remove nsFrame from inheritance chain r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D81864
2020-07-06 22:29:42 +00:00
Kagami Sascha Rosylight 24b9873504 Bug 1647525 - Use HasAnyStateBits() in SVGTextFrame r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D81224
2020-06-27 14:22:58 +00:00
longsonr 71614873fb Bug 1648737 - Move SVGAFrame SVGGFrame SVGGenericContainerFrame SVGInnerSVGFrame SVGMarkerFrame SVGMaskFrame SVGSymbolFrame SVGViewportFrame to the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D81310
2020-06-27 05:39:42 +00:00
Mihai Alexandru Michis 20dfc519d1 Backed out changeset 1b8b8756acad (bug 1648737) for causing bustages in SVGMaskFrame.h
CLOSED TREE
2020-06-27 02:24:41 +03:00
longsonr 3b9835e5b8 Bug 1648737 - Move SVGAFrame SVGGFrame SVGGenericContainerFrame SVGInnerSVGFrame SVGMarkerFrame SVGMaskFrame SVGSymbolFrame SVGViewportFrame to the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D81310
2020-06-26 19:27:08 +00:00
longsonr 0a29054e26 Bug 1647101 - Move SVGTextFrame SVGViewFrame SVGFEContainerFrame SVGFEImageFrame SVGFELeafFrame SVGFEUnstyledLeafFrame into the mozilla namespace r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D80383
2020-06-23 22:59:34 +00:00
Emilio Cobos Álvarez b9b9e38dd9 Bug 1646224 - Use mozilla::Length rather than nscoord to store font sizes. r=heycam,jfkthame
This avoids arbitrary precision loss when computing REM units and so on,
which is particularly important if we ever change the base of our app
units (but useful regardless).

Differential Revision: https://phabricator.services.mozilla.com/D79928
2020-06-22 09:45:40 +00:00
Cosmin Sabou 65d75a47f3 Backed out changeset 299e19193e11 (bug 1646224) for causing font related failures. CLOSED TREE 2020-06-18 18:26:51 +03:00
Emilio Cobos Álvarez 090e3d2409 Bug 1646224 - Use mozilla::Length rather than nscoord to store font sizes. r=heycam,jfkthame
This avoids arbitrary precision loss when computing REM units and so on,
which is particularly important if we ever change the base of our app
units (but useful regardless).

Differential Revision: https://phabricator.services.mozilla.com/D79928
2020-06-18 13:55:03 +00:00
Simon Giesecke 82dc9b2271 Bug 1642949 - Replace uses of RemoveElementAt by RemoveLastElement/PopLastElement where possible. r=necko-reviewers,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D78027
2020-06-10 10:46:14 +00:00
Butkovits Atila e3dce68834 Backed out 3 changesets (bug 1643289, bug 1642949) for causing failure at test_headless_screenshot.html. CLOSED TREE
Backed out changeset 98c420f73380 (bug 1643289)
Backed out changeset 9447ea8910aa (bug 1643289)
Backed out changeset 0c827da9d847 (bug 1642949)
2020-06-10 10:07:23 +03:00
Simon Giesecke d419f0ff08 Bug 1642949 - Replace uses of RemoveElementAt by RemoveLastElement/PopLastElement where possible. r=necko-reviewers,froydnj
Differential Revision: https://phabricator.services.mozilla.com/D78027
2020-06-10 05:49:28 +00:00
Cameron McCormack d56f82ffbf Bug 1609663 - Reflow non-display SVG text that has just been inserted. r=longsonr
Differential Revision: https://phabricator.services.mozilla.com/D75034
2020-05-13 08:00:23 +00:00
Botond Ballo 173d001b86 Bug 1556556 - Propagate RelativeTo far and wide. r=kats,mattwoodrow
This "upgrades" various nsLayoutUtils functions which take as inputs
a set of coordinates and a frame that the coordinates are relative to,
to accept a RelativeTo object instead of a frame.

Most of the patch is just dumb propagation, but the few places where
we use an explicit ViewportType::Visual are important. There are
probably a few other places I've overlooked, but this seems to cover
the important ones that come up commonly.

There are undoubtedly other functions into which we can propagate
RelativeTo, in this patch I've propagated it as far as necessary
for my needs in this bug (mainly GetTransformToAncestor() and
GetEventCoordinatesRelativeTo()).

Differential Revision: https://phabricator.services.mozilla.com/D68919
2020-05-05 19:26:38 +00:00
Csoregi Natalia b073baab86 Backed out 30 changesets (bug 1556556, bug 1631568) for multiple mochitest failures. CLOSED TREE
Backed out changeset edd529f7a9c5 (bug 1631568)
Backed out changeset 1cc0881e244b (bug 1631568)
Backed out changeset ed3c1e85d5e3 (bug 1556556)
Backed out changeset 38ffc6215bbf (bug 1556556)
Backed out changeset 03c2c25d8023 (bug 1556556)
Backed out changeset 9c717eb067b8 (bug 1556556)
Backed out changeset 98e26bc98b85 (bug 1556556)
Backed out changeset 05a6a581e755 (bug 1556556)
Backed out changeset 867946cf05bb (bug 1556556)
Backed out changeset 20d72a334530 (bug 1556556)
Backed out changeset 2c62e61d9054 (bug 1556556)
Backed out changeset 62a223d057d2 (bug 1556556)
Backed out changeset 2c5d55a1f0b1 (bug 1556556)
Backed out changeset 700447945b4e (bug 1556556)
Backed out changeset 93190ae4f5ff (bug 1556556)
Backed out changeset a7bd34d961bb (bug 1556556)
Backed out changeset fccd1d3c7189 (bug 1556556)
Backed out changeset 24056e47183d (bug 1556556)
Backed out changeset 204881474cc1 (bug 1556556)
Backed out changeset 387320881876 (bug 1556556)
Backed out changeset be8f5eb58460 (bug 1556556)
Backed out changeset 629c58a9166b (bug 1556556)
Backed out changeset 4312b2b5dda8 (bug 1556556)
Backed out changeset d11dbf6403a5 (bug 1556556)
Backed out changeset 95c54c023779 (bug 1556556)
Backed out changeset 80fcb7e71188 (bug 1556556)
Backed out changeset d75a4ecb0d47 (bug 1556556)
Backed out changeset 903c4de34e7a (bug 1556556)
Backed out changeset f15334a3e803 (bug 1556556)
Backed out changeset 9553e99137ea (bug 1556556)
2020-04-28 12:43:11 +03:00
Botond Ballo 405c8807cd Bug 1556556 - Propagate RelativeTo far and wide. r=kats,mattwoodrow
This "upgrades" various nsLayoutUtils functions which take as inputs
a set of coordinates and a frame that the coordinates are relative to,
to accept a RelativeTo object instead of a frame.

Most of the patch is just dumb propagation, but the few places where
we use an explicit ViewportType::Visual are important. There are
probably a few other places I've overlooked, but this seems to cover
the important ones that come up commonly.

There are undoubtedly other functions into which we can propagate
RelativeTo, in this patch I've propagated it as far as necessary
for my needs in this bug (mainly GetTransformToAncestor() and
GetEventCoordinatesRelativeTo()).

Differential Revision: https://phabricator.services.mozilla.com/D68919
2020-04-28 01:40:35 +00:00
Andrew Osmond 91b071ed14 Bug 1618345 - Enforce proper color management by splitting gfx::Color into sRGBColor and DeviceColor types. r=jrmuizel
gfx::Color is currently misused in many places. The DrawTargets expect
the color space to be in device space, e.g. what we are actually going
to draw using. Everything sitting above generally deals with sRGB, as
specified in CSS. Sometimes we missed the conversion from sRGB to device
space when issuing draw calls, and similarly sometimes we converted the
color to device space twice.

This patch splits the type in two. sRGBColor and DeviceColor now
represent sRGB and device color spaces respectively. DrawTarget only
accepts DeviceColor, and one can get a DeviceColor from an sRGBColor via
the ToDeviceColor helper API. The reftests now pass with color
management enabled for everything (e.g. CSS) instead of just tagged
raster images.

There will be a follow up patch to enable color management everywhere by
default on all supported platforms.

Differential Revision: https://phabricator.services.mozilla.com/D64771

--HG--
extra : moz-landing-system : lando
2020-03-09 14:16:17 +00:00
Emilio Cobos Álvarez 71cc1a2c62 Bug 1617425 - Use cbindgen for SVG lengths. r=jwatt
Depends on D63777

Differential Revision: https://phabricator.services.mozilla.com/D63778

--HG--
extra : moz-landing-system : lando
2020-02-23 15:43:03 +00:00
Simon Giesecke 9350e6b741 Bug 1613985 - Use MOZ_COUNTED_DEFAULT_CTOR_*/MOZ_COUNTED_DTOR_* macros. r=froydnj
This removes the need for explicit #ifdef NS_BUILD_REFCNT_LOGGING without
introducing user-defined destructors when it is not defined.

Also, some uses of virtual for declaring destructors are replaced by the
appropriate override declaration through these changes.

Differential Revision: https://phabricator.services.mozilla.com/D62604

--HG--
extra : moz-landing-system : lando
2020-02-20 11:40:14 +00:00
Dorel Luca d5f9df8ee1 Backed out 2 changesets (bug 1613985) for Build bustage on Windows2012. CLOSED TREE
Backed out changeset fd177b40b561 (bug 1613985)
Backed out changeset fb6d62b7f28d (bug 1613985)
2020-02-19 22:22:41 +02:00
Simon Giesecke 59b23375c0 Bug 1613985 - Use MOZ_COUNTED_DEFAULT_CTOR_*/MOZ_COUNTED_DTOR_* macros. r=froydnj
This removes the need for explicit #ifdef NS_BUILD_REFCNT_LOGGING without
introducing user-defined destructors when it is not defined.

Also, some uses of virtual for declaring destructors are replaced by the
appropriate override declaration through these changes.

Differential Revision: https://phabricator.services.mozilla.com/D62604

--HG--
extra : moz-landing-system : lando
2020-02-19 18:05:38 +00:00
Mirko Brodesser ea1f257885 Bug 1614636: simplify arguments of `nsFrameSelection::HandleClick`. r=jfkthame
Simplifies understanding its dependent methods.

Differential Revision: https://phabricator.services.mozilla.com/D62433

--HG--
extra : moz-landing-system : lando
2020-02-11 15:12:26 +00:00
Boris Zbarsky 4472ba99ca Bug 1614165 part 1. Improve error messages for SVG text. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D62154

--HG--
extra : moz-landing-system : lando
2020-02-09 02:15:32 +00:00
Sakura Mochizuki edc2287d2f Bug 1611040 - Convert dominant-baseline #defines to an enum class. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D61046

--HG--
extra : moz-landing-system : lando
2020-01-25 10:51:24 +00:00
Emilio Cobos Álvarez a25126cd0d Bug 1611181 - Make direction use an enum class. r=boris
Differential Revision: https://phabricator.services.mozilla.com/D60857

--HG--
extra : moz-landing-system : lando
2020-01-24 11:46:14 +00:00
Emilio Cobos Álvarez 5cd5e6f148 Bug 1609996 - Remove mozilla::Swap in favor of std::swap. r=froydnj
Now mfbt/Move.h is empty except for that excellent comment about move
semantics... Should we put it somewhere else and delete the header as a
follow-up? Or just delete the header and carry on?

Differential Revision: https://phabricator.services.mozilla.com/D60297

--HG--
extra : moz-landing-system : lando
2020-01-20 16:17:06 +00:00
Cameron McCormack a0c9040f10 Bug 1601824 - Measure partial ligature advance contributions correctly on text paths. r=longsonr
Differential Revision: https://phabricator.services.mozilla.com/D56665

--HG--
extra : moz-landing-system : lando
2019-12-11 04:57:41 +00:00