Commit graph

42046 commits

Author SHA1 Message Date
kleines Filmröllchen
7c05eed487 Kernel: Bake version information into the Kernel
This is done by generating a Kernel/Version.h header with major version,
minor version, and git hash.
2022-10-14 13:45:33 +02:00
Timothy Slater
92c203bba2 PixelPaint: Change BucketTool and WandTool to use new Bitmap flood fill
This updates the Bucket and Wand tools to leverage the new flood fill
algorithm added to Gfx::Bitmap instead of implementing it in each tool.
2022-10-14 13:39:33 +02:00
Timothy Slater
eec881ea34 LibGfx: Implement flood fill algorithm in Bitmap class
This change implements a flood fill algorithm for the Bitmap class. This
will be leveraged by various Tools in PixelPaint. Moving the code into
Bitmap reduces the duplication of the algorithm throughout the
PixelPaint Tools (currently Bucket Tool and Wand Select).

The flood fill function requires you to pass in a threshold value (0 -
100) as well as a lambda for what to do when a pixel gets reached. The
lambda is provided an IntPoint representing the coordinates of the pixel
that was just reached.

The genericized lambda approach allows for a variety of things to be
done as the flood algorithm progresses. For example, the Bucket Tool
will paint each pixel that gets reached with the fill_color. The Wand
Select tool wont actually alter the bitmap itself, instead it uses the
reached pixels to alter a selection mask.
2022-10-14 13:39:33 +02:00
demostanis
6933644b2e Base: Add more glyphs
This patch adds U+2504, U+256D, U+256E, U+256F and U+2570
to Csilla Regular, as well as U+2022 to Csilla Bold.
They are used by the Kakoune port.
2022-10-14 13:37:29 +02:00
demostanis
fe94636ac3 Ports: Add a kakoune port 2022-10-14 13:37:29 +02:00
demostanis
6880359064 LibVT: Make Terminal::clear_in_line() keep line attributes 2022-10-14 13:37:29 +02:00
demostanis
09a2db89c9 LibC: Add ffs{,l,ll}
Those are wrappers around AK::bit_scan_forward().
2022-10-14 13:37:29 +02:00
demostanis
aa788581f2 AK: Make StringUtils::matches() handle escaping 2022-10-14 13:37:29 +02:00
Gunnar Beutner
70f4d943be Kernel+LibC: Add registers for AARCH64 in __mcontext 2022-10-14 13:01:13 +02:00
Gunnar Beutner
b7555419f1 Kernel: Remove -nodefaultlibs compiler options
This was necessary until a few months ago because of b0rked toolchain
options.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
3065577b54 Everywhere: Enable building userspace and test binaries on AARCH64
Surely this will just work once the kernel boots, right?
2022-10-14 13:01:13 +02:00
Gunnar Beutner
a7a71be113 LibC: Fix some compiler errors
__x86_64__ isn't defined at all on AARCH64.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
808c43312d Tests+Userland: Implement AARCH64 support for some inline assembly blobs 2022-10-14 13:01:13 +02:00
Gunnar Beutner
dadf656dc9 Tests+Userland: Prefer using __builtin_trap() instead of UD2
This way we don't have to hard-code per-architecture instructions.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
7a8206197e AK: Stub out the NAKED macro on AARCH64
This is almost certainly incorrect but we'll see about that once
the kernel actually gets to userspace init.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
5921df75b6 Kernel: Implement userspace support for syscalls on AARCH64
There are no guarantees that the final syscall API will look like this
but at least for now this lets us compile the userland binaries.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
a650c74b27 AK+Toolchain: Make char and wchar_t behave on AARCH64
By default char and wchar_t are unsigned on AARCH64. This fixes a
bunch of related compiler errors.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
31bd5b1a02 AK+Userland: Stub out code that isn't currently implemented on AARCH64
Even though this almost certainly wouldn't run properly even if we had
a working kernel for AARCH64 this at least lets us build all the
userland binaries.
2022-10-14 13:01:13 +02:00
Gunnar Beutner
c18c84dbfd Toolchain: Fix building libgcc for AARCH64
There was a typo in one of the spec files which resulted in us not
building softfp support for libgcc. Additionally we were missing flags
to build libgcc_s. This patch also makes sure we're not trying to
link against crtbeginS.o and crtendS.o. This is part of a larger effort
to at least get the userland to build at all.
2022-10-14 13:01:13 +02:00
Tim Schumacher
24987e2b1f Toolchain: Add SerenityOS to the LLVM config.guess 2022-10-14 12:57:55 +02:00
leeight
bb39f70efc WindowServer: Avoid window nullptr exception
If `window` is nullptr, we should return as soon as possible to
avoid segment fault runtime error.
2022-10-14 11:42:36 +02:00
cflip
30be638fb2 Ports/zlib: Update to 1.2.13 2022-10-14 11:37:25 +02:00
Lucas CHOLLET
99cd6f66cf Base: Launch CrashDaemon at session start-up 2022-10-14 11:37:11 +02:00
Lucas CHOLLET
3197c1793a Base: Launch Clipboard at session start-up
The clipboard service hasn't been ported to user-based portals with
others services as it is needed at `GUI::Application` creation and thus
before the first login, as the `LoginServer` needs one.

