Commit Graph

53775 Commits

Author SHA1 Message Date
Bastiaan van der Plaat
c88f14902b LibWeb: Add DOMQuad and text tests 2023-08-23 12:11:21 +01:00
Bastiaan van der Plaat
e4270bc01d LibWeb: Make DOMRectReadOnly use double instead of float 2023-08-23 12:11:21 +01:00
Bastiaan van der Plaat
2e1d6f624d LibIDL: Fix bug where Type::is_json doesn't look at parent interface 2023-08-23 12:11:21 +01:00
Bastiaan van der Plaat
43825acc79 Meta+BindingsGenerator: Add postfix to member_value_name to make unique 2023-08-23 12:11:21 +01:00
Tim Schumacher
dbc25f18ec LibCompress: Let BrotliDecompressionStream take a MaybeOwned 2023-08-23 12:03:37 +01:00
Tim Schumacher
8a853278d0 LibCompress: Port ZlibDecompressor to AK::Stream 2023-08-23 12:03:37 +01:00
Tim Schumacher
90780d9ade LibCompress: Let GzipDecompressor take a MaybeOwned<Stream> 2023-08-23 12:03:37 +01:00
0GreenClover0
f165d2e7ec LibWeb: Update <use> visuals after changing the referenced element 2023-08-23 11:55:24 +01:00
Tim Ledbetter
5af7d5da2f Ports: Simplify the output from identify when installing icons
This ensures that the correct index is always used when selecting an
image of a particular size.
2023-08-23 12:55:00 +02:00
Tim Ledbetter
d09271be35 Ports/SDL_sound: Ensure build is run in parallel 2023-08-23 12:23:33 +02:00
Tim Ledbetter
b885be8046 Ports/SDL_sound: Specify which optional dependencies to include
This fixes an issue where building `SDL_sound` with the `libphysfs`
port installed would cause the build to fail.

Ogg support has also been enabled. This allows playback of the sound
effects in GLTron.

Both FLAC and `libmodplug` support are currently disabled, even
though the build succeeds with them enabled, as there is currently no
way to test whether they would work or not.
2023-08-23 12:23:33 +02:00
Tim Ledbetter
9e5d430fbd Ports/SDL_sound: Update formatting to be consistent with other ports 2023-08-23 12:23:33 +02:00
Andreas Kling
354d2ccc3c LibWeb: Support fast_is<T>() for table, table sections, rows and cells
3.2x speed-up on WebKit/PerformanceTests/DOM/GridSort.html
2023-08-23 08:06:25 +02:00
Andreas Kling
76580bb9ba LibWeb: Cache lowercased tag name for getElementsByTagName() iteration
Instead of calling to_lowercase() on two strings for every step while
iterating over the HTMLCollection returned by getElementsByTagName(),
we now cache the lowercased tag name beforehand and reuse it.

2.4x speed-up on WebKit/PerformanceTests/DOM/DOMDivWalk.html
2023-08-23 08:06:25 +02:00
Sam Atkins
ec340f03a5 WebContent+LibWebView: Add support for user style sheets 2023-08-23 05:32:10 +02:00
Sam Atkins
6dcd8d4a2c LibWeb: Add support for "User" CascadeOrigin
User styles are applied after the UserAgent's built-in styles, and
before the Author styles that are part of the web page.

Because they're neither part of the page, but can still be modified
while the page is open, caching is a little tricky. The approach here
is to piggy-back on the StyleComputer's rule caches, which already get
rebuilt whenever the styles change. This is not the smartest approach,
since it means re-parsing the style sheet more often than is necessary,
but it's simple and works. :^)
2023-08-23 05:32:10 +02:00
Sam Atkins
7bc5949e35 LibWeb: Implement the :placeholder-shown pseudo-class
This matches if the element has a placeholder, and that placeholder is
currently visible. This applies to `<input>` and `<textarea>` elements,
but our `<textarea>` is very limited so does not support placeholders.
2023-08-23 05:30:59 +02:00
Sam Atkins
9f5b1e6614 LibWeb: Implement the :read-only and :read-write pseudo-classes 2023-08-23 05:30:59 +02:00
Sam Atkins
3d10bf3ae7 LibWeb: Implement the :target-within pseudo-class selector
As noted in a9620d8784 we don't currently
set the target element so this does not function, so no tests. But it
should work once we have a fleshed out Navigables implementation. :^)
2023-08-23 05:30:59 +02:00
Sam Atkins
3af8b491b4 LibWeb: Implement :any-link and :local-link pseudo-class selectors
`:any-link` matches links, whether they have been visited or not.

`:local-link` matches links to the current URL.
2023-08-23 05:30:59 +02:00
Timothy Flynn
eb8f7b303c LibLocale+LibJS: Make relative time format APIs infallible
These APIs only perform small allocations, and are only used by LibJS.
Callers which could only have failed from these APIs are also made to
be infallible here.
2023-08-23 05:29:21 +02:00
Timothy Flynn
7536648498 LibLocale+LibJS+ClockSettings: Make date time format APIs infallible
These APIs only perform small allocations, and are only used by LibJS
and the time zone settings widget. Callers which could only have failed
from these APIs are also made to be infallible here.
2023-08-23 05:29:21 +02:00
Timothy Flynn
0914e86691 LibLocale+LibJS: Make number format APIs infallible
These APIs only perform small allocations, and are only used by LibJS.
Callers which could only have failed from these APIs are also made to
be infallible here.
2023-08-23 05:29:21 +02:00
Timothy Flynn
cd526813e6 LibLocale+LibJS: Make locale data APIs infallible
These APIs only perform small allocations, and are only used by LibJS.
Callers which could only have failed from these APIs are also made to
be infallible here.
2023-08-23 05:29:21 +02:00
MacDue
a98201f889 LibGfx: Nudge points away from the start point in radial gradients
Avoids a division by zero, and an incorrect pixel in some repeating
radial gradient cases.

(Ref tests updated)
2023-08-23 05:27:19 +02:00
MacDue
df58fa8653 LibGfx: A few small radial gradient tweaks/fixups
A few very minor changes seemed to small to commit separately:

- Fix typo postive -> positive
- Remove swap(start, end) FIXME, that is the correct thing to do
- Add FIXME for start_radius == end_radius case
- Formatting tweaks
2023-08-23 05:27:19 +02:00
Cubic Love
2b8a9ff2ae Base: Improve Hearts Icon
Before the Hearts icon was quite angular, now it is a more rounded
heart with a subtle gradient.
2023-08-23 05:25:28 +02:00
Andi Gallo
bab1d09d92 LibWeb: Derive baseline from rightmost descendant
Make the existing algorithm recursive, accounting for boxes which
contain line boxes indirectly. Fixes some button alignment issues on
Wikipedia.
2023-08-23 05:24:55 +02:00
Timothy Flynn
2a8f558911 CI: Add a step to ensure the AppKit chrome can compile
The main build step builds the Qt chrome, because ENABLE_QT=ON is the
default. This adds a step to ensure we can build the AppKit chrome as
well.
2023-08-22 21:36:19 -04:00
Timothy Flynn
5722d0025b Ladybird: Implement an AppKit chrome for macOS :^)
This adds an alternative Ladybird chrome for macOS using the AppKit
framework. Just about everything needed for normal web browsing has
been implemented. This includes:

* Tabbed, scrollable navigation
* History navigation (back, forward, reload)
* Keyboard / mouse events
* Favicons
* Context menus
* Cookies
* Dialogs (alert, confirm, prompt)
* WebDriver support

This does not include debugging tools like the JavaScript console and
inspector, nor theme support.

The Qt chrome is still used by default. To use the AppKit chrome, set
the ENABLE_QT CMake option to OFF.
2023-08-22 21:36:19 -04:00
Timothy Flynn
66a89bd695 Meta: Support using clang-format on Objective-C++ files
We can (and have to) remove the C++ language identifier from the main
set of rules. This will allow these rule to propagate to all languages.
2023-08-22 21:36:19 -04:00
Aliaksandr Kalenik
43da0701fc LibWeb: Implement navigate() for Location object 2023-08-22 20:30:06 +02:00
Aliaksandr Kalenik
5f21285337 LibWeb: Add Window::navigable() 2023-08-22 20:30:06 +02:00
Aliaksandr Kalenik
343c709566 LibWeb: Add m_page in TraversableNavigable 2023-08-22 20:30:06 +02:00
Andreas Kling
5a704453af LibWeb: Implement "close a top-level traversable" 2023-08-22 20:30:06 +02:00
MacDue
f3a6fe256f Tests/LibWeb: Add a ref test for many wacky SVG radialGradients
Believe it or not, these are all correct (± a pixel), there meant to
look like that!
2023-08-22 20:25:57 +02:00
MacDue
4ad0ac465e Tests/LibWeb: Update reference for svg-gradient-spreadMethod.html 2023-08-22 20:25:57 +02:00
MacDue
bf55b49070 LibGfx: Fix SVG/canvas radial gradients with focal point != start center
Previously, it was assumed the focal point was the center of the start
circle. This is only the case if the start radius is zero or the centers
of the start and end circle are the same.

This was pretty hard to spot until repeating SVG radial gradients where
added, where the maths broke near the focal point.
2023-08-22 20:25:57 +02:00
Sam Atkins
c171810030 LibWeb: Make CalculatedStyleValue::dump() infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
7fe97ee6c5 LibWeb: Make StyleValue::to_string() infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
ccfe197e5a LibWeb: Make serializing CSS Parser types infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
846c719e49 LibWeb: Make serializing Supports rules infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
91114c157b LibWeb: Make serializing selectors infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
afa27bad19 LibWeb: Make serializing media-queries infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
2754c16e97 LibWeb: Make serializing GridTrack classes infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
6bee81cfb6 LibWeb: Make serializing basic CSS types infallible 2023-08-22 17:51:48 +01:00
Sam Atkins
b5893ee115 LibWeb: Make Serialize functions infallible 2023-08-22 17:51:48 +01:00
Andreas Kling
788c2c5a8d LibWeb: Stop using fallible JSON API in code generators 2023-08-22 13:08:24 +02:00
Andreas Kling
20ea82bacc LibWeb: Make (snake/title/camel) casification functions infallible 2023-08-22 13:08:24 +02:00
Andreas Kling
0b83717ea2 AK: Make SourceGenerator::fork() infallible 2023-08-22 13:08:24 +02:00