Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(5)

Side by Side Diff: Source/core/layout/MultiColumnFragmentainerGroup.h

Issue 1102273004: [New Multicolumn] flowThreadTranslationAtOffset() needs to be relative to the flow thread. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef MultiColumnFragmentainerGroup_h 5 #ifndef MultiColumnFragmentainerGroup_h
6 #define MultiColumnFragmentainerGroup_h 6 #define MultiColumnFragmentainerGroup_h
7 7
8 #include "core/layout/LayoutMultiColumnFlowThread.h" 8 #include "core/layout/LayoutMultiColumnFlowThread.h"
9 9
10 namespace blink { 10 namespace blink {
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // breaks assumed so far into account. 76 // breaks assumed so far into account.
77 unsigned findRunWithTallestColumns() const; 77 unsigned findRunWithTallestColumns() const;
78 78
79 // Given the current list of content runs, make assumptions about where we n eed to insert 79 // Given the current list of content runs, make assumptions about where we n eed to insert
80 // implicit breaks (if there's room for any at all; depending on the number of explicit breaks), 80 // implicit breaks (if there's room for any at all; depending on the number of explicit breaks),
81 // and store the results. This is needed in order to balance the columns. 81 // and store the results. This is needed in order to balance the columns.
82 void distributeImplicitBreaks(); 82 void distributeImplicitBreaks();
83 83
84 LayoutUnit calculateColumnHeight(BalancedColumnHeightCalculation) const; 84 LayoutUnit calculateColumnHeight(BalancedColumnHeightCalculation) const;
85 85
86 LayoutSize translationAtColumn(unsigned columnIndex) const;
86 LayoutRect columnRectAt(unsigned columnIndex) const; 87 LayoutRect columnRectAt(unsigned columnIndex) const;
87 LayoutUnit logicalTopInFlowThreadAt(unsigned columnIndex) const { return m_l ogicalTopInFlowThread + columnIndex * m_columnHeight; } 88 LayoutUnit logicalTopInFlowThreadAt(unsigned columnIndex) const { return m_l ogicalTopInFlowThread + columnIndex * m_columnHeight; }
88 LayoutRect flowThreadPortionRectAt(unsigned columnIndex) const; 89 LayoutRect flowThreadPortionRectAt(unsigned columnIndex) const;
89 LayoutRect flowThreadPortionOverflowRect(const LayoutRect& flowThreadPortion , unsigned columnIndex, unsigned columnCount, LayoutUnit columnGap) const; 90 LayoutRect flowThreadPortionOverflowRect(const LayoutRect& flowThreadPortion , unsigned columnIndex, unsigned columnCount, LayoutUnit columnGap) const;
90 91
91 enum ColumnIndexCalculationMode { 92 enum ColumnIndexCalculationMode {
92 ClampToExistingColumns, // Stay within the range of already existing col umns. 93 ClampToExistingColumns, // Stay within the range of already existing col umns.
93 AssumeNewColumns // Allow column indices outside the range of already ex isting columns. 94 AssumeNewColumns // Allow column indices outside the range of already ex isting columns.
94 }; 95 };
95 unsigned columnIndexAtOffset(LayoutUnit offsetInFlowThread, ColumnIndexCalcu lationMode = ClampToExistingColumns) const; 96 unsigned columnIndexAtOffset(LayoutUnit offsetInFlowThread, ColumnIndexCalcu lationMode = ClampToExistingColumns) const;
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
172 173
173 private: 174 private:
174 LayoutMultiColumnSet& m_columnSet; 175 LayoutMultiColumnSet& m_columnSet;
175 176
176 Vector<MultiColumnFragmentainerGroup, 1> m_groups; 177 Vector<MultiColumnFragmentainerGroup, 1> m_groups;
177 }; 178 };
178 179
179 } // namespace blink 180 } // namespace blink
180 181
181 #endif // MultiColumnFragmentainerGroup_h 182 #endif // MultiColumnFragmentainerGroup_h
OLDNEW
« no previous file with comments | « LayoutTests/fast/multicol/very-wide-rtl-crash-expected.txt ('k') | Source/core/layout/MultiColumnFragmentainerGroup.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698