This problem as been solved thanks to session-based portals, a clipboard
portal is now created at boot for the "login" session and another for
each "user" session.

With a user-based portal, the "login" portal would have needed to be
created for the `root` user, exposing us to security issues. It now, can
be owned by the `window` user.
2022-10-14 11:37:11 +02:00
davidot
1be337353b LibJS: Make sure to exactly add nanoseconds in add_duration
If the given nanoseconds values add to something above 2**53 - 1 we are
potentially rounding the double to some near integer value.
2022-10-14 11:23:50 +02:00
davidot
1b0ca52c54 LibJS: Disallow one day long time zone offsets
This is a normative change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/9cc8b29b
2022-10-14 11:23:50 +02:00
leeight
1167fdb17a LibWeb: Make LoadRequest headers case insensitive 2022-10-14 11:23:36 +02:00
ne0ndrag0n
9b61579aa6 Base: Mark NetworkSettings as requiring root 2022-10-14 11:23:06 +02:00
ne0ndrag0n
2affe67c75 Settings: Support for launching settings apps as root 2022-10-14 11:23:06 +02:00
ne0ndrag0n
7fc22896ee LibDesktop: Add support for RequiresRoot option to AppFile 2022-10-14 11:23:06 +02:00
ne0ndrag0n
b4456ecdbb Escalator: Add new method to privilege escalate within GUI 2022-10-14 11:23:06 +02:00
Hendiadyoin1
a143d666db AK: Fix aarch64 versions of math functions
These were incorrectly assumed to compile, but did indeed still have
a few issues.
2022-10-14 11:06:28 +02:00
Hendiadyoin1
eb5651870e AK: Add support for some trivial math functions on aarch64
These all require just a single instruction each, we only have to
differentiate between register prefixes accordingly.
2022-10-14 00:28:34 +02:00
Simon Rask
650d2fdc2d LibJS: Add spec comments to String.prototype.at 2022-10-13 21:14:32 +02:00
Simon Rask
8701832095 LibJS: Add spec comments to String.prototype.substring 2022-10-13 21:14:32 +02:00
leeight
1d058ffd72 Documentation: Update VSCodeConfiguration.md
Because x86-64 is the default target, so update the related
documentations.

