Commit graph

39114 commits

Author SHA1 Message Date
Idan Horowitz
b1fe6c3f68 LibJS: Implement the PartitionDurationFormatPattern abstract operation 2022-07-01 01:00:05 +03:00
Idan Horowitz
f4785e2468 LibUnicode: Generate data about DurationFormat-required units as well 2022-07-01 01:00:05 +03:00
Idan Horowitz
573061e76c LibUnicode: Extract the timeSeparator numeric symbol from CLDR
This will be used by Intl.DurationFormat
2022-07-01 01:00:05 +03:00
Idan Horowitz
8e55eb960e LibJS: Implement the ToDurationRecord abstract operation 2022-07-01 01:00:05 +03:00
Idan Horowitz
d9a4b3e46a LibJS: Implement Intl.DurationFormat.prototype.resolvedOptions 2022-07-01 01:00:05 +03:00
Idan Horowitz
b20ef7d640 LibJS: Implement Intl.DurationFormat.supportedLocalesOf 2022-07-01 01:00:05 +03:00
Idan Horowitz
b910183351 js: Implement pretty-printing of Intl.DurationFormat 2022-07-01 01:00:05 +03:00
Idan Horowitz
97fe37bcc2 LibJS: Start implementing the stage 3 Intl.DurationFormat proposal 2022-07-01 01:00:05 +03:00
Linus Groh
e1ee33ba7c LibJS: Fix incorrect ErrorType in Temporal.PlainMonthDay constructor 2022-06-30 20:20:08 +01:00
MacDue
a999b82882 LibWeb: Fix background images not showing till scrolling/repaint
Previously, set_needs_display() was passed an empty rectangle in
ImageStyleValue::resource_did_load(). This led to the browser not
doing a repaint when the image loaded.

Fixes #14435
2022-06-30 20:11:40 +01:00
Andreas Kling
e98f8f20df Run: Don't try to set a history selection if history is empty
This fixes an assertion on startup when there's no command history.
2022-06-30 17:31:07 +02:00
Luke Wilde
c153d1779e LibJS/Bytecode: End the for variable scope at the start of its end block
If the for loop's body is not block terminated, we will generate a Jump
to the end block which will block terminate the body. Then, we ended
the lexical variable scope if needed. However, since the body is now
block terminated, the "LeaveLexicalEnvironment" instruction that is
generated by end_variable_scope is now dropped on the floor.

This fixes this by moving it to the beginning of the end block.
2022-06-30 15:59:55 +01:00
Kenneth Myhra
fbe22af86e Everywhere: Use my fairly new and shiny serenityos.org email :^) 2022-06-30 15:59:42 +01:00
Luke Wilde
bc08d39754 LibJS/Bytecode: Make for, do/while and while always switch to end block
Previously we only did this if the body block was not terminated.
If it was, all future codegen would happen in this block terminated
body block until another switch occurred, dropping all generated
instructions in this time on the floor.
2022-06-30 18:35:18 +04:30
Lennon Donaghy
c1b0931d2e HackStudio: Properly clear previous editor tabs when closing project
Before this commit the close tab button, which is meant to only
show when more than one tab is open, would be present on the tab
of a new project opened after the first project.

