Commit Graph

3366 Commits

Author SHA1 Message Date
Andreas Kling
7f5e960b72 AK: Remove unused UUID class 2024-06-18 12:00:14 +02:00
Andreas Kling
47287d2cf1 AK: Remove kstdio.h and dbgputstr()
We can just write directly to stderr in the one place this was used.
2024-06-18 12:00:14 +02:00
Andreas Kling
6df5785fc4 AK: Remove unused PrintfImplementation.h 2024-06-18 12:00:14 +02:00
Andreas Kling
fa56b6cca0 Meta/Lagom: Remove unused StateMachineGenerator 2024-06-18 12:00:14 +02:00
Andreas Kling
1039acca8c LibGfx: Remove JPEG2000 image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
a34a5af939 LibGfx: Remove ILBM image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
b6daddb088 LibGfx: Remove JBIG2 image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
b7f8d7aec5 LibGfx: Remove TGA image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
681a2ac14e LibGfx: Remove support for the various "portable" image formats
These formats are not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
7141319a7c LibGfx: Remove DDS image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
4b4254c3d0 LibGfx: Remove QOI image format support
This format is not supported by other browsers.
2024-06-17 21:57:35 +02:00
Andreas Kling
2a888ca626 LibGfx: Remove home-grown JPEG codec in favor of libjpeg-turbo 2024-06-17 17:59:54 +02:00
Timothy Flynn
56e9eb6f68 Meta: Restore a couple debug flags in all_the_debug_macros.cmake
These were errantly removed in 666f7338a0.
2024-06-16 15:30:28 -04:00
Matthew Olsson
7950992fc2 LibWeb: Remove TimingFunction in favor of EasingStyleValue::Function
Now that EasingStyleValue is a lot nicer to use, there isn't much reason
to keep TimingFunction around.
2024-06-16 07:12:46 +02:00
Matthew Olsson
ac35f76e67 Meta: Remove GenerateCSSEasingFunctions 2024-06-16 07:12:46 +02:00
Timothy Flynn
6675ef3f24 CI+LibLocale: Remove the CLDR from the system 2024-06-16 06:57:08 +02:00
Timothy Flynn
4de8adabac LibLocale: Replace available locale lookups with ICU 2024-06-16 06:57:08 +02:00
Timothy Flynn
1bcc29d0d1 LibJS+LibLocale: Replace Unicode keyword lookups with ICU
Note: All of the changes to the test files in this patch are now aligned
with both Chrome and Firefox.
2024-06-16 06:57:08 +02:00
Timothy Flynn
5e2ee4447e LibJS+LibLocale: Replace plural rules selection with ICU
This uses ICU for all of the Intl.PluralRules prototypes, which lets us
remove all data from our plural rules generator.

Plural rules depend directly on internal data from the number formatter,
so rather than creating a separate Locale::PluralRules class (which will
make accessing that data awkward), this adds plural rules APIs to the
existing Locale::NumberFormat.
2024-06-15 06:57:16 +02:00
Timothy Flynn
7f9ccd39f5 LibJS+LibLocale: Replace relative time formatting with ICU
This uses ICU for all of the Intl.RelativeTimeFormat prototypes, which
lets us remove all data from our relative-time format generator.
2024-06-15 06:57:16 +02:00
Timothy Flynn
f9a7fc6263 LibLocale: Remove the number formatting data generator
The last user of the remaining data (Intl.DurationFormat) no longer
consumes these APIs.
2024-06-14 07:59:42 +02:00
Aliaksandr Kalenik
8feaecd5c8 LibWeb: Create BlockContainer layout node for <input type="button">
...and shadow tree with TextNode for "value" attribute is created.
This means InlineFormattingContext is used, and button's text now
respects CSS text-decoration properties and unicode-ranges.
2024-06-14 07:58:55 +02:00
Diego
991759f453 LibWasm: Enable the loop.wast test file 2024-06-13 12:15:20 +02:00
Luke Warlow
ee64684565 LibWeb: Add Contrast preference 2024-06-13 11:18:38 +02:00
Timothy Flynn
4b3e26c583 LibJS+LibLocale: Replace calendar weekday information with ICU 2024-06-13 07:42:09 +02:00
Timothy Flynn
9cb1857dc6 LibJS+LibLocale: Replace preferred hour cycle lookups with ICU 2024-06-13 07:42:09 +02:00
Timothy Flynn
e2bffe5612 LibJS+LibLocale: Replace time zone display names with ICU 2024-06-13 07:42:09 +02:00
Timothy Flynn
273694d8de LibJS+LibLocale: Replace date-time formatting with ICU
This uses ICU for the Intl.DateTimeFormat `format` `formatToParts`,
`formatRange`, and `formatRangeToParts`.

This lets us remove most data from our date-time format generator. All
that remains are time zone data and locale week info, which are relied
upon still for other interfaces. So they will be removed in a future
patch.

Note: All of the changes to the test files in this patch are now aligned
with other browsers. This includes:

* Some very incorrect formatting of Japanese symbols. (Looking at the
  old results now, it's very obvious they were wrong.)
* Old FIXMEs regarding range formatting not including the start/end date
  when only time fields were requested, but the dates differ.
* Day period inconsistencies.
2024-06-13 07:42:09 +02:00
Tim Ledbetter
2f5cf8ac20 LibIDL+LibWeb: Mark [FIXME] interfaces as [[Unimplemented]]
Methods and attributes marked with [FIXME] are now implemented as
direct properties with the value `undefined` and are marked with the
[[Unimplemented]] attribute. This allows accesses to these properties
to be reported, while having no other side-effects.

This fixes an issue where [FIXME] methods broke feature detection on
some sites.
2024-06-11 16:33:30 +02:00
Diego
40fcb00c14 LibWasm: Add missing spec-test imports 2024-06-11 02:43:55 +02:00
Tim Ledbetter
fd98076aca Meta: Ensure LibURL tests are built 2024-06-10 20:34:57 -04:00
circl
5d2095279d Meta: Remove references to SerenityOS in the gn build README 2024-06-10 13:53:01 +02:00
circl
4509d08dde Meta: Add BINDINGS_GENERATOR_DEBUG macro back to gn build 2024-06-10 13:53:01 +02:00
Timothy Flynn
67f3de2320 LibJS+LibLocale: Begin replacing number formatting with ICU
This uses ICU for the Intl.NumberFormat `format` and `formatToParts`
prototypes. It does not yet port the range formatter prototypes.

Most of the new code in LibLocale/NumberFormat is simply mapping from
ECMA-402 types to ICU types. Beyond that, the only algorithmic change is
that we have to mutate the output from ICU for `formatToParts` to match
what is expected by ECMA-402. This is explained in NumberFormat.cpp in
`flatten_partitions`.

This lets us remove most data from our number format generator. All that
remains are numbering system digits and symbols, which are relied upon
still for other interfaces (e.g. Intl.DateTimeFormat). So they will be
removed in a future patch.

Note: All of the changes to the test files in this patch are now aligned
with both Chrome and Safari.
2024-06-10 13:51:51 +02:00
Andreas Kling
c096608dd9 Meta: Update for GitHub org rename to LadybirdBrowser 2024-06-09 13:02:56 +02:00
Diego
9235c3268f LibWasm: Generate all spec-tests properly 2024-06-09 12:16:17 +02:00
circl
666f7338a0 Meta+AK: Clear out unused debug macro definitions 2024-06-09 10:48:19 +02:00
Timothy Flynn
5f7251fd91 LibJS+LibLocale: Replace list formatting with ICU
This also largely eliminates the need for some ECMA-402 AOs, as is it
all handled internally by ICU (which the spec is basically based on).
2024-06-09 10:47:28 +02:00
Timothy Flynn
d17d131224 LibJS+LibLocale: Replace locale character ordering with ICU 2024-06-09 10:47:28 +02:00
Timothy Flynn
e487f91388 LibJS+LibLocale: Replace locale maximization and minimization with ICU 2024-06-09 10:47:28 +02:00
Timothy Flynn
9724a25daf LibJS+LibLocale: Replace canonical locales and display names with ICU
Note: We keep locale parsing and syntactic validation as-is. ECMA-402
places additional restrictions on locales above what is required by the
Unicode spec. ICU doesn't provide methods that let us easily check those
restrictions, whereas LibLocale does. Other browsers also implement
their own validators here.

This introduces a locale cache to re-use parsed locale data and various
related structures (not doing so has a non-negligible performance impact
on Intl tests).

The existing APIs for canonicalization and display names are pretty
intertwined, so they must both be adapted at once here. The results of
canonicalization are slightly different on some edge cases. But the
changed results are actually now aligned with Chrome and Safari.
2024-06-09 10:47:28 +02:00
Andreas Kling
2f68e36137 Ladybird: Use fontconfig to choose generic fonts on non-Apple systems
If we get a suggestion from fontconfig, we try those fonts first, before
falling back on the hard coded list of known suitable fonts for each
generic family.
2024-06-08 10:23:36 +02:00
Andrew Kaster
9f25dc6b09 CMake+CI: Remove BUILD_LAGOM=OFF option in favor of LAGOM_TOOLS_ONLY=ON
The far more common configuration for Ladybird is to always build the
Lagom libraries.
2024-06-08 07:58:11 +02:00
Andrew Kaster
1af9e44130 CMake: Use CMAKE_LINKER_TYPE on CMake >= 3.29 2024-06-08 07:58:11 +02:00
Andreas Kling
28d4e326f8 LibGfx: Use the woff2 library to decode WOFF2 font files
This saves us the trouble of maintaining our own implementation,
and instantly brings us to full WOFF2 feature parity with others.

Co-Authored-By: Andrew Kaster <akaster@serenityos.org>
2024-06-07 18:42:12 +02:00
Andrew Kaster
1e3e36af11 Meta+CMake: Move vcpkg directives to ladybird.sh and CMakePresets
Also add a vcpkg command to ladybird.sh to ensure that vcpkg is setup,
and use a local binary cache for vcpkg build and install media to
avoid cluttering $XDG_CACHE_HOME.
2024-06-07 11:15:48 -04:00
Jamie Mansfield
8f0d035145 LibWeb: Implement should block mixed content request 2024-06-07 09:50:30 +02:00
Andrew Kaster
d90a9ab70c LibWeb: Add Web::UIEvents::KeyCode and KeyModifier enums, drop Kernel
This was the last Kernel header we had. Move the definitions we need
into a UIEvents header similar to MouseButton.
2024-06-07 09:44:41 +02:00
Andrew Kaster
82b73b2eee CMake: Move ca_certificate_download include up with other downloads 2024-06-06 12:51:14 -06:00
Andrew Kaster
6f387577c5 CMake+Base: Remove LiberationMono and rules copying it to build
This was only used by the pdf and MacPDF applications.
2024-06-06 12:51:14 -06:00
Andrew Kaster
41176a4f4e CMake: Remove Superbuild-specific install rule guard 2024-06-06 12:51:14 -06:00
Andrew Kaster
f55f64755d CMake: Remove ENABLE_LAGOM_LIBWEB and ENABLE_LAGOM_LADYBIRD options 2024-06-06 12:51:14 -06:00
Andrew Kaster
b5a60c0f9f Meta: Link librt to LibCoreMinimal on NetBSD
We were already linking librt to LibCore for shm_open and friends.
Now that we build the code that uses POSIX shm into LibCoreMinimal, we
need to link librt into that as well.
2024-06-06 12:48:58 -06:00
Timothy Flynn
8362c073f3 Everywhere: Remove LibSQL, SQLServer, and the sql REPL :^)
It is now entirely unused and replaced by sqlite3.
2024-06-06 11:27:03 -04:00
Timothy Flynn
b36ab480bf Meta+Toolchain+CI: Add a script to bootstrap vcpkg
And hook it into ladybird.sh for convenience. The script will set up
PATH and other environment variables automatically.