74018be739
2022-10-13 17:44:49 +02:00
Xexxa
3b9e52cd46 Base: Adjust emoji flag sizes
🇨🇱 - U+1F1E8 U+1F1F1 FLAG: CHILE
🇨🇴 - U+1F1E8 U+1F1F4 FLAG: COLOMBIA
🇨🇵 - U+1F1E8 U+1F1F5 FLAG: CLIPPERTON ISLAND
🇨🇷 - U+1F1E8 U+1F1F7 FLAG: COSTA RICA
🇨🇺 - U+1F1E8 U+1F1FA FLAG: CUBA
🇨🇼 - U+1F1E8 U+1F1FC FLAG: CURAÇAO
🇨🇿 - U+1F1E8 U+1F1FF FLAG: CZECHIA
🇩🇪 - U+1F1E9 U+1F1EA FLAG: GERMANY
🇩🇯 - U+1F1E9 U+1F1EF FLAG: DJIBOUTI
🇩🇰 - U+1F1E9 U+1F1F0 FLAG: DENMARK
🇩🇴 - U+1F1E9 U+1F1F4 FLAG: DOMINICAN REPUBLIC
🇪🇦 - U+1F1EA U+1F1E6 FLAG: CEUTA & MELILLA
🇪🇬 - U+1F1EA U+1F1EC FLAG: EGYPT
🇪🇸 - U+1F1EA U+1F1F8 FLAG: SPAIN
🇫🇲 - U+1F1EB U+1F1F2 FLAG: MICRONESIA
🇫🇷 - U+1F1EB U+1F1F7 FLAG: FRANCE
🇬🇦 - U+1F1EC U+1F1E6 FLAG: GABON
🇬🇳 - U+1F1EC U+1F1F3 FLAG: GUINEA
🇬🇷 - U+1F1EC U+1F1F7 FLAG: GREECE
🇬🇹 - U+1F1EC U+1F1F9 FLAG: GUATEMALA
🇬🇼 - U+1F1EC U+1F1FC FLAG: GUINEA-BISSAU
🇬🇾 - U+1F1EC U+1F1FE FLAG: GUYANA
🇭🇰 - U+1F1ED U+1F1F0 FLAG: HONG KONG SAR CHINA
🇭🇲 - U+1F1ED U+1F1F2 FLAG: HEARD & MCDONALD ISLANDS
🇭🇺 - U+1F1ED U+1F1FA FLAG: HUNGARY
🇮🇨 - U+1F1EE U+1F1E8 FLAG: CANARY ISLANDS
🇮🇩 - U+1F1EE U+1F1E9 FLAG: INDONESIA
🇮🇷 - U+1F1EE U+1F1F7 FLAG: IRAN
🇮🇹 - U+1F1EE U+1F1F9 FLAG: ITALY
🇰🇷 - U+1F1F0 U+1F1F7 FLAG: SOUTH KOREA
🇱🇰 - U+1F1F1 U+1F1F0 FLAG: SRI LANKA
🇱🇹 - U+1F1F1 U+1F1F9 FLAG: LITHUANIA
🇱🇺 - U+1F1F1 U+1F1FA FLAG: LUXEMBOURG
🇱🇻 - U+1F1F1 U+1F1FB FLAG: LATVIA
🇲🇨 - U+1F1F2 U+1F1E8 FLAG: MONACO
🇲🇫 - U+1F1F2 U+1F1EB FLAG: ST. MARTIN
🇲🇬 - U+1F1F2 U+1F1EC FLAG: MADAGASCAR
🇲🇲 - U+1F1F2 U+1F1F2 FLAG: MYANMAR (BURMA)
🇲🇺 - U+1F1F2 U+1F1FA FLAG: MAURITIUS
🇲🇼 - U+1F1F2 U+1F1FC FLAG: MALAWI
🇳🇦 - U+1F1F3 U+1F1E6 FLAG: NAMIBIA
🇳🇪 - U+1F1F3 U+1F1EA FLAG: NIGER
🇳🇱 - U+1F1F3 U+1F1F1 FLAG: NETHERLANDS
🇳🇷 - U+1F1F3 U+1F1F7 FLAG: NAURU
🇵🇪 - U+1F1F5 U+1F1EA FLAG: PERU
🇵🇭 - U+1F1F5 U+1F1ED FLAG: PHILIPPINES
🇵🇱 - U+1F1F5 U+1F1F1 FLAG: POLAND
🇷🇪 - U+1F1F7 U+1F1EA FLAG: RÉUNION
🇸🇮 - U+1F1F8 U+1F1EE FLAG: SLOVENIA
🇸🇰 - U+1F1F8 U+1F1F0 FLAG: SLOVAKIA
🇸🇱 - U+1F1F8 U+1F1F1 FLAG: SIERRA LEONE
🇸🇴 - U+1F1F8 U+1F1F4 FLAG: SOMALIA
🇸🇷 - U+1F1F8 U+1F1F7 FLAG: SURINAME
🇸🇸 - U+1F1F8 U+1F1F8 FLAG: SOUTH SUDAN
🇸🇾 - U+1F1F8 U+1F1FE FLAG: SYRIA
🇹🇩 - U+1F1F9 U+1F1E9 FLAG: CHAD
🇹🇴 - U+1F1F9 U+1F1F4 FLAG: TONGA
🇹🇷 - U+1F1F9 U+1F1F7 FLAG: TURKEY
🇹🇼 - U+1F1F9 U+1F1FC FLAG: TAIWAN
🇺🇦 - U+1F1FA U+1F1E6 FLAG: UKRAINE
🇺🇳 - U+1F1FA U+1F1F3 FLAG: UNITED NATIONS
🇺🇾 - U+1F1FA U+1F1FE FLAG: URUGUAY
🇺🇿 - U+1F1FA U+1F1FF FLAG: UZBEKISTAN
🇻🇨 - U+1F1FB U+1F1E8 FLAG: ST. VINCENT & GRENADINES
🇻🇪 - U+1F1FB U+1F1EA FLAG: VENEZUELA
🇼🇸 - U+1F1FC U+1F1F8 FLAG: SAMOA
🇾🇪 - U+1F1FE U+1F1EA FLAG: YEMEN
🇿🇦 - U+1F1FF U+1F1E6 FLAG: SOUTH AFRICA
2022-10-13 17:43:33 +02:00
Xexxa
25eb366a33 Base: Adjust emoji (remove corner pixel for 3D feel)
📔 - U+1F4D4 NOTEBOOK WITH DECORATIVE COVER
📕 - U+1F4D5 CLOSED BOOK
📗 - U+1F4D7 GREEN BOOK
📘 - U+1F4D8 BLUE BOOK
📙 - U+1F4D9 ORANGE BOOK
📓 - U+1F4D3 NOTEBOOK
📒 - U+1F4D2 LEDGER
2022-10-13 17:43:33 +02:00
Xexxa
597750c077 Base: Add more emoji
👁️‍🗨️ - U+1F441 U+200D U+1F5E8 EYE IN SPEECH BUBBLE
🦷 - U+1F9B7 TOOTH
🧜‍♀️ - U+1F9DC U+200D U+2640 MERMAID
🏌️‍♂️ - U+1F3CC U+200D U+2642 MAN GOLFING
🏌️‍♀️ - U+1F3CC U+200D U+2640 WOMAN GOLFING
🏊‍♂️ - U+1F3CA U+200D U+2642 MAN SWIMMING
🏊‍♀️ - U+1F3CA U+200D U+2640 WOMAN SWIMMING
🏋️‍♂️ - U+1F3CB U+200D U+2642 MAN LIFTING WEIGHTS
🏋️‍♀️ - U+1F3CB U+200D U+2640 WOMAN LIFTING WEIGHTS
🦓 - U+1F993 ZEBRA
🐮 - U+1F42E COW FACE
🥖 - U+1F956 BAGUETTE BREAD
🏺 - U+1F3FA AMPHORA
🚂 - U+1F682 LOCOMOTIVE
🚃 - U+1F683 RAILWAY CAR
🛶 - U+1F6F6 CANOE
🛍️ - U+1F6CD SHOPPING BAGS
💴 - U+1F4B4 YEN BANKNOTE
💵 - U+1F4B5 DOLLAR BANKNOTE
💶 - U+1F4B6 EURO BANKNOTE
💷 - U+1F4B7 POUND BANKNOTE
🪚 - U+1FA9A CARPENTRY SAW
🚽 - U+1F6BD TOILET
🚿 - U+1F6BF SHOWER
☣️ - U+2623 BIOHAZARD
📳 - U+1F4F3 VIBRATION MODE
♻️ - U+267B RECYCLING SYMBOL
⚜️ - U+269C FLEUR-DE-LIS
2022-10-13 17:43:33 +02:00
Xexxa
f912fb3f08 Base: Adjust emoji (colour scheme consistency)
🏌️ - U+1F3CC PERSON GOLFING
🏋️ - U+1F3CB PERSON LIFTING WEIGHTS
2022-10-13 17:43:33 +02:00
Luke Wilde
bf2debdf53 LibWeb: Make navigator.languages an attribute instead of a function 2022-10-13 14:42:14 +02:00
demostanis
1eac02c9a4 CatDog: Make it always on top 2022-10-13 12:37:54 +01:00
demostanis
63a18aa89e LibGUI+WindowServer: Add Window::set_always_on_top() 2022-10-13 12:37:54 +01:00
Timon Kruiper
50e74de279 Kernel: Add StdLib.cpp and UserOrKernelBuffer.cpp to aarch64 build
Also remove UserOrKernelBuffer::{read, write} and __stack_chk_fail from
Dummy.cpp and init.cpp respectively.
2022-10-13 11:26:46 +02:00
Andrew Kaster
290d3449e0 LibVideo: Hide debug message behind MATROSKA_DEBUG
This clutters fuzzer output if enabled.
2022-10-13 11:25:03 +02:00
Andrew Kaster
b704f82487 Fuzzers: Add VP9Decoder and MatroskaReader fuzzers for LibVideo 2022-10-13 11:25:03 +02:00
Andrew Kaster
bf014c4d20 LibVideo: Check parsed superframe sizes when decoding VP9 frames
Make sure that the next parsed superframe size will not overflow the
chunk data before splitting it out to decode a frame.
2022-10-13 11:25:03 +02:00
Andrew Kaster
9d3074f72f LibVideo: Always check byte length before reading first byte in Streamer
The check was missing at the front of
MatroskaReader::Streamer::read_variable_size_integer, causing assertions
on malformed input streams.
2022-10-13 11:25:03 +02:00
MacDue
4507920187 LibWeb: Fix position: fixed canvases/images disappearing when scrolling
This fixes the Serenity logo vanishing after scrolling on the 4th
birthday post.

The previous check did not account for any translation in the painter.
This now uses the painter's clip rect and translation to work out
if a rect is visible. It also makes use of `absolute_paint_rect()`
rather than `absolute_rect()` which can account for things like
box-shadows.
2022-10-13 11:16:27 +02:00
Maxwell Trussell
f5e68fcc20 Utilities: Add pkill 2022-10-13 11:15:33 +02:00