[webkit-changes] [WebKit/WebKit] 302e7f: [Skia] Return early when receiving an all-zero Das...

Simon Pena noreply at github.com
Mon Jan 20 12:15:21 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 302e7f17d0ef26379d41ca0a5c79677bca01bfa4
      https://github.com/WebKit/WebKit/commit/302e7f17d0ef26379d41ca0a5c79677bca01bfa4
  Author: Simon Pena <spena at igalia.com>
  Date:   2025-01-20 (Mon, 20 Jan 2025)

  Changed paths:
    M Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp

  Log Message:
  -----------
  [Skia] Return early when receiving an all-zero DashArray
https://bugs.webkit.org/show_bug.cgi?id=285610

Reviewed by Carlos Garcia Campos.

Validate dash array elements according to the spec, including
optimising the all-zero case. An all-zero DashArray can be detected and skipped.

* Source/WebCore/platform/graphics/skia/GraphicsContextSkia.cpp:
(WebCore::isValidDashArray): New helper that checks array is valid.
(WebCore::GraphicsContextSkia::setLineDash): Use the helper to assign a
nullptr and return early.

Canonical link: https://commits.webkit.org/289164@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list