TableWrapperBlockFormattingContext.h [plain text]
#pragma once
#if ENABLE(LAYOUT_FORMATTING_CONTEXT)
#include "BlockFormattingContext.h"
#include <wtf/IsoMalloc.h>
namespace WebCore {
namespace Layout {
class TableWrapperBlockFormattingContext final : public BlockFormattingContext {
WTF_MAKE_ISO_ALLOCATED(TableWrapperBlockFormattingContext);
public:
TableWrapperBlockFormattingContext(const ContainerBox& formattingContextRoot, BlockFormattingState&);
void layoutInFlowContent(InvalidationState&, const ConstraintsForInFlowContent&) final;
void setHorizontalConstraintsIgnoringFloats(const HorizontalConstraints& horizontalConstraints) { m_horizontalConstraintsIgnoringFloats = horizontalConstraints; }
private:
class Quirks : public BlockFormattingContext::Quirks {
public:
Quirks(const TableWrapperBlockFormattingContext&);
Optional<LayoutUnit> overrideTableHeight(const ContainerBox& tableBox) const;
};
TableWrapperBlockFormattingContext::Quirks quirks() const { return Quirks(*this); }
void layoutTableBox(const ContainerBox& tableBox, const ConstraintsForInFlowContent&);
void computeBorderAndPaddingForTableBox(const ContainerBox&, const HorizontalConstraints&);
void computeWidthAndMarginForTableBox(const ContainerBox&, const HorizontalConstraints&);
void computeHeightAndMarginForTableBox(const ContainerBox&, const ConstraintsForInFlowContent&);
private:
HorizontalConstraints m_horizontalConstraintsIgnoringFloats;
};
inline TableWrapperBlockFormattingContext::Quirks::Quirks(const TableWrapperBlockFormattingContext& formattingContext)
: BlockFormattingContext::Quirks(formattingContext)
{
}
}
}
SPECIALIZE_TYPE_TRAITS_LAYOUT_FORMATTING_CONTEXT(TableWrapperBlockFormattingContext, isTableWrapperBlockFormattingContext())
#endif