Commit Graph

31950 Commits

Author SHA1 Message Date
Lady Gegga
613edc75b7 Base: Add Emoticons to font Katica Regular 10
1F600, 1F603, 1F606, 1F60E, 1F60F, 1F610, 1F611, 1F615, 1F626, 1F641,
1F642, 1F643
https://www.unicode.org/charts/PDF/U1F600.pdf
2022-01-01 07:48:48 +03:30
Lady Gegga
1c5cb30b80 Base: Add Misc. Symbols and Pictographs to font Katica Regular 10
1F50C, 1F50D, 1F50E, 1F523, 1F524, 1F582, 1F583, 1F5AF, 1F5B0, 1F5B1,
1F5B2, 1F5B4, 1F5B5, 1F5D5, 1F5E8, 1F5E9, 1F5EA, 1F5EB
https://www.unicode.org/charts/PDF/U1F300.pdf
2022-01-01 07:48:48 +03:30
Lady Gegga
7f361aa7e5 Base: Add Dingbats to font Katica Regular 10
2780, 2781, 2782, 2783, 2784, 2785, 2786, 2787, 2788, 2789,
278A, 278B, 278C, 278D, 278E, 278F, 2790, 2791, 2792, 2793
https://www.unicode.org/charts/PDF/U2700.pdf
2022-01-01 07:48:48 +03:30
Lady Gegga
341796c144 Base: Add Chinese characters to font Katica Regular 10
6761, 6762, 4EF0, 4EFA, 4EFB, 4EFC, 4EF4, 4EF2, 4F55, 4F54,
4F43, 4F44, 4F42, 4F46, 4F40, 4ED6, 540E, 5410, 884C, 8840,
8841, 4EE5, 4EE6, 4EE7, 4EE8, 4EE9, 4EEA, 4F1A, 4F1B, 4F1C,
4F1D, 4F1E, 4F1F, 672C, 672B, 672A, 4E3A, 4E39, 4E38, 6240,
5BF9, 5BF8, 793E, 5E94, 5408
https://www.unicode.org/charts/PDF/U4E00.pdf
2022-01-01 07:48:48 +03:30
Lady Gegga
aadc60fd60 Base: Adjust 81EA in font Katica Regular 10
81EA https://www.unicode.org/charts/PDF/U4E00.pdf
2022-01-01 07:48:48 +03:30
drblah
b6ba0f9fad Kernel: Update E1000 link state using interrupt
Calls to link_up() in the E1000 driver would read the link state
directly from the hardware on every call. This had negative
performance impact in high throughput situations since link_up()
is called every time an IP packet's route is resolved.

This patch takes inspiration from the RTL8139 network adapter where
the link state is stored in a bool and only updated when the hardware
generates an interrupt related to link state change.

After this change I measured a ~9% increase in TCP Tx throughput
using:
cat /dev/zero | nc <host_IP> <host_port> from the Serenity VM to my
host machine
2021-12-31 15:48:16 +01:00
Linus Groh
d7f6635d55 LibJS: Add missing undefined fallback to IfStatement completions
Also add spec comments.
2021-12-31 15:39:25 +01:00
Linus Groh
a6476ad61f test-wasm: Convert WebAssemblyModule::create() to ThrowCompletionOr
This exposed a missing exception check in parseWebAssemblyModule(),
which could throw but still return a normal completion (which currently
works as we check VM::exception() at the right point, but breaks when
moving everything to exceptions).
2021-12-31 15:01:16 +01:00
Conor Byrne
faad7a3ed1 LibDiff: Fix error when parsing a 'new' hunk location
If the location started at 0, and / or the length was 0, it would
originally turn out to be a location of { -1, -1 } when LibDiff was
finished parsing, which was incorrect.

To fix this, we only subtract 1 if `start` or `length` isn't 0.
2021-12-31 14:12:54 +01:00
Conor Byrne
507ad1954f HackStudio: Fix crash when clicking unstaged files
In certain cases, an index might be invalid in the unstaged files view.
We must check if this index is valid before attempting to read the
index's data.
2021-12-31 14:12:54 +01:00
davidot
c0a3b1467c LibJS: Fix the Now.plainDateTime in case they go over a year boundary
Since years don't have a constant amount of seconds because they can be
leap years no constant will work in all cases. We now test a timezone in
both the positive and negative direction and check that at least one
worked. Assuming years are at least 2 days long this will always pass
at least one test.
2021-12-31 12:26:26 +01:00
davidot
c296df6b58 LibJS: Convert to_reference() to ThrowCompletionOr 2021-12-31 00:03:20 +01:00
davidot
a24df37713 LibJS: Convert resolve_this_binding() to ThrowCompletionOr
Also add spec comments.
2021-12-31 00:03:20 +01:00
Emanuele Torre
dc03529ffd LibJS: Fix spec comment in Temporal::PlainDate::balance_iso_date()
This matches the text of the spec, and is more correct since the
variable is being updated, not defined it.

See: https://github.com/tc39/proposal-temporal/commit/5ab1822

---

I also changed `test_year += 1` to `test_year++` for consistency with
step 11.c that has the same description.
2021-12-30 23:59:40 +01:00
Ali Mohammad Pur
783e27f8f9 Shell: Make redirection errors raise ShellErrors
Naturally, this means that a command with a failing redirection will
not start, and so will terminate the pipeline (if any).
This also applies to the `exit` run when the shell is closed, fixing a
fun bug there as well (thanks to Discord user Salanty for pointing that
out) where closing the terminal (i.e. I/O error on the tty) with a
failing `exit` command would make the shell retry executing `exit` every
time, leading to an eventual stack overflow.
2021-12-31 02:19:45 +03:30
Ali Mohammad Pur
8de8a7766d LibCore: Add Core::System::setpgid() 2021-12-31 02:19:45 +03:30
Ali Mohammad Pur
ee46cee31f LibCore: Make Core::System::pipe2() available on Lagom
Note that this drops the flags on the floor if not on linux or serenity.
2021-12-31 02:19:45 +03:30
davidot
b303b8cf4e LibJS: Convert thrown exception to completion in binding initialization
This regressed in 676554d3 as it assumed to_reference() (already)
returned a completion type instead of putting the error in
vm.exception().
2021-12-30 20:14:13 +01:00
Daniel Bertalan
7608af13cd Kernel: Use the toolchain's nm in mkmap.sh
By using the binary from our build of binutils, we can be sure that `nm`
supports demangling symbols, so we can avoid spawning a separate
`c++filt` process.
2021-12-30 18:10:51 +01:00
davidot
9d3623f0e8 LibJS: Add and fix some spec comments in AbstractOperations 2021-12-30 15:29:33 +01:00
davidot
d72022ba04 LibJS: Convert get_identifier_reference() to ThrowCompletionOr
And while we're here add spec comments.
2021-12-30 15:29:33 +01:00
davidot
676554d3f8 LibJS: Convert resolve_binding() to ThrowCompletionOr
The spec has a note stating that resolve binding will always return a
reference whose [[ReferencedName]] field is name. However this is not
correct as the underlying method GetIdentifierReference may throw on
env.HasBinding(name) thus it can throw. However, there are some
scenarios where it cannot throw because the reference is known to exist
in that case we use MUST with a comment.
2021-12-30 15:29:33 +01:00
creator1creeper1
dfaa6c910c Utilities/lsusb: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
575a8e6487 Utilities/arp: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
067e32c023 Utilities/netstat: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
9c832e3b0f Utilities/ifconfig: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
d9b3278074 Utilities/notify: Propagate errors in Gfx::Bitmap loading 2021-12-30 14:37:02 +01:00
creator1creeper1
9d6ecdca7b Utilities/lsirq: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
bceddb2073 Utilities/mount: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
creator1creeper1
904c8634eb Utilities/lsof: Propagate errors in JSON decoding 2021-12-30 14:37:02 +01:00
r00ster91
fe2ade13e9 Pong: Support W and S keys for movement 2021-12-30 14:36:21 +01:00
Young-Jin Park
9d74659f3b LibGUI: Fix leading whitespaces when text is wrapped
This commit should fix a bug where using leading whitespaces when a line
is wrapped results in a crash. Now it should correctly highlight the
leading whitespaces even when the leading whitespaces are longer than a
line.
2021-12-30 14:34:01 +01:00
Hendiadyoin1
23037d619a Kernel: Simplify some if statements 2021-12-30 14:32:17 +01:00
Hendiadyoin1
04d75f4ff9 Kernel: Add some implied auto qualifiers 2021-12-30 14:32:17 +01:00
Hendiadyoin1
9346b9589f Kernel: Remove else-after-return statements in CommandLine.cpp 2021-12-30 14:32:17 +01:00
Hendiadyoin1
1db53400ce Kernel: Remove superfluous moves in CommandLine.cpp 2021-12-30 14:32:17 +01:00
Hendiadyoin1
b1aee18078 Kernel: Add missing includes in ThreadTracer and WorkQueue 2021-12-30 14:32:17 +01:00
Elyse
173a84a2ef LibGUI+SoundPlayer: Use 'decrease_slider_by_page_steps()' method
This method allow us to avoid repeating the pattern
'set_value(value() - page_step() * page_number)'.
2021-12-30 14:31:50 +01:00
Elyse
0d660b27ae LibGUI+SoundPlayer: Use 'increase_slider_by_page_steps()'
This method allow us to avoid repeating the pattern
'set_value(value() + page_step() * page_number)'.
2021-12-30 14:31:50 +01:00
Elyse
8d1fb299b1 LibGUI+LibWeb: Use 'decrease_slider_by_steps()' method
This method allow us to avoid repeating the pattern
'set_value(value() - step() * step_number)'.
2021-12-30 14:31:50 +01:00
Elyse
cee4e02134 LibGUI+LibWeb: Use 'increase_slider_by_steps()' method
This method allow us to avoid repeating the pattern
'set_value(value() + step() * step_number)'.
2021-12-30 14:31:50 +01:00
Elyse
086615535f Everywhere: Use 'decrease_slider_by()' method from AbstractSlider
The same idea as 'increase_slider_by()', it helps us to avoid repeating
the pattern 'set_value(value() - delta)'.
2021-12-30 14:31:50 +01:00
Elyse
d53e1fa1fa Everywhere: Use 'increase_slider_by()' method from AbstractSlider
This method help us to avoid repeating the pattern
'set_value(value() + delta)'.
2021-12-30 14:31:50 +01:00
Elyse
8b8f404146 LibGUI: Add movement methods to AbstractSlider
These methods give us a simple way to move up and down the slider,
without needing to repeat the 'set_value(value() + some_value)'
pattern that multiple applications and libraries use.
2021-12-30 14:31:50 +01:00
Luke Wilde
4427386d5f LibWeb: Implement Element.getAttributeNames 2021-12-30 14:30:35 +01:00
Daniel Bertalan
6b39c6b1bf Shell: Avoid many single byte write() syscalls when printing the prompt
Whenever the prompt is printed, we write a line's worth of space
characters to the terminal to ensure that the prompt ends up on a new
line even if there is dangling output on the current line.

