summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2020-06-24LibWeb: Use the cached text-align value in LineBox::add_fragment()Andreas Kling
2020-06-23LibWeb: Cache the used CSS text-align property on LayoutNodeWithStyleAndreas Kling
2020-06-23LibWeb: Always inline absolute Length to_px() conversionAndreas Kling
Only do the relative Length units out of line.
2020-06-23LibWeb: Always inline is<LayoutBox>() and is<LayoutBlock>()Andreas Kling
2020-06-23LibWeb: Cache the used CSS 'position' value on LayoutNodeWithStyleAndreas Kling
This avoids having to query the StyleProperties hash map whenever we need to know if an element is absolutely positioned. This was extremely hot in interactive window resize profiles.
2020-06-23LibWeb: Handle empty inputs to the CSS parserAndreas Kling
Empty inputs -> empty outputs.
2020-06-23LibWeb: Handle position:absolute with both left and right specifiedAndreas Kling
In this case, we need to undo the right-side offsetting, since the width computation algorithm will already have stretched the width to accomodate both the side constraints.
2020-06-23AK: Inline the basics of VectorIteratorAndreas Kling
Inlining these allows the compiler to optimize out the assertions in favor of a static range check in many cases.
2020-06-23Meta: Add Hüseyin to contributors list :^)Andreas Kling
He recently passed 100 commits in the projects!
2020-06-23LibWeb: Make sure BoxModelMetrics are set for position:absolute boxesAndreas Kling
This is all very redundant and we should find a way to share this code between at least some of the positioning modes.
2020-06-23LibWeb: Take margin into account when positioning absolute descendantsAndreas Kling
2020-06-23LibWeb: Respect specified width when computing shrink-to-fit candidatesAndreas Kling
Previously we would always just use the combined content width as the shrunken width in shrink-to-fit width calculations, but if the element has a non-auto specified width, we should just let that take over. This is far from perfect and doesn't take stuff like min/max-width into account. Will need more work, this just covers the basic case.
2020-06-23LibJS: Explicitly invoke Cell constructor in Object(Object& prototype)Andreas Kling
2020-06-23LibWeb: Update PageView content size on page relayoutAndreas Kling
If the layout changes and the page becomes taller or shorter for some reason, we need to update the PageView's scrollable content size.
2020-06-23LibJS: Make NativeProperty a plain Cell instead of an ObjectAndreas Kling
This removes the need for NativeProperty objects to have a prototype, which just made things confusing.
2020-06-23LibJS: Clarify Object (base class) construction somewhatAndreas Kling
Divide the Object constructor into three variants: - The regular one (takes an Object& prototype) - One for use by GlobalObject - One for use by objects without a prototype (e.g ObjectPrototype)
2020-06-23LibWeb: Make wrapper factory functions take JS::GlobalObject&Andreas Kling
Instead of taking the JS::Heap&. This allows us to get rid of some calls to JS::Interpreter::global_object(). We're getting closer and closer to multiple global objects. :^)
2020-06-23LibWeb: Let HTMLScriptElement call Document::run_javascript()Andreas Kling
The fewer places we invoke the JS parser the better. Unless we have some specific reason to parse manually, we can just call Document.
2020-06-23LibWeb: Remove hacky old ways of running <script> element contentsAndreas Kling
Now that we're using the new HTML parser, we don't have to do the weird "run the script when inserted into the document, uhh, or when the text content of the script element changes" dance. Instead, we just follow the spec, and scripts run the way they should.
2020-06-23LibWeb: Fix tokenization of attributes with URL query strings in themAndreas Kling
<a href="/foo&amp=bar"> was being tokenized into <a href="/foo&=bar">. The spec mentions this but I had overlooked it. The bug happens because we interpreted the "&amp" as a named character reference.
2020-06-23SystemServer: Fix typo (exist -> exit) (#2615)Ruairidh MacLeod
Small typo that I noticed on the latest OS hacking video!
2020-06-23WebContent: Unveil access to the ImageDecoder service :^)Andreas Kling
2020-06-23LibWeb: Remove Gfx::ImageDecoder from ImageLoaderAndreas Kling
We still use a Gfx::ImageDecoder for GIF images, but there's no need for the ImageLoader object to have its own pointer to it. Just grab the ImageDecoder from the ImageResource when needed.
2020-06-23LibWeb: Use ImageLoader::has_image() in HTMLObjectElementAndreas Kling
This makes ACID2 load the eyes image again. :^)
2020-06-23LibWeb: Decode CSS image values out-of-process as wellAndreas Kling
2020-06-23LibWeb: Give ImageResource::bitmap(frame_index) default frame_index = 0Andreas Kling
2020-06-23Ports: Make ninja use ppoll instead of pselectNico Weber
2020-06-23LibC+Kernel: Implement ppollNico Weber
ppoll() is similar() to poll(), but it takes its timeout as timespec instead of as int, and it takes an additional sigmask parameter. Change the sys$poll parameters to match ppoll() and implement poll() in terms of ppoll().
2020-06-23JPGLoader: Move JPGLoader internal structs and #defines to JPGLoader.cppdevashish
2020-06-23LibGfx: Integrate JPEG decoder with rest of the systemdevashish
This patch adds functions like `load_jpeg` to JPGLoader to make the JPEG decoder conform to the API that bitmap loader uses :^)
2020-06-23LibGfx+LibWeb: Add JPEG decoder and integrate with LibWebDevashish
This patch adds support for JPEG decoding. The JPEG decoder is capable of handling standard 2x1 horizontal, 2x1 vertical and quartered chroma subsampling. The implemented Inverse DCT performs with a decent speed. As of interchange formats, since we tend to ignore the metadata in APPn markers, the decoder can handle any format compatible with JFIF, which includes EXIFs and sometimes WebMs too. The decoder does not support progressive JPEGs yet.
2020-06-22LibWeb+Browser: Decode non-animated images out-of-process :^)Andreas Kling
We now use the ImageDecoder service in LibWeb for everything except GIF images (we'll have to deal with them later, ofc.) This has a little bit of overhead but we should be able to optimize it until it becomes negligible.
2020-06-22LibIPC: Silence some debug spamAndreas Kling
2020-06-22ImageDecoder: Add a new service for out-of-process image decoding :^)Andreas Kling
The new ImageDecoder service (available for members of "image" via /tmp/portal/image) allows you to decode images in a separate process. This will allow programs to confidently load untrusted images, since the bulk of the security concerns are sandboxed to a separate process. The only API right now is a synchronous IPC DecodeImage() call that takes a shbuf with encoded image data and returns a shared buffer and metadata for the decoded image. It also comes with a very simple library for interfacing with the ImageDecoder service: LibImageDecoderClient. The name is a bit of a mouthful but I guess we can rename it later if we think of something nicer to call it. There's obviously a bit of overhead to spawning a separate process for every image decode, so this is mostly only appropriate for untrusted images (e.g stuff downloaded from the web) and not necessary for trusted local images (e.g stuff in /res)
2020-06-22LibCore: Remove some debug spam in Local{Server,Socket}Andreas Kling
2020-06-22LibCore: Put safe_syscall() debug spam behind #ifdefAndreas Kling
2020-06-22SystemServer: Put some debug spam behind #ifdefsAndreas Kling
2020-06-22Kernel: Silence debug spam on execAndreas Kling
2020-06-22Kernel: Silence some debug spam in SchedulerAndreas Kling
2020-06-22LibWeb: Generate CanvasRenderingContext2D bindings from IDL :^)Andreas Kling
We're still missing optional argument support, so this implementation doesn't support fill(), only fill(fill_rule). Still it's really nice to get rid of so much hand-written wrapper code.
2020-06-22Base: Test web page and images for PPM image file typeHüseyin ASLITÜRK
2020-06-22LibGfx: Add PPM image file type supportHüseyin ASLITÜRK
2020-06-22LibWeb: Add "image/x‑portable‑pixmap" mime type for pbm file extensionHüseyin ASLITÜRK
2020-06-22Base: Add PPM file type to QuickShow file type listHüseyin ASLITÜRK
2020-06-22Ports: Add ninjaNico Weber
- 1.8.2 for now, newer versions need high-res timestamp file APIs which serenity doesn't have yet - pselect() instead of ppoll() for now, same reason (depends on #2609) - no good default for -j yet (see nproc.patch) - `-l` probably doesn't work yet (see loadavg.patch), but I've never used that anyways - some minor include patches that I've also sent upstream Other than that, this seems to work reasonably well. It currently produces some spam on stdout from probably the shell.
2020-06-22LibC: Implement pselectNico Weber
pselect() is similar() to select(), but it takes its timeout as timespec instead of as timeval, and it takes an additional sigmask parameter. Change the sys$select parameters to match pselect() and implement select() in terms of pselect().
2020-06-22LibC: Add timespec functions to sys/time.hNico Weber
And rewrite the timeval functions as inline functions. Also add the non-standard but fairly common and useful TIMEVAL_TO_TIMESPEC / TIMESPEC_TO_TIMEVAL functions.
2020-06-22AK: Add timespec_add and timespec_subNico Weber
2020-06-22LibJS: expose some more math functionsstelar7
2020-06-22LibM: Add some more math functionsstelar7