| Index: Source/core/rendering/RenderMultiColumnSpannerSet.h
|
| diff --git a/Source/core/rendering/RenderMultiColumnSpannerSet.h b/Source/core/rendering/RenderMultiColumnSpannerSet.h
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..e3dda8837aaf1c837d0917ec88185e067c297f30
|
| --- /dev/null
|
| +++ b/Source/core/rendering/RenderMultiColumnSpannerSet.h
|
| @@ -0,0 +1,52 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +#ifndef RenderMultiColumnSpannerSet_h
|
| +#define RenderMultiColumnSpannerSet_h
|
| +
|
| +#include "core/rendering/RenderMultiColumnSet.h"
|
| +
|
| +namespace blink {
|
| +
|
| +// "Column" set for column-span:all elements. Positions the portion of the flow thread that a
|
| +// spanner takes up. The actual renderer that sets column-span all is laid out as part of flow
|
| +// thread layout (although it cannot use the flow thread width when calculating its own with; it has
|
| +// to pretend that the containing block is the multicol container, not the flow
|
| +// thread). RenderMultiColumnSpannerSet just makes sure that it's positioned correctly among other
|
| +// column sets, within the multicol container.
|
| +//
|
| +// FIXME: should consider not inheriting from RenderMultiColumnSet (but rather from some common base
|
| +// class). Most of what's in RenderMultiColumnSet is of no interest to us.
|
| +class RenderMultiColumnSpannerSet final : public RenderMultiColumnSet {
|
| +public:
|
| + virtual bool isOfType(RenderObjectType type) const override { return type == RenderObjectRenderMultiColumnSpannerSet || RenderMultiColumnSet::isOfType(type); }
|
| +
|
| + static RenderMultiColumnSpannerSet* createAnonymous(RenderMultiColumnFlowThread*, RenderStyle* parentStyle, RenderBox*);
|
| +
|
| + RenderBox* rendererInFlowThread() const { return m_rendererInFlowThread; }
|
| +
|
| + // Copy margin properties from the column-span:all renderer to this spanner set. Block direction
|
| + // margins on column spanners are not to collapse with anything in the adjacent columns. Having
|
| + // to worry about that in general block layout code inside the flow thread would be complex and
|
| + // messy, so they are applied on the spanner set instead, and ignored on the actual
|
| + // column-span:all renderer during flow thread layout.
|
| + void updateMarginProperties();
|
| +
|
| +protected:
|
| + virtual bool recalculateColumnHeight(BalancedHeightCalculation) override;
|
| + virtual void computeLogicalHeight(LayoutUnit logicalHeight, LayoutUnit logicalTop, LogicalExtentComputedValues&) const override;
|
| + virtual LayoutUnit pageLogicalHeight() const override;
|
| + virtual const char* renderName() const override;
|
| +
|
| +private:
|
| + RenderMultiColumnSpannerSet(RenderMultiColumnFlowThread*, RenderBox*);
|
| +
|
| + RenderBox* m_rendererInFlowThread; // The actual column-span:all renderer inside the flow thread.
|
| +};
|
| +
|
| +DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderMultiColumnSpannerSet, isRenderMultiColumnSpannerSet());
|
| +
|
| +} // namespace blink
|
| +
|
| +#endif
|
|
|