1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 07:48:11 +00:00

LibHTML: Flesh out <img> element with LayoutImage and LayoutReplaced

This patch adds parsing of <img> into HTMLImageElement objects.
It also adds LayoutImage and its parent class LayoutReplaced, which is
going to represent CSS "replaced elements."
This commit is contained in:
Andreas Kling 2019-10-05 22:07:45 +02:00
parent 7162347563
commit 09dccb3224
11 changed files with 96 additions and 2 deletions

View file

@ -0,0 +1,20 @@
#include <LibHTML/Layout/LayoutImage.h>
LayoutImage::LayoutImage(const HTMLImageElement& element, NonnullRefPtr<StyleProperties> style)
: LayoutReplaced(element, move(style))
{
}
LayoutImage::~LayoutImage()
{
}
void LayoutImage::layout()
{
LayoutReplaced::layout();
}
void LayoutImage::render(RenderingContext& context)
{
LayoutReplaced::render(context);
}