blob: 7ed7bcb79094aed067c64e4666fe3f55d884a431 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#pragma once
#include <LibDraw/Size.h>
#include <LibHTML/CSS/LengthBox.h>
class BoxModelMetrics {
public:
BoxModelMetrics();
~BoxModelMetrics();
LengthBox& margin() { return m_margin; }
LengthBox& padding() { return m_padding; }
LengthBox& border() { return m_border; }
const LengthBox& margin() const { return m_margin; }
const LengthBox& padding() const { return m_padding; }
const LengthBox& border() const { return m_border; }
struct PixelBox {
int top;
int right;
int bottom;
int left;
};
PixelBox full_margin() const;
private:
LengthBox m_margin;
LengthBox m_padding;
LengthBox m_border;
};
|