On CI, vcpkg is theoretically already installed on Linux machines, but
not with the right environment variables, and not on macOS. So this also
makes CI use this script to bootstrap vcpkg.
2024-06-06 11:27:03 -04:00
Davide Cavalca
9af91eb622 Meta: ENABLE_NETWORK_DOWNLOADS for ca_certificates and public_suffix 2024-06-05 13:03:31 -04:00
Andrew Kaster
90af26e309 Meta+CMake: Remove unused CMake functions and features
Goodbye, serenity_components and Jakt.
2024-06-05 12:23:54 -04:00
Andrew Kaster
ec6072e7cd Meta: Uncouple ladybird.sh run from a specific CMake configuration 2024-06-05 12:21:59 -04:00
Nathan E. Egge
e62f0a8da3 Meta: Remove dependency on sudo, doas or pls 2024-06-05 12:04:11 -04:00
Andreas Kling
d0afc3e643 CI: Remove "label pull requests" action 2024-06-05 10:49:45 +02:00
Jamie Mansfield
8e062a52a3 LibWeb: Move NetworkPartitionKey into a header
This is used elsewhere, such as the HTMLLinkElement.
2024-06-05 05:42:47 +01:00
Andrew Kaster
c6e9f0e7b5 Meta+Documentation: Switch default build dir to Build/Ladybird
Also prefer using the new top-level CMakeLists.txt
2024-06-04 13:44:22 -06:00
Andreas Kling
cd84d23afa Base+Tests+Ladybird: Remove bitmap fonts 2024-06-04 18:45:30 +02:00
Andreas Kling
04a6e2f83d LibWeb: Remove Gfx::BitmapFont
This class supported the binary bitmap font file format in SerenityOS,
and isn't something we need in Ladybird.
2024-06-04 18:45:30 +02:00
Andreas Kling
966d442152 LibWeb+Ladybird: Remove FontPluginSerenity (+ use Ladybird::FontPlugin) 2024-06-04 18:45:30 +02:00
Andreas Kling
1b2d08ee7e LibGfx: Remove a bunch of unused classes 2024-06-04 18:45:30 +02:00
Simon Wanner
0ab4722cee LibTextCodec: Use generated lookup tables for all single byte decoders 2024-06-04 10:21:07 +02:00
Simon Wanner
6b2c459901 LibTextCodec: Fix ISO-8859-1 vs. windows-1252 handling in web contexts
The Encoding specification maps ISO-8859-1 to windows-1252 and expects
the windows-1252 translation table to be used, which differs from
ISO-8859-1 for 0x80-0x9F.