We write these to the stderr, which is unbuffered, so each putc() call
would come with the overhead of a system call. Let's use a buffer
+ fwrite() instead, since heap allocation is much faster.
2021-12-30 14:26:29 +01:00
Jelle Raaijmakers
c19632128c LibGL+LibSoftGPU: Implement texture coordinate generation
Texture coordinate generation is the concept of automatically
generating vertex texture coordinates instead of using the provided
coordinates (i.e. `glTexCoord`).

This commit implements support for:

* The `GL_TEXTURE_GEN_Q/R/S/T` capabilities
* The `GL_OBJECT_LINEAR`, `GL_EYE_LINEAR`, `GL_SPHERE_MAP`,
  `GL_REFLECTION_MAP` and `GL_NORMAL_MAP` modes
* Object and eye plane coefficients (write-only at the moment)

This changeset allows Tux Racer to render its terrain :^)
2021-12-30 14:24:29 +01:00
Jelle Raaijmakers
69da279073 LibSoftGPU: Use eye coordinates for fog calculation
Now that we calculate and store eye coordinates for each vertex, we
should use their `z` values for the fragment depth used in further fog
calculations.

This fixes the fog in Tux Racer :^)
2021-12-30 14:24:29 +01:00
Jelle Raaijmakers
fef7f7159c LibGL+LibSoftGPU: Implement eye, clip, NDC and window coordinates
This follows the OpenGL 1.5 spec much more closely. We need to store
the eye coordinates especially, since they are used in texture
coordinate generation and fog fragment depth calculation.
2021-12-30 14:24:29 +01:00
Jelle Raaijmakers
fd4d6b0031 LibSoftGPU: Set obvious FP values for depth_min/max 2021-12-30 14:24:29 +01:00