Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
|
|
This doesn't actually matter, but I'm trying to match the commonmark
test cases where possible.
|
|
- Support tildes.
- Support different lengths of fence.
- Begrudgingly keep support for serenities one markdown extension.
|
|
|
|
|
|
also fix a conflict with lists and thematic breaks
|
|
|
|
|
|
These allow you to turn the close-on-exec flag on/off via ioctl().
|
|
|
|
With this flag set to true only the icon of the title button is painted.
This is useful for themes with a more non-serenity look such as
Coffee and Cupertino (that currently try to hide the button).
|
|
The number was previously vertically centered, but it prevents from
quickly seeing a line change.
|
|
The issue was caused by the usage of the
selection_end_column_within_line variable as if it was the visual line.
This is fixed by taking the minimum between this value and the length of
a visual line.
|
|
|
|
Similarly to x86_64, Aarch64 is LP64, so its `uint64_t` type is
`unsigned long`.
Fixes a bunch of compiler warnings when compiling the LLVM runtime
libraries for the aarch64-pc-serenity target.
|
|
No other system seems to put this behind a _USE_POSIX ifdef.
|
|
We aren't actually using these for anything, and the spaceship operator
requires ``<compare>`` from the STL, which we'd rather not include.
|
|
|
|
Following FIXMEs have been addressed:
- 1. Let settingsObject be this’s relevant settings object.
- 2. If settingsObject has a responsible document and it is not fully
active, then throw an "InvalidStateError" DOMException.
- 6. Let parsedURL be the result of parsing url with settingsObject's
API base URL and settingsObject’s API URL character encoding.
- 8. If the async argument is omitted, set async to true, and set
username and password to null.
|
|
|
|
The XMLHttpRequest specification specifices that header values should be
normalized by trimming leading and trailing HTTP whitespace bytes.
|
|
This changes the regular expression for is_method() to a more
restrictive pattern.
|
|
This patch adds support for combining header values, in addtion it adds
spec comments for readability.
|
|
|
|
|
|
|
|
|
|
Fixes #13755.
Co-Authored-By: Damien Firmenich <fir.damien@gmail.com>
|
|
Similar to SystemMonitor's option of the same name, this allows you to
launch the given application with the specific tab open.
|
|
This gives us a convenient way to refer to them, which will be used in
the following commit.
|
|
While working on #13764 I noticed that DateTime::to_string() would just
return an empty String if the format included an invalid specifier
(eg `%Q`). This seems to be a mistake. POSIX date(1), which I believe
we are basing our implementation on, only replaces valid specifiers,
and any invalid ones get included as literals in the output.
For example, on Linux `date "+%Quiz"` returns "%Quiz", but we were
returning "".
|
|
Previously, we were sending Buffers to the server whenever we had new
audio data for it. This meant that for every audio enqueue action, we
needed to create a new shared memory anonymous buffer, send that
buffer's file descriptor over IPC (+recfd on the other side) and then
map the buffer into the audio server's memory to be able to play it.
This was fine for sending large chunks of audio data, like when playing
existing audio files. However, in the future we want to move to
real-time audio in some applications like Piano. This means that the
size of buffers that are sent need to be very small, as just the size of
a buffer itself is part of the audio latency. If we were to try
real-time audio with the existing system, we would run into problems
really quickly. Dealing with a continuous stream of new anonymous files
like the current audio system is rather expensive, as we need Kernel
help in multiple places. Additionally, every enqueue incurs an IPC call,
which are not optimized for >1000 calls/second (which would be needed
for real-time audio with buffer sizes of ~40 samples). So a fundamental
change in how we handle audio sending in userspace is necessary.
This commit moves the audio sending system onto a shared single producer
circular queue (SSPCQ) (introduced with one of the previous commits).
This queue is intended to live in shared memory and be accessed by
multiple processes at the same time. It was specifically written to
support the audio sending case, so e.g. it only supports a single
producer (the audio client). Now, audio sending follows these general
steps:
- The audio client connects to the audio server.
- The audio client creates a SSPCQ in shared memory.
- The audio client sends the SSPCQ's file descriptor to the audio server
with the set_buffer() IPC call.
- The audio server receives the SSPCQ and maps it.
- The audio client signals start of playback with start_playback().
- At the same time:
- The audio client writes its audio data into the shared-memory queue.
- The audio server reads audio data from the shared-memory queue(s).
Both sides have additional before-queue/after-queue buffers, depending
on the exact application.
- Pausing playback is just an IPC call, nothing happens to the buffer
except that the server stops reading from it until playback is
resumed.
- Muting has nothing to do with whether audio data is read or not.
- When the connection closes, the queues are unmapped on both sides.
This should already improve audio playback performance in a bunch of
places.
Implementation & commit notes:
- Audio loaders don't create LegacyBuffers anymore. LegacyBuffer is kept
for WavLoader, see previous commit message.
- Most intra-process audio data passing is done with FixedArray<Sample>
or Vector<Sample>.
- Improvements to most audio-enqueuing applications. (If necessary I can
try to extract some of the aplay improvements.)
- New APIs on LibAudio/ClientConnection which allows non-realtime
applications to enqueue audio in big chunks like before.
- Removal of status APIs from the audio server connection for
information that can be directly obtained from the shared queue.
- Split the pause playback API into two APIs with more intuitive names.
I know this is a large commit, and you can kinda tell from the commit
message. It's basically impossible to break this up without hacks, so
please forgive me. These are some of the best changes to the audio
subsystem and I hope that that makes up for this :yaktangle: commit.
:yakring:
|
|
With the following change in how we send audio, the old Buffer type is
not really needed anymore. However, moving WavLoader to the new system
is a bit more involved and out of the scope of this PR. Therefore, we
need to keep Buffer around, but to make it clear that it's the old
buffer type which will be removed soon, we rename it to LegacyBuffer.
Most of the users will be gone after the next commit anyways.
|
|
|
|
This new class with an admittedly long OOP-y name provides a circular
queue in shared memory. The queue is a lock-free synchronous queue
implemented with atomics, and its implementation is significantly
simplified by only accounting for one producer (and multiple consumers).
It is intended to be used as a producer-consumer communication
datastructure across processes. The original motivation behind this
class is efficient short-period transfer of audio data in userspace.
This class includes formal proofs of several correctness properties of
the main queue operations `enqueue` and `dequeue`. These proofs are not
100% complete in their existing form as the invariants they depend on
are "handwaved". This seems fine to me right now, as any proof is better
than no proof :^). Anyways, the proofs should build confidence that the
implemented algorithms, which are only roughly based on existing work,
operate correctly in even the worst-case concurrency scenarios.
|
|
|
|
These are supposed to be used as flags in a bitfield, so let's make
them powers of two.
|
|
This matches how some other systems implement errno, and makes 3rd party
software that expect us to have __errno_location() work.
|
|
- Don't add multiple numbers to nested steps, just the innermost one
(as rendered in the HTML document)
- "Otherwise" comments go before the else, not after it
- "FIXME:" goes before step number, not between it and the comment text
- Always add a period between number and comment text
The majority of these were introduced in #13756, but some unrelated ones
have been updated as well.
|
|
Currently, navigating through different years in the Year view of the
Calendar app or the taskbar is very slow.
Profiling results show that almost all the time is spent in
`Calendar::update_tiles`, and specifically, in `DateTime::create` and
`DateTime::set_time`.
Performance can improve substantially if the `TZ` environment variable
is set [0], but we can improve the current code to perform better
nevertheless :^)
This diff focuses on removing the need of the `Tile` struct to require
the instantiation of a `DateTime` object, which avoids _at least_ 365
object instantiations in the Year view, on each `update_tiles` call.
Instead, as the `date_time` isn't used often, we can instantiate it on
demand when a particular date is selected.
[0] https://blog.packagecloud.io/set-environment-variable-save-thousands-of-system-calls/
|
|
This patch changes the previously used contains method for matching the
user search term with all available commands to use the fuzzy match
algorithm, which makes it more typo tolerant.
|
|
This patch makes CommandPalette be closed whenever the focus shifts from
the dialog. It is closer to other non-serenity implementations of the
CommandPalette and other modal dialogs in the system.
|
|
I believe the issue was caused by the product of two u16s being promoted
to (signed) int, which can cause unwanted overflow behaviour when
comparing to size_t. Casting each term to size_t before the
multiplication makes the comparison unsigned.
|
|
According to the spec, these calls should be identical to an invocation
of `glVertex2*`, which sets the W-coordinate to 1 by default.
This fixes the credits sequence rendering of Tux Racer.
|
|
If a triangle edge is completely horizontal and moving in a positive X
direction, we were erroneously treating it as a top edge. This adds
a better check that accounts for those edges. :^)
|
|
By setting the clip plane normals' W coordinate to 1, we can skip two
coordinate retrievals and three additions. This works because the
Vector `.dot()` operation multiplies the W coordinates of both vectors.
|
|
We sat on a throne of lies: our `edge_function()` returned positive
values for _clockwise_ vertex rotation instead of _counter-clockwise_,
which was hidden by the fact that we were forcing everything into CW
rotation by an erroneous area comparison (`> 0` instead of `< 0`).
This simplifies our culling code significantly.
|