summaryrefslogtreecommitdiff
path: root/Userland
AgeCommit message (Collapse)Author
2021-09-21LibPDF: Rely on default-constructor of VariantBen Wiederhake
2021-09-21LibIMAP: Remove unused Variant optionBen Wiederhake
2021-09-20WindowServer: Apply screen scaling when getting bitmap around cursorDavid Isaksson
This fixes an issue for the magnifier that when the screen scaling is increased to 2 the magnifier doesn't center around the cursor. Since booting Serenity with multiple displays doesn't work at the moment the rescaling is only added for the one display case.
2021-09-20LibWeb: Resolve 'inherit' property-value somewhatTobias Christiansen
This doesn't capture the whole picture as shorthands are not considered in a careful way. A very dirty hack is included to not try to resolve 'font' as the amount of debug spam it generated ("No inital value found for...") was unhelpful.
2021-09-20LibWeb: Enable bilinear blending for bitmapsSam Atkins
This is slower, but looks a lot nicer. :^)
2021-09-20LibGfx: Add optional bilinear filtering to draw_scaled_bitmap()Sam Atkins
The algorithm is quite simple: You grab a 2x2 area of pixels around the point you want from the source bitmap, and then linearly interpolate between them based on how far they are from that point. This works well when scaling up images, and moderately well when scaling down - small details may get skipped over. The way GPUs solve this is with mipmaps, which is not something I want to get into right now. (And increases the memory usage per bitmap by 50%.) I have not focused on performance, but this does reuse much of the existing fixed-point calculation, and uses constexpr so that the performance for nearest-neighbor should be the same as it was previously.
2021-09-20LibC+DynamicLoader: Store the auxiliary vector address at startupItamar
Previously, getauxval() got the address of the auxiliary vector by traversing to the end of the `environ` pointer. The assumption that the auxiliary vector comes after the environment array is true at program startup, however the environment array may be re-allocated and change its address during runtime which would cause getauxval() to work with an incorrect auxiliary vector address. To fix this, we now get the address of the auxiliary vector once in __libc_init and store it in a libc-internal pointer which is then used by getauxval(). Fixes #10087.
2021-09-20LibWeb: Implement <script src> execution for non-blocking scriptsAndreas Kling
2021-09-20LibWeb: Make <script src> loads partially async (by following the spec)Andreas Kling
Instead of firing up a network request and synchronously blocking for it to finish via a nested event loop, we now start an asynchronous request when encountering <script src>. Once the script load finishes (or fails), it gets executed at one of the synchronization points in the HTML parser. This solves some long-standing issues with random unexpected events getting dispatched in the middle of parsing.
2021-09-20LibWeb: Pop entire stack of open elements at the end of parsingAndreas Kling
2021-09-20LibWeb: Implement an ad-hoc version of EventLoop::spin_until(condition)Andreas Kling
This doesn't follow the exact spec steps but instead simply makes a nested Core::EventLoop and spins it while a periodic timer tests the goal condition.
2021-09-20LibWeb: Use Document::realm() in HTMLScriptElement::prepare_script()Andreas Kling
2021-09-20WidgetGallery: Crop animated cursorsKarol Kosek
Selecting the wait cursor displayed the full sprite image. This has been borrowed from the MouseSettings.
2021-09-20WidgetGallery+MouseSettings: Use LexicalPath::basename()Karol Kosek
2021-09-20WidgetGallery: Simplify cursor change codeKarol Kosek
The code here wasn't updated when a new file icons appeared, so double- -clicking a cursor didn't always set it to the correct one. Also, the cursor list is sorted alphabetically, by the file name. So if a theme used a different file naming in Config.ini, then the previous code would also be incorrect. Here we will just take the bitmap icon from the model. Closes: #10142
2021-09-20LibGUI: Update the window cursor if it was provided as a bitmapKarol Kosek
This condition rejected almost every bitmap cursor change.
2021-09-20LibC: Spec compliant IN6_IS_ADDR_V4MAPPEDKenneth Myhra
An IPv4 mapped IPv6 address consist of 80 "0" bits, followed by 16 "1" bits, followed by the 32-bit IPv4 address. Example of IPv4 mapped IPv6 address: IPv4 address: 169.219.13.133 IPv6 address: 0000:0000:0000:0000:FFFF:A9DB:0D85 Simplified : ::FFFF:A9DB:0D85
2021-09-20LibPDF: Replace Value class by AK::VariantBen Wiederhake
This decreases the memory consumption by LibPDF by 4 bytes per Value, compensating exactly for the increase in an earlier commit. :^)
2021-09-20LibPDF: Extract reference bitpacking into dedicated classBen Wiederhake
2021-09-20LibPDF: Move inline function definitionBen Wiederhake
This breaks the dependency cycle between Parser and Document.
2021-09-20LibPDF: Break weird dependency cycleBen Wiederhake
Old situation: Object.h defines Object Object.h defines ArrayObject ArrayObject requires the definition of Object ArrayObject requires the definition of Value Value.h defines Value Value requires the definition of Object Therefore, a file with the single line "#include <Value.h>" used to raise compilation errors; certainly not something that one might expect from a library. This patch splits up the definitions in Object.h to break the cycle. Now, Object.h only defines Object, Value.h still only defines Value (and includes Object.h), and the new header ObjectDerivatives.h defines ArrayObject (and includes both Object.h and Value.h).
2021-09-20LibPDF: Add missing headers in Value.hBen Wiederhake
2021-09-20LibPDF: Fix math error in commentsBen Wiederhake
2021-09-20LibPDF: Switch to automatic ref counting, fix memory leakBen Wiederhake
At least `Value::operator=` didn't properly unref the `PDF::Object` when it was called. This type of problem is removed by just letting `RefPtr` do its thing. This patch increases the memory consumption by LibPDF by 4 bytes (the other union objects) per value.
2021-09-20LibPDF: Add missing headers to XRefTable.hBen Wiederhake
2021-09-20LibPDF: Add missing headers to Reader.hBen Wiederhake
2021-09-20LibPDF: Add missing headers to Forward.hBen Wiederhake
2021-09-20PixelPaint: Move Tools to it's own subdirectoryMarcus Nilsson
The PixelPaint source directory was getting a bit large, let's move all the Tools to it's own subdirectory. Also remove some unused includes.
2021-09-20AK+LibC: Remove SERENITY_LIBC_BUILD guard around `<initializer_list>`Andrew Kaster
This was required before commit 5f724b6ca1aae3a5a8c7189069649e8a9347cca2 when we were building LibC before libstdc++ headers were available in the sysroot. However as noted in that commit, we never actually needed to be building LibC before libstdc++, so we can go ahead and remove this ancient hack.
2021-09-20Shell: Make ArgsParser not exit on failure in builtin_exit()Ali Mohammad Pur
Fixes #10128.
2021-09-19LibWeb: Give InlineNodes borders :^)Sam Atkins
2021-09-19LibWeb: Move border-painting code out of BoxSam Atkins
The logic here is needed by InlineNode too. Moving it into a `paint_all_borders()` function makes it available to them both, as well as anyone else who wants it. :^)
2021-09-19LibGfx: Add per-side overloads of Rect::inflate() and ::shrink()Sam Atkins
These are in CSS order (top, right, bottom, left) since LibWeb is the reason I'm adding these. :^)
2021-09-19LibWeb: Give InlineNodes a box-shadow :^)Sam Atkins
2021-09-19LibWeb: Give InlineNodes a backgroundSam Atkins
This now uses the same code as Box, so images, repeat-rules, and anything that's added in the future will work for `display: inline` elements too. :^)
2021-09-19LibWeb: Move background painting from Box to its own fileSam Atkins
This makes the code accessible to things that aren't a Box, such as InlineNode.
2021-09-19LibWeb: Move box-shadow painting out of Box to its own fileSam Atkins
This makes the code accessible to things that aren't a Box, such as InlineNode.
2021-09-19LibWeb: Move InlineNode background code from `paint_fragment` -> `paint`Sam Atkins
`paint_fragment()` seems to never get called. Moving the painting to `paint()` fixes the background.
2021-09-19LibWeb: Extract border-radius normalization code from BoxSam Atkins
This is going to be needed by InlineNodes too! `BorderPainting.{h,cpp}` might not be the best place for it, but it works for now.
2021-09-19LibWeb: Stop painting backgrounds for TextNodesSam Atkins
Doing so was causing the background to be painted twice, which looks ugly if the background is semi-transparent. The painting is a bit of a hack, as some situations apparently relied on it. This commit is ripping the band-aid off to find where those are and fix them. :^)
2021-09-19LibWeb: Implement XMLHttpRequest.getAllResponseHeaders()Andreas Kling
2021-09-19LibWeb: Implement basic support for MessageChannel and MessagePortAndreas Kling
This patch adds a basic initial implementation of these API's. Since LibWeb currently doesn't support workers, this implementation of messaging doesn't bother with serializing and deserializing messages.
2021-09-19LibWeb: Add missing #include to MainThreadVM.hAndreas Kling
2021-09-19LibWeb: Add HTML::Task::Source::PostedMessageAndreas Kling
This is the task source used by MessagePort.postMessage().
2021-09-19AudioApplet: Refactor window resizingDavid Isaksson
2021-09-19AudioApplet: Get values from AudioServer instead of the config fileDavid Isaksson
2021-09-19AudioApplet: Make sure to set the internal volume on slider changeDavid Isaksson
This fixes the issue that the percent label doesn't update.
2021-09-19AudioApplet: Round the volume to the nearest integerDavid Isaksson
2021-09-19AudioApplet: Update the volume slider on update from audio serverDavid Isaksson
2021-09-19LibGUI: Add option to disable on_change call for sliders set_value()David Isaksson
This makes it possible to avoid messy situations where a slider controlled value can be changed from multiple sources.