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

Side by Side Diff: third_party/WebKit/Source/core/style/ComputedStyle.h

Issue 1820773002: getComputedStyle() should return used value for 'line-height' (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * (C) 2000 Antti Koivisto (koivisto@kde.org) 3 * (C) 2000 Antti Koivisto (koivisto@kde.org)
4 * (C) 2000 Dirk Mueller (mueller@kde.org) 4 * (C) 2000 Dirk Mueller (mueller@kde.org)
5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved. 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ights reserved.
6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com)
7 * 7 *
8 * This library is free software; you can redistribute it and/or 8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public 9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either 10 * License as published by the Free Software Foundation; either
(...skipping 615 matching lines...) Expand 10 before | Expand all | Expand 10 after
626 626
627 float zoom() const { return visual->m_zoom; } 627 float zoom() const { return visual->m_zoom; }
628 float effectiveZoom() const { return rareInheritedData->m_effectiveZoom; } 628 float effectiveZoom() const { return rareInheritedData->m_effectiveZoom; }
629 629
630 TextDirection direction() const { return static_cast<TextDirection>(inherite d_flags._direction); } 630 TextDirection direction() const { return static_cast<TextDirection>(inherite d_flags._direction); }
631 bool isLeftToRightDirection() const { return direction() == LTR; } 631 bool isLeftToRightDirection() const { return direction() == LTR; }
632 bool selfOrAncestorHasDirAutoAttribute() const { return rareInheritedData->m _selfOrAncestorHasDirAutoAttribute; } 632 bool selfOrAncestorHasDirAutoAttribute() const { return rareInheritedData->m _selfOrAncestorHasDirAutoAttribute; }
633 633
634 const Length& specifiedLineHeight() const; 634 const Length& specifiedLineHeight() const;
635 Length lineHeight() const; 635 Length lineHeight() const;
636 int computedLineHeight() const; 636 float computedLineHeight() const;
Timothy Loh 2016/04/11 03:32:16 Why is this changing?
nainar 2016/04/11 04:42:15 If I retain it as int we lose out on information.
Timothy Loh 2016/04/11 04:44:43 Doesn't this mean we're changing layout behaviour
637 637
638 EWhiteSpace whiteSpace() const { return static_cast<EWhiteSpace>(inherited_f lags._white_space); } 638 EWhiteSpace whiteSpace() const { return static_cast<EWhiteSpace>(inherited_f lags._white_space); }
639 static bool autoWrap(EWhiteSpace ws) 639 static bool autoWrap(EWhiteSpace ws)
640 { 640 {
641 // Nowrap and pre don't automatically wrap. 641 // Nowrap and pre don't automatically wrap.
642 return ws != NOWRAP && ws != PRE; 642 return ws != NOWRAP && ws != PRE;
643 } 643 }
644 644
645 bool autoWrap() const 645 bool autoWrap() const
646 { 646 {
(...skipping 1399 matching lines...) Expand 10 before | Expand all | Expand 10 after
2046 } 2046 }
2047 2047
2048 inline bool ComputedStyle::hasPseudoElementStyle() const 2048 inline bool ComputedStyle::hasPseudoElementStyle() const
2049 { 2049 {
2050 return noninherited_flags.pseudoBits & ElementPseudoIdMask; 2050 return noninherited_flags.pseudoBits & ElementPseudoIdMask;
2051 } 2051 }
2052 2052
2053 } // namespace blink 2053 } // namespace blink
2054 2054
2055 #endif // ComputedStyle_h 2055 #endif // ComputedStyle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698