#ifndef THIRD_PARTY_BLINK_RENDERER_CORE_LAYOUT_ABSOLUTE_UTILS_H_
#define THIRD_PARTY_BLINK_RENDERER_CORE_LAYOUT_ABSOLUTE_UTILS_H_
#include <optional>
#include "third_party/blink/renderer/core/core_export.h"
#include "third_party/blink/renderer/core/layout/geometry/logical_size.h"
#include "third_party/blink/renderer/core/layout/geometry/physical_size.h"
#include "third_party/blink/renderer/core/layout/min_max_sizes.h"
#include "third_party/blink/renderer/core/layout/physical_box_fragment.h"
#include "third_party/blink/renderer/platform/geometry/layout_unit.h"
namespace blink {
class BlockNode;
class ConstraintSpace;
class LayoutResult;
struct LogicalStaticPosition;
struct CORE_EXPORT LogicalOofDimensions { … };
struct CORE_EXPORT LogicalOofInsets { … };
struct LogicalAlignment { … };
LogicalAlignment ComputeAlignment(
const ComputedStyle& style,
WritingDirectionMode container_writing_direction,
WritingDirectionMode self_writing_direction);
struct LogicalAnchorCenterPosition { … };
LogicalAnchorCenterPosition ComputeAnchorCenterPosition(
const ComputedStyle& style,
const LogicalAlignment& alignment,
WritingDirectionMode writing_direction,
LogicalSize available_size);
CORE_EXPORT LogicalOofInsets
ComputeOutOfFlowInsets(const ComputedStyle& style,
const LogicalSize& available_size,
const LogicalAlignment&,
WritingDirectionMode self_writing_direction);
struct CORE_EXPORT InsetModifiedContainingBlock { … };
CORE_EXPORT InsetModifiedContainingBlock ComputeInsetModifiedContainingBlock(
const BlockNode& node,
const LogicalSize& available_size,
const LogicalAlignment&,
const LogicalOofInsets&,
const LogicalStaticPosition&,
const LogicalAnchorCenterPosition&,
WritingDirectionMode container_writing_direction,
WritingDirectionMode self_writing_direction);
CORE_EXPORT InsetModifiedContainingBlock
ComputeIMCBForPositionFallback(const LogicalSize& available_size,
const LogicalAlignment&,
const LogicalOofInsets&,
const LogicalStaticPosition&,
const ComputedStyle&,
WritingDirectionMode container_writing_direction,
WritingDirectionMode self_writing_direction);
CORE_EXPORT bool ComputeOofInlineDimensions(
const BlockNode&,
const ComputedStyle& style,
const ConstraintSpace&,
const InsetModifiedContainingBlock&,
const LogicalAlignment&,
const BoxStrut& border_padding,
const std::optional<LogicalSize>& replaced_size,
WritingDirectionMode container_writing_direction,
LogicalOofDimensions* dimensions);
CORE_EXPORT const LayoutResult* ComputeOofBlockDimensions(
const BlockNode&,
const ComputedStyle& style,
const ConstraintSpace&,
const InsetModifiedContainingBlock&,
const LogicalAlignment&,
const BoxStrut& border_padding,
const std::optional<LogicalSize>& replaced_size,
WritingDirectionMode container_writing_direction,
LogicalOofDimensions* dimensions);
}
#endif