mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
style: Preserve calc() rounding behavior.
See the comment. I don't really this is ideal, I filed bug 1528114 to investigate changing that. Differential Revision: https://phabricator.services.mozilla.com/D19584
This commit is contained in:
parent
f7a59bf0ee
commit
d4ad12bee4
1 changed files with 5 additions and 2 deletions
|
@ -90,14 +90,17 @@ item_types = ["enums", "structs", "typedefs"]
|
||||||
// Defined in nsStyleCoord.h
|
// Defined in nsStyleCoord.h
|
||||||
static constexpr inline StyleLengthPercentage Zero();
|
static constexpr inline StyleLengthPercentage Zero();
|
||||||
static inline StyleLengthPercentage FromAppUnits(nscoord);
|
static inline StyleLengthPercentage FromAppUnits(nscoord);
|
||||||
|
inline CSSCoord LengthInCSSPixels() const;
|
||||||
|
private:
|
||||||
|
inline nscoord LengthComponent() const;
|
||||||
|
public:
|
||||||
|
inline float Percentage() const;
|
||||||
inline bool HasPercent() const;
|
inline bool HasPercent() const;
|
||||||
inline bool ConvertsToLength() const;
|
inline bool ConvertsToLength() const;
|
||||||
inline nscoord ToLength() const;
|
inline nscoord ToLength() const;
|
||||||
inline bool ConvertsToPercentage() const;
|
inline bool ConvertsToPercentage() const;
|
||||||
inline bool HasLengthAndPercentage() const;
|
inline bool HasLengthAndPercentage() const;
|
||||||
inline float ToPercentage() const;
|
inline float ToPercentage() const;
|
||||||
inline CSSCoord LengthInCSSPixels() const;
|
|
||||||
inline float Percentage() const;
|
|
||||||
inline CSSCoord ResolveToCSSPixels(CSSCoord aPercentageBasisInCSSPixels) const;
|
inline CSSCoord ResolveToCSSPixels(CSSCoord aPercentageBasisInCSSPixels) const;
|
||||||
template<typename T> inline CSSCoord ResolveToCSSPixelsWith(T aPercentageGetter) const;
|
template<typename T> inline CSSCoord ResolveToCSSPixelsWith(T aPercentageGetter) const;
|
||||||
inline nscoord Resolve(nscoord aPercentageBasis) const;
|
inline nscoord Resolve(nscoord aPercentageBasis) const;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue