Karol Kosek
ab6288fd3d
LibWeb: Use SmoothPixels scaling mode as the pixelated rendering
...
It's probably not in 1:1 as spec says, as it wants us to first upscale
the image to the nearest integer and then downscale it bilinearly.
But this mode still falls into the general description of the value:
> The image is scaled in a way that preserves the pixelated nature of
> the original as much as possible, but allows minor smoothing instead
> of awkward distortion when necessary.
Also, this way we don't have to allocate the memory just for the integer
scale. :^) :^)
2022-06-16 14:26:55 +01:00
Karol Kosek
3d7838c5fb
LibGfx: Implement SmoothPixels scaling mode
...
If you wanted to upscale an image, you had two options:
- use Nearest Neighbor: it's probably a good choice. The image stays
sharp.. unless you aren't using integer scales.
- use Bilinear blending, but this on the other hand, doesn't handle
upscaling well. It just blurs everything.
But what if we could take the best of both of them and make the image
sharp on integers and just blur it a little when needed?
Well, there's Smooth Pixels!
This mode is similar to the Bilinear Blend, with the main difference
is that the blend ratio is multiplied by the current scale, so the blur
on corners can be only 1px wide.
From my testing this mode doesn't handles downscaling as good as the
Bilinear blending though.
2022-06-16 14:26:55 +01:00
Karol Kosek
c409881b5f
LibGfx: Pass scaling mode as an enum in do_draw_scaled_bitmap
2022-06-16 14:26:55 +01:00
hhsdev
3f230a638d
HackStudio: Add "Open in New Tab" context menu entry
...
This action creates a new editor tab and opens the selected file in the
newly created tab.
2022-06-16 12:55:14 +01:00
MacDue
68bc742d9e
Base: Add <img> tag + border-radius HTML example
2022-06-16 10:28:07 +01:00
MacDue
4d110c39f3
LibWeb: Support using border-radius on <img> tags
2022-06-16 10:28:07 +01:00
MacDue
5b6abfadfd
LibWeb: Make PaintableBox::normalized_border_radii_data() protected
...
This method is needed in subclasses of PaintableBox to do
border-radius clipping.
2022-06-16 10:28:07 +01:00
MacDue
51899751d7
Base: Add background-image + border-radius HTML examples
2022-06-16 10:28:07 +01:00
MacDue
4e8e1492f9
LibWeb: Support using border-radius with a background-image
2022-06-16 10:28:07 +01:00
MacDue
830632407f
LibWeb: Add BorderRadiusCornerClipper
...
This is a helper class for clipping the corners off a element.
This works in a similar way to how (outline) borders are painted.
The steps are:
1. A small bitmap that fits only the corners is allocated
2. The corners are painted into the bitmap
3. The existing pixels (where the corners will be painted)
are copied using the (inverse) corner bitmap as a mask
(done before the element is painted)
4. The element is painted
5. The areas outside the corner radii are restored
Like with the borders, this only requires allocation on the first
paint.
2022-06-16 10:28:07 +01:00
MacDue
4dfbbd5965
LibWeb: Move border corner bitmap getter/cache to function
...
This will allow the same bitmap to be shared between border,
background, and various other corner clipping code.
2022-06-16 10:28:07 +01:00
MacDue
81a3ec0692
LibGfx: Add Painter::get_pixel()
...
This is required to do some painting tricks in LibWeb, this has to be
added to the painter so it can apply the paint translation first.
2022-06-16 10:28:07 +01:00
Xexxa
4f311d1660
Base: Add new font Katica Bold Oblique 10
...
0020-007E https://www.unicode.org/charts/PDF/U0000.pdf
2022-06-16 08:52:10 +01:00
Xexxa
9383d49641
Base: Add Mathematical Alphanumeric Symbols to font Katica Regular 10
...
1D522, 1D525, 1D52A, 1D51C, 1D4EA, 1D4F8, 1D4F7, 1D4FC, 1D4FD,
1D516-1D51C
https://www.unicode.org/charts/PDF/U1D400.pdf
2022-06-16 08:52:10 +01:00
Xexxa
52bb037e75
Base: Add 1f785-1F78B, 1F517 to Katica Bold 12
...
1f785-1F78B https://www.unicode.org/charts/PDF/U1F780.pdf
1F517 https://www.unicode.org/charts/PDF/U1F300.pdf
2022-06-16 08:52:10 +01:00
Xexxa
9740ae41fe
Base: Add 2713, 2714 to Katica Bold 10
...
2713, 2714 https://www.unicode.org/charts/PDF/U2700.pdf
2022-06-16 08:52:10 +01:00
Xexxa
14d7e04cd3
Base: Remove painted parts outside of view in Katica Bold 10
...
A few glyphs is "cut" with painted part outside of the view.
0023, 0026, 0040, 004B, 004D, 004E, 004F, 0051, 0052, 0057,
006D, 0077
2022-06-16 08:52:10 +01:00
Thomas Fach-Pedersen
626e7a5c7f
LibWeb: Test parsing of CSS Level 4 rgb and hsl syntax
2022-06-15 19:10:43 +01:00
Thomas Fach-Pedersen
019e3a342d
LibWeb: Parse rgb and hsl functions according to CSS Module Level 4
...
Implement parsing of rgb(..) and hsl(..) in both the modern level 4
syntax without commas, and the legacy syntax with commas.
The parser accepts non-integer numbers but rounds to integer values
for now.
2022-06-15 19:10:43 +01:00
Thomas Fach-Pedersen
83c79fec1c
LibWeb: Fix calculation of degrees from radians
2022-06-15 19:10:43 +01:00
kleines Filmröllchen
1b25513ed7
Kernel: Don't VERIFY that the DMA channel is running on AC'97 interrupt
...
Fixes #13771 ; as discussed it's not really a problem to receive an
interrupt while the DMA channel is not running, but we do want to log
it.
2022-06-15 20:53:10 +03:00
Linus Groh
2c647da0b5
LibJS: Mark AddInstant in AddZonedDateTime as fallible
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/8bc0f98
2022-06-15 17:49:20 +01:00
Linus Groh
b2965cf204
LibJS: Fix Instant rounding modes
...
This is a normative change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/0993b75
2022-06-15 17:49:20 +01:00
Linus Groh
1755d051fd
LibJS: Mark two calls as infallible in DifferenceTemporalPlainTime
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/0e4966a
2022-06-15 17:49:20 +01:00
Linus Groh
36ef604905
LibJS: Assume options is an object in the DifferenceZonedDateTime AO
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/a6662f1
2022-06-15 17:49:20 +01:00
Linus Groh
52a4ee563d
LibJS: Assume options is an object in the MergeLargestUnitOption AO
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/20a04ac
2022-06-15 17:49:20 +01:00
Linus Groh
569c2dc1d0
LibJS: Adjust order of operations in ISO{Date,MonthDay}FromFields
...
This is a normative change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/7dd90dc
2022-06-15 17:49:20 +01:00
Linus Groh
3bc54ac75a
LibJS: Mark a call of CreateDurationRecord as fallible
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/462f027
2022-06-15 17:49:20 +01:00
Linus Groh
81b9a2e4a1
LibJS: Mark a call of CreateDateDurationRecord as fallible
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/5411f62
2022-06-15 17:49:20 +01:00
Linus Groh
8be4cc9653
LibJS: Make options mandatory in Difference{Zoned,ISO}DateTime
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/d4c4a16
2022-06-15 17:49:20 +01:00
Linus Groh
eaf6f20ed1
LibJS: Move assertion step around in Calendar.prototype.mergeFields
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/f790821
2022-06-15 17:49:20 +01:00
Linus Groh
c0986be2c1
LibJS: Use consistent alias names for object-copy steps
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/6669bad
2022-06-15 17:49:20 +01:00
Linus Groh
e68173b656
LibJS: Update AvailableCalendars AO to reflect spec changes
...
These are editorial and normative changes in the Temporal spec.
See:
- https://github.com/tc39/proposal-temporal/commit/2c977fc
- https://github.com/tc39/proposal-temporal/commit/3af75ec
- https://github.com/tc39/proposal-temporal/commit/75ea812
- https://github.com/tc39/proposal-temporal/commit/e7be49b
- https://github.com/tc39/proposal-temporal/commit/883e00a
- https://github.com/tc39/proposal-temporal/commit/5b9d76a
2022-06-15 17:49:20 +01:00
Linus Groh
3025f77991
LibJS: Add an explicit operation for merging calendar field names
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/2bd7977
2022-06-15 17:49:20 +01:00
Linus Groh
ee80164ac1
LibJS: Remove unnecessary variable initialization in DifferenceISODate
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/ca1abdc
2022-06-15 17:49:20 +01:00
Linus Groh
fafc9b07c4
LibJS: Mark AO calls creating a copy of built-in objects as infallible
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/536f067
2022-06-15 17:49:20 +01:00
Linus Groh
be2c86002a
LibJS: Handle absent options in DifferenceZonedDateTime
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/edc223c
2022-06-15 17:49:20 +01:00
Linus Groh
5eb48f6f3a
LibJS: Remove constant arguments from CalculateOffsetShift
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/0bc5f9d
2022-06-15 17:49:20 +01:00
Linus Groh
2ce3d4389a
LibJS: Use existing variable instead of re-reading internal slot
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/8d62569
2022-06-15 17:49:20 +01:00
Linus Groh
a7dfe9096c
LibJS: Switch branches in RegulateISODate
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/2e4a06f
2022-06-15 17:49:20 +01:00
Linus Groh
07041498f8
LibJS: Inline ConstrainISOYearMonth into RegulateISOYearMonth
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/c97932b
2022-06-15 17:49:20 +01:00
Linus Groh
aaa9524a52
LibJS: Add parentheses around modulo operation
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/90e4b34
2022-06-15 17:49:20 +01:00
Linus Groh
287dd03e2e
LibJS: Use nsMinInstant / nsMaxInstant constants in ParseTemporalInstant
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/a045682
2022-06-15 17:49:20 +01:00
Linus Groh
690585323d
LibJS: Prefer Else + Assertion over If for constrained values
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/2088eaa
2022-06-15 17:49:20 +01:00
Linus Groh
9b3602d000
LibJS: Update missing/superfluous commas in various spec comments
...
These are editorial changes in the Temporal spec.
See:
- https://github.com/tc39/proposal-temporal/commit/9586746
- https://github.com/tc39/proposal-temporal/commit/3c76ecc
- https://github.com/tc39/proposal-temporal/commit/96eab07
2022-06-15 17:49:20 +01:00
Linus Groh
30328d74d0
LibJS: Use MaximumTemporalDurationRoundingIncrement in two more places
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/de582e2
2022-06-15 17:49:20 +01:00
Linus Groh
6c82c9df79
LibJS: Fix GetIterator capitalization in Calendar.prototype.fields
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/8538970
2022-06-15 17:49:20 +01:00
Linus Groh
9d2377ff60
LibJS: Only call CanonicalizeTimeZoneName on valid time zone IDs
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/30122e6
2022-06-15 17:49:20 +01:00
Linus Groh
cf61d01140
LibJS: Add a named alias for parseResult.[[Name]] in ToTemporalTimeZone
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/8ddcb07
2022-06-15 17:49:20 +01:00
Linus Groh
71a519831d
LibJS: Update to the latest ECMA-402 GetOption and move it into ECMA-262
...
This is an editorial change in the Temporal spec.
See: https://github.com/tc39/proposal-temporal/commit/4e79b69
2022-06-15 17:49:20 +01:00