mirror of
https://github.com/RGBCube/serenity
synced 2025-06-04 09:08:12 +00:00

The basic idea of block layout is: width, then children based on width, then height based on height of children.
30 lines
362 B
C++
30 lines
362 B
C++
#include <LibHTML/DOM/Element.h>
|
|
#include <LibHTML/Layout/LayoutBlock.h>
|
|
|
|
LayoutBlock::LayoutBlock(const Node& node)
|
|
: LayoutNode(&node)
|
|
{
|
|
}
|
|
|
|
LayoutBlock::~LayoutBlock()
|
|
{
|
|
}
|
|
|
|
void LayoutBlock::layout()
|
|
{
|
|
compute_width();
|
|
|
|
LayoutNode::layout();
|
|
|
|
compute_height();
|
|
}
|
|
|
|
void LayoutBlock::compute_width()
|
|
{
|
|
|
|
}
|
|
|
|
void LayoutBlock::compute_height()
|
|
{
|
|
|
|
}
|