This was due to m_all_editor_tab_widgets not being cleared when closing
the first project. This is now cleared when close_current_project() is
called.
2022-06-30 14:38:09 +01:00
Lennon Donaghy
d2aafe58c9 HackStudio: Leave one editor tab open on closing project 2022-06-30 14:38:09 +01:00
Andrew Kaster
010190beb8 Toolchain: Remove workarounds for initializer_list and _aligned_alloc
These are no longer required to use libc++ on Serenity
2022-06-30 12:34:16 +01:00
Andrew Kaster
efc1805b8f Toolchain: Create separate serenity xlocale support file 2022-06-30 12:34:16 +01:00
Andrew Kaster
d889294036 Toolchain: Format llvm patches per new patch format
This removes the patch series 1/N comments, git version at the bottom of
the patch, and zeros out the original commit hash.
2022-06-30 12:34:16 +01:00
Andrew Kaster
a80493d221 LibC: Align _ctype_ to newlib's implementation
newlib has an extra character slot at the beginning to enable some
macro tricks that cause a warning when someone passes a type that's not
"int" into a ctype function. Our deviation from this causes issues for
LLVM.
2022-06-30 12:34:16 +01:00
Andrew Kaster
6223841d69 Tests: Add tests for <ctype.h> functions declared in the C Standard 2022-06-30 12:34:16 +01:00
Andrew Kaster
6d4cfba596 Ports/ruby: Pass proper --with-coroutine flag per architecture
This fixes the x86_64 build. However, when built with clang x86_64,
ruby crashes on exit trying to free some memory that has an invalid
header magic. More work to be done here to make the x86_64 build work
properly.
2022-06-30 12:29:18 +01:00
Andrew Kaster
809852aeb1 Toolchain+Ports: Install host ruby into Local/ruby, not Local/$ARCH
Following the pattern for qemu, mold, and clang, we should install the
host ruby required to build the ruby port into its own install tree
rather than forcing it into the GNU compiler's bindir.
2022-06-30 12:29:18 +01:00
Andrew Kaster
dcc0f299be Toolchain+Ports: Install host python into Local/python, not Local/$ARCH
Following the pattern for qemu, mold, and clang, we should install the
host python required to build the python port into its own install tree
rather than forcing it into the GNU compiler's bindir.
2022-06-30 12:29:18 +01:00
Tim Schumacher
242bbf1be4 Toolchain: Set '/' as default division character for binutils
While we are at it, regenerate the patch and remove some outdated parts
of the description.
2022-06-30 12:27:17 +01:00
Karol Kosek
9aafaec259 LibGfx: Use ZlibCompressor for compressing PNG files
Previously we were hand-writing all the Zlib and raw Deflated data
structures here, but now PNGs will be compressed using ZlibCompressor
which will actually try to compress something! :^)

Note that we don't do any filtering that should help compress data even
more, but even now the results are pretty good:

- screenshots of my Serenity desktop are take now about 55 KiB, where
  previously it was 3 MiB.
- re-encoding NASA photo of the Earth[1] to PNG shows a 2x improvement
  (34.3 MiB -> 16.5 MiB).

[1]: https://commons.wikimedia.org/wiki/File:The_Blue_Marble_(remastered).jpg
2022-06-30 12:26:49 +01:00
Karol Kosek
0de0de3536 LibCompress: Implement a Zlib compressor 2022-06-30 12:26:49 +01:00
Karol Kosek
42abe1df77 LibCompress: Use newly created Zlib header structure when decompressing
This way we can get rid of some magic numbers.
2022-06-30 12:26:49 +01:00
Karol Kosek
20575ea1f3 LibCompress: Add Zlib header structure 2022-06-30 12:26:49 +01:00
martinfalisse
f33979a753 SQLStudio: Add collapsible tabs for query results
Adds tabs under the editor and places the query results there. It is
only displayed if there are results to an executed query.
2022-06-30 12:22:45 +01:00
martinfalisse
e9541bca31 SQLStudio: Show script execution results in table
Show the results of executing a script in the TableView (if there are
results to show).
2022-06-30 12:22:45 +01:00
martinfalisse
061525282f SQLStudio: Execute statements in SQL server
Make the link between SQLStudio and the SQLServer so that statements
written in the editor window are executed by LibSQL when the 'Run'
button is clicked.
2022-06-30 12:22:45 +01:00
martinfalisse
4461dad0f3 SQLStudio: Add GUI for query results
Add the necessary GUI elements (button, table) so that one can click a
button to run the currently-open script, and see the results in a
user-friendly table.
2022-06-30 12:22:45 +01:00
Cyber Gsus
224924885d Documentation: Bump compiler version to 12.1.0 in include paths
Even though we tell the user to change the version manually if it
doesn't match with the current
`Toolchain/Local/i686/i686-pc-serenity/include/XX.X.X` version, it
doesn't hurt to update it properly now that versions differ by major
version.
2022-06-30 13:16:40 +02:00
Linus Groh
3c9bf1e161 Base: Add example for calc(<percentage> - <length>) to calc.html
`calc(<percentage> + -<length>)` did work before, but a direct
`calc(<percentage> - <length>)` was broken. Let's have a test for both.
2022-06-30 12:11:57 +01:00
Linus Groh
b3a22c97cd Base: Fix label/actual style mismatches in calc.html 2022-06-30 12:11:57 +01:00
Linus Groh
26fc01eecb LibWeb/CSS: Fix incorrect calc(<percentage> - <value>) computations
When swapping both values to perform the actual calculation, we need to
consider that `A + B == B + A`, but `A - B != B - A`, so turn it into
`-B + A`.

Co-Authored-By: Sam Atkins <atkinssj@serenityos.org>
2022-06-30 12:11:57 +01:00
jmdeejay
c1acb587d7 Base: Add new Canadian keyboard mappings 2022-06-30 12:00:10 +01:00
MacDue
5b9d7bb335 FileSystemAccessServer: Call window stealing functions sync
These functions were changed to synchronous in #13870 but
the async_ versions were still being called. This led to
frequent crashes when loading local files in Browser.
2022-06-30 11:15:24 +01:00
Tim Schumacher
154f3dc4ae Ports: Add a port of e2fsprogs 2022-06-30 11:57:49 +02:00
Tim Schumacher
6d4d6c3e2a LibC: Implement wcswidth 2022-06-30 11:57:49 +02:00
Tim Schumacher
9497cc6c97 LibC: Stub out brk and sbrk 2022-06-30 11:57:49 +02:00
Tim Schumacher
e2036ca2ca LibELF: Store the full file path in DynamicObject
Otherwise, our `dirname` call on the parent object will always be empty
when trying to resolve dependencies.
2022-06-30 11:57:10 +02:00
Luke Wilde
dc805e6c81 Base: Sort the default content list in ascending order 2022-06-30 11:55:25 +02:00
Luke Wilde
b23819fb19 Base: Add 300+ ads and trackers to the default content filter list
This also starts making use of the fact we match on any part of the URL
to block on-site trackers such as the ones provided by Ezoic:
```
/greenoaks.gif?
/imp.gif?
/cmbdv2.js
/ezcl.webp?
```
This also promotes some subdomains to the eTLD+1 as I saw other
subdomains being used for these.
2022-06-30 11:55:25 +02:00
Lennon Donaghy
fbb8893513 PixelPaint: Omit file extension in tab/editor titles
This commit removes the file extension in the presented title of images,
and fixes an issue with the previous commit wherein "save as" on an
image would always append ".pp" as an extension, even when the filename
already included this extension.
2022-06-30 11:54:29 +02:00
Lennon Donaghy
7919b4368e PixelPaint: Use image title as default filename for "save as"
When creating a new image, a title can be entered. This title was not
used when saving the file however, so naming it was pointless, as the
title used would be whatever was entered during the first save.

This commit makes it so that the default text in the "save as" dialogue
is whatever was entered previously when the image was created.
2022-06-30 11:54:29 +02:00
FrHun
307d113594 Spreadsheet: Make conditional-formatting condition-list scrollable 2022-06-30 11:53:50 +02:00
FrHun
fddd2bf6ff LibGUI: Add min_content_size debug property to AbstractScrollableWidget
This helps with debugging subclasses of AbstractScrollableWidget
2022-06-30 11:53:50 +02:00
FrHun
247e3ef6e7 LibGUI: Add custom layout change handling to ScrollableContainerWidget 2022-06-30 11:53:50 +02:00