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

Side by Side Diff: third_party/WebKit/Source/core/layout/line/RootInlineBox.h

Issue 1647313003: Continue converting to explicit LayoutUnit constructors (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@explicitContstructors
Patch Set: Add TODO Created 4 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2006, 2007, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2006, 2007, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 LayoutUnit lineBottom() const { return m_lineBottom; } 54 LayoutUnit lineBottom() const { return m_lineBottom; }
55 55
56 LayoutUnit lineTopWithLeading() const { return m_lineTopWithLeading; } 56 LayoutUnit lineTopWithLeading() const { return m_lineTopWithLeading; }
57 LayoutUnit lineBottomWithLeading() const { return m_lineBottomWithLeading; } 57 LayoutUnit lineBottomWithLeading() const { return m_lineBottomWithLeading; }
58 58
59 LayoutUnit paginationStrut() const { return m_paginationStrut; } 59 LayoutUnit paginationStrut() const { return m_paginationStrut; }
60 void setPaginationStrut(LayoutUnit strut) { m_paginationStrut = strut; } 60 void setPaginationStrut(LayoutUnit strut) { m_paginationStrut = strut; }
61 61
62 LayoutUnit selectionTop() const; 62 LayoutUnit selectionTop() const;
63 LayoutUnit selectionBottom() const; 63 LayoutUnit selectionBottom() const;
64 LayoutUnit selectionHeight() const { return max<LayoutUnit>(0, selectionBott om() - selectionTop()); } 64 LayoutUnit selectionHeight() const { return (selectionBottom() - selectionTo p()).clampNegativeToZero(); }
65 65
66 LayoutUnit selectionTopAdjustedForPrecedingBlock() const; 66 LayoutUnit selectionTopAdjustedForPrecedingBlock() const;
67 LayoutUnit selectionHeightAdjustedForPrecedingBlock() const { return max<Lay outUnit>(0, selectionBottom() - selectionTopAdjustedForPrecedingBlock()); } 67 LayoutUnit selectionHeightAdjustedForPrecedingBlock() const { return (select ionBottom() - selectionTopAdjustedForPrecedingBlock()).clampNegativeToZero(); }
68 68
69 LayoutUnit blockDirectionPointInLine() const; 69 LayoutUnit blockDirectionPointInLine() const;
70 70
71 LayoutUnit alignBoxesInBlockDirection(LayoutUnit heightOfBlock, GlyphOverflo wAndFallbackFontsMap&, VerticalPositionCache&); 71 LayoutUnit alignBoxesInBlockDirection(LayoutUnit heightOfBlock, GlyphOverflo wAndFallbackFontsMap&, VerticalPositionCache&);
72 void setLineTopBottomPositions(LayoutUnit top, LayoutUnit bottom, LayoutUnit topWithLeading, LayoutUnit bottomWithLeading, LayoutUnit selectionBottom = Layo utUnit::min()) 72 void setLineTopBottomPositions(LayoutUnit top, LayoutUnit bottom, LayoutUnit topWithLeading, LayoutUnit bottomWithLeading, LayoutUnit selectionBottom = Layo utUnit::min())
73 { 73 {
74 m_lineTop = top; 74 m_lineTop = top;
75 m_lineBottom = bottom; 75 m_lineBottom = bottom;
76 m_lineTopWithLeading = topWithLeading; 76 m_lineTopWithLeading = topWithLeading;
77 m_lineBottomWithLeading = bottomWithLeading; 77 m_lineBottomWithLeading = bottomWithLeading;
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 LayoutUnit m_lineBottom; 191 LayoutUnit m_lineBottom;
192 LayoutUnit m_lineTopWithLeading; 192 LayoutUnit m_lineTopWithLeading;
193 LayoutUnit m_lineBottomWithLeading; 193 LayoutUnit m_lineBottomWithLeading;
194 LayoutUnit m_selectionBottom; 194 LayoutUnit m_selectionBottom;
195 LayoutUnit m_paginationStrut; 195 LayoutUnit m_paginationStrut;
196 }; 196 };
197 197
198 } // namespace blink 198 } // namespace blink
199 199
200 #endif // RootInlineBox_h 200 #endif // RootInlineBox_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/layout/line/LineWidth.h ('k') | third_party/WebKit/Source/core/layout/line/RootInlineBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698