mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 18:20:43 +09:00
LibWeb: Add <canvas> element and start fleshing out CRC2D
This patch adds HTMLCanvasElement along with a LayoutCanvas object. The DOM and layout parts are very similar to <img> elements. The <canvas> element holds a Gfx::Bitmap which is sized according to the "width" and "height" attributes on the element. Calling .getContext("2d") on a <canvas> element gives you a context object that draws into the underlying Gfx::Bitmap of the <canvas>. The context weakly points to the <canvas> which allows it to outlive the canvas element if needed. This is really quite cool. :^)
This commit is contained in:
parent
73d28a0551
commit
a37c29e353
Notes:
sideshowbarker
2024-07-19 08:13:54 +09:00
Author: https://github.com/awesomekling
Commit: a37c29e353
19 changed files with 649 additions and 1 deletions
|
@ -28,19 +28,24 @@
|
|||
|
||||
namespace Web {
|
||||
|
||||
class CanvasRenderingContext2D;
|
||||
class Document;
|
||||
class Element;
|
||||
class EventListener;
|
||||
class EventTarget;
|
||||
class Frame;
|
||||
class HTMLElement;
|
||||
class HTMLCanvasElement;
|
||||
class HtmlView;
|
||||
class Node;
|
||||
|
||||
namespace Bindings {
|
||||
|
||||
class CanvasRenderingContext2DWrapper;
|
||||
class DocumentWrapper;
|
||||
class EventListenerWrapper;
|
||||
class EventTargetWrapper;
|
||||
class HTMLCanvasElementWrapper;
|
||||
class NodeWrapper;
|
||||
class Wrappable;
|
||||
class Wrapper;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue