summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibWeb/HTML/HTMLCanvasElement.cpp
AgeCommit message (Collapse)Author
2022-03-17Libraries: Use default constructors/destructors in LibWebLenny Maiorani
https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#cother-other-default-operation-rules "The compiler is more likely to get the default semantics right and you cannot implement these functions better than the compiler."
2022-02-19LibWeb: Move QualifiedName into the Web::DOM namespaceAndreas Kling
2022-02-05LibWeb: Compute element style in Layout::TreeBuilderAndreas Kling
Instead of making each Layout::Node compute style for itself, we now compute it in TreeBuilder before even calling create_layout_node(). For non-element DOM nodes, we create the style and layout tree node in TreeBuilder. This allows us to move create_layout_node() from DOM::Node to DOM::Element.
2021-11-13LibWeb: Allow setting the width & height properties on <canvas> elementsAndreas Kling
2021-11-08LibGfx: Use ErrorOr<T> for Bitmap::try_create()Andreas Kling
Another one that was used in a fajillion places.
2021-10-06LibWeb: Start work towards modern CSS "display" valuesAndreas Kling
Until now, we've internally thought of the CSS "display" property as a single-value property. In practice, "display" is a much more complex property that comes in a number of configurations. The most interesting one is the two-part format that describes the outside and inside behavior of a box. Switching our own internal representation towards this model will allow for much cleaner abstractions around layout and the various formatting contexts. Note that we don't *parse* two-part "display" yet, this is only about changing the internal representation of the property. Spec: https://drafts.csswg.org/css-display
2021-09-24LibWeb: Rename CSS::StyleResolver => StyleComputerAndreas Kling
Resolved style is a spec concept that refers to the weird mix of computed style and used style reflected by getComputedStyle(). The purpose of this class is to produce the *computed* style for a given element, so let's call it StyleComputer.
2021-09-13LibWeb: Add the Web::URL namespace and move URLEncoder to itIdan Horowitz
This namespace will be used for all interfaces defined in the URL specification, like URL and URLSearchParams. This has the unfortunate side-effect of requiring us to use the fully qualified AK::URL name whenever we want to refer to the AK class, so this commit also fixes all such references.
2021-07-27LibWeb: Return null if an unknown canvas context type is requestedK-Adam
2021-07-21LibGfx: Use "try_" prefix for static factory functionsAndreas Kling
Also mark them as [[nodiscard]].
2021-04-23AK: Rename adopt() to adopt_ref()Andreas Kling
This makes it more symmetrical with adopt_own() (which is used to create a NonnullOwnPtr from the result of a naked new.)
2021-04-22Everything: Move to SPDX license identifiers in all files.Brian Gianforcaro
SPDX License Identifiers are a more compact / standardized way of representing file license information. See: https://spdx.dev/resources/use/#identifiers This was done with the `ambr` search and replace tool. ambr --no-parent-ignore --key-from-file --rep-from-file key.txt rep.txt *
2021-04-19LibWeb: Add basic support for HTMLCanvasElement.toDataURL() :^)Andreas Kling
This allows you to serialize a <canvas> element's bitmap into a data: URI. Pretty neat! :^)
2021-03-16LibGfx: Rename 32-bit BitmapFormats to BGRA8888 and BGRx888xAndreas Kling
The previous names (RGBA32 and RGB32) were misleading since that's not the actual byte order in memory. The new names reflect exactly how the color values get laid out in bitmap data.
2021-02-23Everywhere: Rename ASSERT => VERIFYAndreas Kling
(...and ASSERT_NOT_REACHED => VERIFY_NOT_REACHED) Since all of these checks are done in release builds as well, let's rename them to VERIFY to prevent confusion, as everyone is used to assertions being compiled out in release. We can introduce a new ASSERT macro that is specifically for debug checks, but I'm doing this wholesale conversion first since we've accumulated thousands of these already, and it's not immediately obvious which ones are suitable for ASSERT.
2021-02-07LibWeb: Use move semantics for QualifiedName more oftenAndreas Kling
2021-01-12Libraries: Move to Userland/Libraries/Andreas Kling