chromium/third_party/blink/renderer/core/layout/table/table_layout_algorithm_types.cc

// Copyright 2020 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifdef UNSAFE_BUFFERS_BUILD
// TODO(crbug.com/351564777): Remove this and convert code to safer constructs.
#pragma allow_unsafe_buffers
#endif

#include "third_party/blink/renderer/core/layout/table/table_layout_algorithm_types.h"

#include "third_party/blink/renderer/core/layout/block_node.h"
#include "third_party/blink/renderer/core/layout/constraint_space_builder.h"
#include "third_party/blink/renderer/core/layout/length_utils.h"
#include "third_party/blink/renderer/core/layout/table/layout_table_caption.h"
#include "third_party/blink/renderer/core/layout/table/layout_table_cell.h"
#include "third_party/blink/renderer/core/layout/table/layout_table_column.h"
#include "third_party/blink/renderer/core/layout/table/layout_table_section.h"
#include "third_party/blink/renderer/core/style/computed_style.h"
#include "third_party/blink/renderer/platform/geometry/calculation_value.h"

namespace blink {

namespace {

// Gathers css sizes. CSS values might be modified to enforce universal
// invariants: css_max_inline_size >= css_min_inline_size
// css_percentage_inline_size <= css_percentage_max_inline_size
inline void InlineSizesFromStyle(const ComputedStyle& style,
                                 LayoutUnit inline_border_padding,
                                 bool is_parallel,
                                 std::optional<LayoutUnit>* inline_size,
                                 std::optional<LayoutUnit>* min_inline_size,
                                 std::optional<LayoutUnit>* max_inline_size,
                                 std::optional<float>* percentage_inline_size) {}

}  // namespace

constexpr LayoutUnit TableTypes::kTableMaxInlineSize;

// Implements https://www.w3.org/TR/css-tables-3/#computing-cell-measures
// "outer min-content and outer max-content widths for colgroups"
TableTypes::Column TableTypes::CreateColumn(
    const ComputedStyle& style,
    std::optional<LayoutUnit> default_inline_size,
    bool is_table_fixed) {}

// Implements https://www.w3.org/TR/css-tables-3/#computing-cell-measures
// "outer min-content and outer max-content widths for table cells"
// Note: this method calls BlockNode::ComputeMinMaxSizes.
TableTypes::CellInlineConstraint TableTypes::CreateCellInlineConstraint(
    const BlockNode& node,
    WritingDirectionMode table_writing_direction,
    bool is_fixed_layout,
    const BoxStrut& cell_border,
    const BoxStrut& cell_padding) {}

TableTypes::Section TableTypes::CreateSection(const LayoutInputNode& section,
                                              wtf_size_t start_row,
                                              wtf_size_t row_count,
                                              LayoutUnit block_size,
                                              bool treat_as_tbody) {}

void TableTypes::CellInlineConstraint::Encompass(
    const TableTypes::CellInlineConstraint& other) {}

void TableTypes::Column::Encompass(
    const std::optional<TableTypes::CellInlineConstraint>& cell) {}

TableGroupedChildren::TableGroupedChildren(const BlockNode& table)
    :{}

void TableGroupedChildren::Trace(Visitor* visitor) const {}

TableGroupedChildrenIterator TableGroupedChildren::begin() const {}

TableGroupedChildrenIterator TableGroupedChildren::end() const {}

TableGroupedChildrenIterator::TableGroupedChildrenIterator(
    const TableGroupedChildren& grouped_children,
    bool is_end)
    :{}

TableGroupedChildrenIterator& TableGroupedChildrenIterator::operator++() {}

TableGroupedChildrenIterator& TableGroupedChildrenIterator::operator--() {}

BlockNode TableGroupedChildrenIterator::operator*() const {}

bool TableGroupedChildrenIterator::operator==(
    const TableGroupedChildrenIterator& rhs) const {}

bool TableGroupedChildrenIterator::operator!=(
    const TableGroupedChildrenIterator& rhs) const {}

void TableGroupedChildrenIterator::AdvanceForwardToNonEmptySection() {}

void TableGroupedChildrenIterator::AdvanceBackwardToNonEmptySection() {}

}  // namespace blink