Commit graph

4011 commits

Author SHA1 Message Date
Idan Horowitz
f553ab3104 LibJS: Implement Temporal.PlainDateTime.prototype.hour 2021-07-29 22:47:56 +01:00
Idan Horowitz
f93b6ea58c LibJS: Implement Temporal.PlainDateTime.prototype.day 2021-07-29 22:47:56 +01:00
Idan Horowitz
677a631e87 LibJS: Implement Temporal.PlainDateTime.prototype.monthCode 2021-07-29 22:47:56 +01:00
Idan Horowitz
78e63b34fa LibJS: Implement Temporal.PlainDateTime.prototype.month 2021-07-29 22:47:56 +01:00
Idan Horowitz
23d0fd2659 LibJS: Implement Temporal.PlainDateTime.prototype.year 2021-07-29 22:47:56 +01:00
sin-ack
667124dc22 LibGUI: Do not wrap text in statusbar segments
This commit adds a new property to Label which allows one to enable or
disable text wrapping. Statusbar now uses this property to disable text
wrapping in its segments, since text wrapping in statusbars doesn't make
sense.
2021-07-29 22:33:34 +01:00
sin-ack
1e44a0c2d9 LibCore: Support registration of TextWrapping properties
This is basically a named boolean.
2021-07-29 22:33:34 +01:00
Andrew Kaster
38707f4a20 LibUnicode: Make unicode data generation logic more relocatable
The previous logic had several checks for Lagom directories and
subdirectories. All we really want to do for these header checks is make
sure that the files end up in an included folder prefixed with
LibUnicode. We also don't need to hard code the path to the generator,
the $<TARGET_FILES> generator expression can create the path for us.
2021-07-29 21:46:25 +01:00
Andrew Kaster
de2bf3f333 Meta/LibTest: Build object libraries for test main files
By using the power of object libraries and $<TARGET_OBJECTS> we can make
sure to only build TestMain.cpp and JavaScriptTestRunnerMain.cpp once.

Previously we built these cpp files into object files once for every
single test executable. This change reduces the number of total compile
jobs in a Serenity target build by around 100.
2021-07-29 21:46:25 +01:00
Andrew Kaster
af9be6e093 LibTTF/LibGfx: Remove circular dependency by merging LibTTF into LibGfx
LibTTF has a concrete dependency on LibGfx for things like Gfx::Bitmap,
and LibGfx has a concrete dependency in the TTF::Font class in
Gfx::FontDatabase. This circular dependency works fine for Serenity and
Lagom Linux builds of the two libraries. It also works fine for static
library builds on Lagom macOS builds.

However, future changes will make Lagom use shared libraries, and
circular library dependencies are not tolerated in macOS.
2021-07-29 21:46:25 +01:00
Luke
e3b588a43d Kernel+LibC: Add linger to sys/sockets.h
Also adds SO_BROADCAST in UnixTypes.h to match sys/sockets.h.
Required by bash 5.1.8.
2021-07-29 19:35:03 +01:00
Andreas Kling
efa9627fc4 LibWeb: Remove unused enum value CSS::StyleValue::Position
CSS position values are just basic identifiers, they don't require
a custom StyleValue type.
2021-07-29 15:01:47 +02:00
Conor Byrne
2b5566d7cc LibGUI+Playground: Move GMLAutocompleteProvider to LibGUI 2021-07-29 11:33:16 +02:00
Tobias Christiansen
4c17f389db LibWeb: Add proper support for text-decoration-line property values
The code handling the rendering of the text-decoration-line got moved
into its own function to reduce clutter.
The CSS property text-decoration-line now supports underline, overline
and line-through.
2021-07-29 11:07:56 +02:00
LuK1337
ba119029dd LibGUI: Allow to specify FilePicker window position 2021-07-29 09:24:08 +02:00
LuK1337
84ee95c346 LibGUI: Allow to specify position on screen for Dialog window
This change allows us to specify where on screen we'd like the Dialog
window to be drawn. By default it's set to CenterWithinParent which
may fall back to Center if parent window is unset or not visible on
screen.
2021-07-29 09:24:08 +02:00
Peter Elliott
5d6bf83374 LibCore: Prevent LockFile fd from leaking into child process
Fixes #9059
2021-07-29 07:58:17 +02:00
K-Adam
15cdb702c2 LibWeb: Handle comment blocks when skipping unknown @-rules
This css definition was parsed incorrectly before:

```css
@media screen {
    /* Unclosed bracket in comment { */
    body {
        background: red;
    }
}
```
2021-07-29 01:24:03 +02:00
Linus Groh
4e4d8d6905 LibJS: Reflect infallibility editorial changes in the Temporal spec
See:

- https://github.com/tc39/proposal-temporal/commit/3c0671f
- https://github.com/tc39/proposal-temporal/commit/fe28b86
2021-07-28 23:48:56 +01:00
SeekingBlues
a13a5315a5 LibWeb: Fix incompatibility of attribute "contenteditable"
The previous behavior of mapping a missing value to the "inherit"
state is incompatible. Now, a missing value maps to the "true" state,
which is the expected behavior.
2021-07-28 23:47:58 +02:00
Timothy Flynn
c4bfda7f7f LibUnicode: Handle code points that are both cased and case-ignorable
Apparently, some code points fit both categories, for example U+0345
(COMBINING GREEK YPOGEGRAMMENI). Handle this fact when determining if
a code point is a final code point in a string.
2021-07-28 23:42:29 +02:00
Timothy Flynn
dff156b7c6 LibUnicode: Reduce Unicode data generator boilerplate
There's a fair amount of boilerplate when e.g. adding a new UCD file to
parse or a new enumeration to generate. Reduce the overhead by adding
helper lambdas. Also adds a couple missing spec links with UCD field
information.
2021-07-28 23:42:29 +02:00
Timothy Flynn
7827aede6f LibUnicode: Check word break when deciding on case-ignorable code points 2021-07-28 23:42:29 +02:00
Timothy Flynn
12fb3ae033 LibUnicode: Download and parse the word break property list UCD file
Note that unlike the main property list, each code point has only one
word break property. Code points that do not have a word break property
are to be assigned the property "Other".
2021-07-28 23:42:29 +02:00
Timothy Flynn
c45a014645 LibUnicode: Check property list when deciding if a code point is cased 2021-07-28 23:42:29 +02:00
Timothy Flynn
38adfd8874 LibUnicode: Download and parse the property list UCD file 2021-07-28 23:42:29 +02:00
Linus Groh
5e64156fce LibJS: Implement Temporal.Now.plainTimeISO() 2021-07-28 21:57:30 +01:00
Linus Groh
2aa2c56891 LibJS: Update Temporal.Now spec section numbers
The addition of @@toStringTag shifted them all by 1.
2021-07-28 21:57:30 +01:00
Linus Groh
817be1b292 LibJS: Handle PlainTime objects in GetTemporalCalendarWithISODefault 2021-07-28 21:57:30 +01:00
Linus Groh
c2d45e5a83 LibJS: Handle PlainTime objects in ToTemporalCalendar 2021-07-28 21:57:30 +01:00
Linus Groh
d3bed13f4b LibJS: Implement Temporal.PlainTime.prototype.nanosecond 2021-07-28 21:57:30 +01:00
Linus Groh
65b90e93ad LibJS: Implement Temporal.PlainTime.prototype.microsecond 2021-07-28 21:57:30 +01:00
Linus Groh
8bcccf2577 LibJS: Implement Temporal.PlainTime.prototype.millisecond 2021-07-28 21:57:30 +01:00
Linus Groh
c5f03bc921 LibJS: Implement Temporal.PlainTime.prototype.second 2021-07-28 21:57:30 +01:00
Linus Groh
574f474d27 LibJS: Implement Temporal.PlainTime.prototype.minute 2021-07-28 21:57:30 +01:00
Linus Groh
524a56f7b6 LibJS: Implement Temporal.PlainTime.prototype.hour 2021-07-28 21:57:30 +01:00
Linus Groh
a8dd1b9480 LibJS: Implement Temporal.PlainTime.prototype.calendar 2021-07-28 21:57:30 +01:00
Linus Groh
ad89a205bc LibJS: Implement Temporal.PlainTime.prototype.valueOf() 2021-07-28 21:57:30 +01:00
Linus Groh
64b44c7f30 LibJS: Implement Temporal.PlainTime.prototype[@@toStringTag] 2021-07-28 21:57:30 +01:00
Linus Groh
ae4bf8fc32 LibJS: Start implementing Temporal.PlainTime
This commit adds the PlainTime object itself, its constructor and
prototype (currently empty), and the CreateTemporalTime abstract
operation.
2021-07-28 21:57:30 +01:00
Linus Groh
321f2c0927 LibJS: Fix types of PlainDateTime iso_{milli,micro,nano}second params
999 does not fit into an u8. :^)
2021-07-28 21:57:30 +01:00
Linus Groh
2ba338869b LibJS/Tests: Remove two leftover console.log() calls 2021-07-28 21:57:30 +01:00
Linus Groh
d84fd3ad5c LibJS: Reflect infallibility editorial change in ToTemporalCalendar
See: https://github.com/tc39/proposal-temporal/commit/3437106
2021-07-28 21:57:30 +01:00
Andreas Kling
2135c66823 Revert "LibGUI: Only dispatch Leave if the now-hovered widget isn't a child"
This reverts commit cfc9ee6f16.

This change was wrong: The parent *does* lose hover when the mouse
cursor enters a child widget. Hover is not hierarchical, there is only a
hovered window and a hovered widget within that window.

This fixes an issue with GUI::TabWidget buttons appearing hovered
despite the mouse cursor not being over the buttons.
2021-07-28 21:28:56 +02:00
Andreas Kling
230f7ce71c Revert "LibGUI: Ignore the Enter event by default"
This reverts commit a5a32fbcce.

This change was wrong: it's fine for a child widget to receive an enter
event despite its parent never getting one. Only the widget directly
under the mouse cursor is considered hovered for enter/leave purposes.
2021-07-28 21:28:56 +02:00
Andreas Kling
410b3c85b6 LibGUI+LibGfx: Highlight currently active tab button with accent color
Use the new "Accent" color role to emphasize the currently active tab
within a GUI::TabWidget. :^)
2021-07-28 20:25:14 +02:00
Andreas Kling
9826d616dd LibGUI: Update windows when they become active/inactive
Since interfaces may look different depending on the window active state
we need to update them when it changes.
2021-07-28 20:25:14 +02:00
Andreas Kling
e378587c82 LibGfx+Base: Add a themable "Accent" color role
This can be used by GUI widgets to draw attention to a specific part of
the widget, for example the currently active sub-widget component.
2021-07-28 20:21:52 +02:00
Andreas Kling
03cca20699 LibGfx: Remove unused StylePainter::paint_surface() 2021-07-28 19:13:08 +02:00
ovf
898b8ffcb6 LibWeb: Avoid assertion failure on parsing numeric character references 2021-07-28 18:32:22 +02:00