diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:35:29 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 05:35:29 +0000 |
commit | 59203c63bb777a3bacec32fb8830fba33540e809 (patch) | |
tree | 58298e711c0ff0575818c30485b44a2f21bf28a0 /dom/svg/SVGContentUtils.h | |
parent | Adding upstream version 126.0.1. (diff) | |
download | firefox-59203c63bb777a3bacec32fb8830fba33540e809.tar.xz firefox-59203c63bb777a3bacec32fb8830fba33540e809.zip |
Adding upstream version 127.0.upstream/127.0
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | dom/svg/SVGContentUtils.h | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/dom/svg/SVGContentUtils.h b/dom/svg/SVGContentUtils.h index 8cd017b709..31e75cbb21 100644 --- a/dom/svg/SVGContentUtils.h +++ b/dom/svg/SVGContentUtils.h @@ -180,13 +180,24 @@ class SVGContentUtils { static float GetFontXHeight(const ComputedStyle*, nsPresContext*); /* + * Get the number of CSS px (user units) per lh (i.e. the line-height in + * user units) for an nsIContent. + * + * Requires the element be styled - if not, a default value assuming + * the font-size of 16px and line-height of 1.2 is returned. + */ + static float GetLineHeight(const mozilla::dom::Element* aElement); + + /* * Report a localized error message to the error console. */ static nsresult ReportToConsole(const dom::Document* doc, const char* aWarning, const nsTArray<nsString>& aParams); - static Matrix GetCTM(dom::SVGElement* aElement, bool aScreenCTM); + static Matrix GetCTM(dom::SVGElement* aElement); + + static Matrix GetScreenCTM(dom::SVGElement* aElement); /** * Gets the tight bounds-space stroke bounds of the non-scaling-stroked rect |