Other contexts expect to get the actual ISO-8859-1 encoding, with 1-to-1
mapping to U+0000-U+00FF, when requesting it.

`decoder_for_exact_name` is introduced, which skips the mapping from
aliases to the encoding name done by `get_standardized_encoding`.
2024-06-04 10:21:07 +02:00
Andreas Kling
6321e97b09 AK: Remove various unused things 2024-06-04 09:19:39 +02:00
Andreas Kling
f2fd8fc928 Everywhere: Remove LibGemini
This hasn't been maintained (or worked at all) for a long time,
and it's not a widely supported protocol, so let's drop it.
2024-06-04 09:19:39 +02:00
Andreas Kling
e4cd91761d Everywhere: Remove LibMarkdown
This was used to convert markdown into HTML for display in the browser,
but no other browser behaves this way, so let's simplify things by
removing it.

(Yes, we could implement all kinds of "convert to HTML and display" for
every file format out there, but that's far outside the scope of a
browser engine.)
2024-06-04 09:19:39 +02:00
Timothy Flynn
126cbce632 Meta: Remove empty LibSystem library and references 2024-06-04 07:45:42 +02:00
Timothy Flynn
f5ed7d5d9c Meta: Remove base64 utility from the GN build 2024-06-04 07:45:42 +02:00
Timothy Flynn
a089c00e02 Meta: Remove unused SerenityOS references from the GN build 2024-06-04 07:45:42 +02:00
Timothy Flynn
d28412ed34 Meta: Remove unused (and non-existent) linkages from the GN build 2024-06-04 07:45:42 +02:00
Timothy Flynn
0cb1564615 Meta: Removed unused LibVT from the GN build 2024-06-04 07:45:42 +02:00
Federico Guerinoni
0e02279b5d Documentation: Update instruction for building with QtCreator 2024-06-03 13:19:00 -06:00
Timothy Flynn
bdbe2fdcc5 Everywhere: Replace SERENITY_SOURCE_DIR with LADYBIRD_SOURCE_DIR
In order to have checkouts of both SerenityOS and Ladybird, we need to
use a different environment variable for Ladybird.
2024-06-03 15:57:59 +02:00
Andreas Kling
e70d96e4e7 Everywhere: Remove a lot more things we don't need 2024-06-03 10:53:53 +02:00
Andreas Kling
421aa7c475 Everywhere: Remove more unused components 2024-06-03 10:53:53 +02:00
Andrew Kaster
9dd24991a8 Documentation: Remove references to serenity.sh and its build configs
Build/lagom only now.
2024-06-03 10:53:53 +02:00
Andrew Kaster
faeff81ce9 Meta: Rename serenity.sh to ladybird.sh and remove non-lagom commands 2024-06-03 10:53:53 +02:00
Andrew Kaster
9b05fb98f3 CMake: Remove unused files 2024-06-03 10:53:53 +02:00
Tim Ledbetter
44c8d42157 Fuzzers: Remove fuzzers for non-existent libraries 2024-06-03 10:53:53 +02:00
Tim Ledbetter
1a4fbfe495 Everywhere: Remove references to the kernel 2024-06-03 10:53:53 +02:00
Tim Ledbetter
d147ed8549 Meta: Remove references to LibC 2024-06-03 10:53:53 +02:00
Tim Ledbetter
3e56835611 Everywhere: Remove references to non-existent paths 2024-06-03 10:53:53 +02:00
Andrew Kaster
6d3a54e4a8 Meta: Update Documentation and CI for repo move 2024-06-03 10:53:53 +02:00
Andrew Kaster
dd1fbd3513 Meta: Remove SerenityOS components not needed for Ladybird 2024-06-03 10:53:53 +02:00
Matthew Olsson
74840de7fc LibWeb: Generate a method to get camel-cased CSS property names 2024-06-03 10:53:32 +02:00
Timothy Flynn
d4734e920c Meta: Define HAVE_QT when building WebContent for Qt in the GN build
For some reason, WebContent fails to load simple sites like xkcd.com
without the Qt event loop, even when using RequestServer instead of the
Qt networking stack. The CMake build on Linux has the same issue if we
skip installing the Qt event loop. It's not clear why this is - whether
something depends on the Qt event loop, or if there's a bug in the Unix
event loop implementation.

This is, however, also needed to use the --enable-qt-networking feature.
2024-06-02 15:52:28 -04:00
Timothy Flynn
951aa44f87 Meta: Use the host CXX tool for linking as well
For example, if you set host_cxx=clang in your args.gn, we would still
use GCC for linking. This matches the CMake build now.
2024-06-02 15:52:28 -04:00
Timothy Flynn
847ee6e266 Meta: Do not launch linker commands with ccache 2024-06-02 15:52:28 -04:00
Timothy Flynn
017009437d Meta: Update compilation flags in the GN build to match the CMake build 2024-06-02 15:52:28 -04:00
Diego
d906255cbb LibWasm: Improve table support
Implements `table.get`, `table.set`, `elem.drop`, `table.size`,
and `table.grow`. Also fixes a few issues when generating ref-related
spectests. Also changes the `TableInstance` type to use
`Vector<Reference>` instead of `Vector<Optional<Reference>>`, because
the ability to be null is already encoded in the `Reference` type.
2024-06-01 16:21:03 +02:00
Daniel Bertalan
30f6cef648 VideoPlayerSDL: Instruct the compiler to search SDL2's include path
On my Mac system with Homebrew SDL + self-built Clang, SDL2's include
directory is not in the library search path by default. Add it to
unbreak the build.
2024-06-01 08:24:01 -04:00
Timothy Flynn
b01e810a89 LibWeb+LibWebView+WebContent: Support case-insensitive find-in-page
This allows searching for text with case-insensitivity. As this is
probably what most users expect, the default behavior is changes to
perform case-insensitive lookups. Chromes may add UI to change the
behavior as they see fit.
2024-06-01 07:37:54 +02:00
Timothy Flynn
ac15c1cc01 Meta: Port recent changes to the GN build
2ce61fe6ea
2024-05-31 10:44:00 -04:00
Timothy Flynn
d6732e5906 Ladybird/AppKit: Implement a basic find-in-page panel 2024-05-31 06:30:39 -04:00
Timothy Flynn
903078e4d1 Meta: Fix detection of QtMultimedia usage on macOS
We use Audio Unit for audio on macOS.
2024-05-31 06:30:39 -04:00