Bug 263748 - [GeometryInterface] Add `scaleNonUniform` in DOMMatrixReadOnly
Summary: [GeometryInterface] Add `scaleNonUniform` in DOMMatrixReadOnly
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar, WPTImpact
Depends on:
Blocks:
 
Reported: 2023-10-26 15:15 PDT by Ahmad Saleem
Modified: 2023-11-21 16:28 PST (History)
5 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ahmad Saleem 2023-10-26 15:15:25 PDT
Hi,

We should add 'scaleNonUniform' support.

Web-Spec: https://drafts.fxtf.org/geometry/#dom-dommatrixreadonly-scalenonuniform

Blink Commit: https://chromium.googlesource.com/chromium/src.git/+/57f350e070536c7870cad53b3edf74f58cc51d50

We are failing WPT test cases due to lack of support and adding them will progress them.

I was not able to find relevant bug so created new.

Thanks!
Comment 1 Radar WebKit Bug Importer 2023-11-02 15:16:13 PDT
<rdar://problem/117875678>
Comment 2 Ahmad Saleem 2023-11-18 06:33:55 PST
>> Source/WebCore/css/DOMMatrixReadOnly.cpp

Ref<DOMMatrix> DOMMatrixReadOnly::scaleNonUniform(double scaleX, double scaleY)
{
    auto matrix = cloneAsDOMMatrix();
    return matrix->scaleSelf(scaleX, scaleY, 1, 0, 0, 0);
}

>> Source/WebCore/css/DOMMatrixReadOnly.h:

Ref<DOMMatrix> scaleNonUniform(double scaleX = 1, double scaleY = 1);

>> Source/WebCore/css/DOMMatrixReadOnly.idl:

[NewObject] DOMMatrix scaleNonUniform(optional unrestricted double scaleX = 1,
                                      optional unrestricted double scaleY = 1);

___

This compiles and progress few tests cases.

I can sync 'WPT' and do above to at least progress few tests cases and as for remaining, I am happy to create separate bugs.
Comment 3 Karl Dubost 2023-11-20 03:47:11 PST
if it doesn't regress anything, let's do it.
what are the WPT tests progressing? 
ah probably these https://wpt.fyi/results/css/geometry?label=master&label=experimental&aligned&q=safari%3Afail
Comment 4 EWS 2023-11-21 16:28:16 PST
Committed 271030@main (d0f9805c729a): <https://commits.webkit.org/271030@main>

Reviewed commits have been landed. Closing PR #20799 and removing active labels.