#include "testing/gtest/include/gtest/gtest.h"
#include "third_party/blink/renderer/core/layout/geometry/transform_state.h"
#include "third_party/blink/renderer/core/layout/layout_inline.h"
#include "third_party/blink/renderer/core/layout/layout_multi_column_flow_thread.h"
#include "third_party/blink/renderer/core/layout/layout_view.h"
#include "third_party/blink/renderer/core/paint/paint_layer_scrollable_area.h"
#include "third_party/blink/renderer/core/testing/core_unit_test_helper.h"
namespace blink {
class MapCoordinatesTest : public RenderingTest { … };
PhysicalOffset MapCoordinatesTest::AdjustForFrameScroll(
const PhysicalOffset& point) const { … }
PhysicalOffset MapCoordinatesTest::MapLocalToAncestor(
const LayoutObject* object,
const LayoutBoxModelObject* ancestor,
PhysicalOffset point,
MapCoordinatesFlags mode) const { … }
gfx::QuadF MapCoordinatesTest::MapLocalToAncestor(
const LayoutObject* object,
const LayoutBoxModelObject* ancestor,
gfx::QuadF quad,
MapCoordinatesFlags mode) const { … }
PhysicalOffset MapCoordinatesTest::MapAncestorToLocal(
const LayoutObject* object,
const LayoutBoxModelObject* ancestor,
PhysicalOffset point,
MapCoordinatesFlags mode) const { … }
gfx::QuadF MapCoordinatesTest::MapAncestorToLocal(
const LayoutObject* object,
const LayoutBoxModelObject* ancestor,
gfx::QuadF quad,
MapCoordinatesFlags mode) const { … }
TEST_F(MapCoordinatesTest, SimpleText) { … }
TEST_F(MapCoordinatesTest, SimpleInline) { … }
TEST_F(MapCoordinatesTest, SimpleBlock) { … }
TEST_F(MapCoordinatesTest, OverflowClip) { … }
TEST_F(MapCoordinatesTest, TextInRelPosInline) { … }
TEST_F(MapCoordinatesTest, RelposInline) { … }
TEST_F(MapCoordinatesTest, RelposInlineInRelposInline) { … }
TEST_F(MapCoordinatesTest, RelPosBlock) { … }
TEST_F(MapCoordinatesTest, AbsPos) { … }
TEST_F(MapCoordinatesTest, AbsPosAuto) { … }
TEST_F(MapCoordinatesTest, FixedPos) { … }
TEST_F(MapCoordinatesTest, FixedPosAuto) { … }
TEST_F(MapCoordinatesTest, FixedPosInFixedPos) { … }
TEST_F(MapCoordinatesTest, FixedPosInFixedPosScrollView) { … }
TEST_F(MapCoordinatesTest, FixedPosInAbsolutePosScrollView) { … }
TEST_F(MapCoordinatesTest, FixedPosInTransform) { … }
TEST_F(MapCoordinatesTest, FixedPosInContainPaint) { … }
TEST_F(MapCoordinatesTest, FixedPosInIFrameWhenMainFrameScrolled) { … }
TEST_F(MapCoordinatesTest, IFrameTransformed) { … }
TEST_F(MapCoordinatesTest, FixedPosInScrolledIFrameWithTransform) { … }
TEST_F(MapCoordinatesTest, MulticolWithText) { … }
TEST_F(MapCoordinatesTest, MulticolWithInline) { … }
TEST_F(MapCoordinatesTest, MulticolWithBlock) { … }
TEST_F(MapCoordinatesTest, MulticolWithBlockAbove) { … }
TEST_F(MapCoordinatesTest, NestedMulticolWithBlock) { … }
TEST_F(MapCoordinatesTest, MulticolWithAbsPosInRelPos) { … }
TEST_F(MapCoordinatesTest, MulticolWithAbsPosInInlineRelPos) { … }
TEST_F(MapCoordinatesTest, MulticolWithAbsPosNotContained) { … }
TEST_F(MapCoordinatesTest, MulticolRtl) { … }
TEST_F(MapCoordinatesTest, MulticolWithLargeBorder) { … }
TEST_F(MapCoordinatesTest, FlippedBlocksWritingModeWithText) { … }
TEST_F(MapCoordinatesTest, FlippedBlocksWritingModeWithInline) { … }
TEST_F(MapCoordinatesTest, FlippedBlocksWritingModeWithBlock) { … }
TEST_F(MapCoordinatesTest, Table) { … }
static bool FloatValuesAlmostEqual(float expected, float actual) { … }
static bool QuadsAlmostEqual(const gfx::QuadF& expected,
const gfx::QuadF& actual) { … }
#define EXPECT_QUADF_EQ(expected, actual) …
TEST_F(MapCoordinatesTest, Transforms) { … }
TEST_F(MapCoordinatesTest, SVGShape) { … }
TEST_F(MapCoordinatesTest, SVGShapeScale) { … }
TEST_F(MapCoordinatesTest, SVGShapeWithViewBoxWithoutScale) { … }
TEST_F(MapCoordinatesTest, SVGShapeWithViewBoxWithScale) { … }
TEST_F(MapCoordinatesTest, SVGShapeWithViewBoxWithNonZeroOffset) { … }
TEST_F(MapCoordinatesTest, SVGShapeWithViewBoxWithNonZeroOffsetAndScale) { … }
TEST_F(MapCoordinatesTest, SVGForeignObject) { … }
TEST_F(MapCoordinatesTest, LocalToAbsoluteTransform) { … }
TEST_F(MapCoordinatesTest, LocalToAncestorTransform) { … }
TEST_F(MapCoordinatesTest, LocalToAbsoluteTransformFlattens) { … }
TEST_F(MapCoordinatesTest, Transform3DWithOffset) { … }
TEST_F(MapCoordinatesTest, Transform3DWithOffset2) { … }
TEST_F(MapCoordinatesTest, IgnoreScrollOffset) { … }
TEST_F(MapCoordinatesTest, IgnoreScrollOffsetForInline) { … }
TEST_F(MapCoordinatesTest, IgnoreScrollOffsetWithWritingModes) { … }
TEST_F(MapCoordinatesTest, FixedPositionWithScrollOffset) { … }
TEST_F(MapCoordinatesTest, FixedPositionWithScrollOffsetVerticalRL) { … }
TEST_F(MapCoordinatesTest, FixedPositionUnderTransformWithScrollOffset) { … }
TEST_F(MapCoordinatesTest,
IgnoreScrollOffsetWithWritingModesAndNonOverlayScrollbar) { … }
}