A lot of places were relying on AK/Traits.h to give it strnlen, memcmp,
memcpy and other related declarations.
In the quest to remove inclusion of LibC headers from Kernel files, deal
with all the fallout of this included-everywhere header including less
things.
This header has always been fundamentally a Kernel API file. Move it
where it belongs. Include it directly in Kernel files, and make
Userland applications include it via sys/ioctl.h rather than directly.
Reduce inclusion of limits.h as much as possible at the same time.
This does mean that kmalloc.h is now including Kernel/API/POSIX/limits.h
instead of LibC/limits.h, but the scope could be limited a lot more.
Basically every file in the kernel includes kmalloc.h, and needs the
limits.h include for PAGE_SIZE.
The `mimic_pressed` function was primarily used in one place, the
Calculator. This patch removes quite a lot of logic duplication there.
It is also profitable to a lot of other places where `click()` was
called without mimicking a click.
This function does more things than a simple getter, so it's probably
better to not use this notation.
I also drop the parameter as it was always used with the same value.
There is a difference in y offset position calculation for floats when
LineBuilder provides final y position while for blocks it needs to be
adjusted by `y_offset`. This difference already accounted in floating
box position calculation and this patch also makes it accounted in check
whether a floating boxes on the same line intersect between each other.
If valid grid-template-areas were given, then place grid items within
these areas. Grid-template-areas take precedence over named line
tracks, meaning if there are grid-areas as well as named tracks, should
use the grid-areas.
When starting the GridFormattingContext, calculate the valid grid areas
as declared in the `grid-template-areas` property. Since this doesn't
change, are able to do this once and store the results.
In some sections of the code, previously would use the values passed to
`grid-column-start`, `grid-row-end`, etc. literally. Since these values
start at grid-column 1 instead of 0 (as represented in most areas in
the code), this made the code unnecessarily complicated.
Now the values are zero-indexed from the getgo.
1. Don't use double_hash. This is not for doubles, as its name implies.
2. Specialize traits and formatters using the underlying DistinctNumeric
type of Web::DevicePixels and Web::CSSPixels.
The idea is that we'll have one type for each tag type.
For now, this treats all tag types as unknown, but it puts most
of the infrastructure for reading tags in place.