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

Unified Diff: third_party/WebKit/Source/core/style/BorderEdge.h

Issue 2640143005: Support subpixel layout for borders. (Closed)
Patch Set: Rebaselined tests. Created 3 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 side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/style/BorderEdge.h
diff --git a/third_party/WebKit/Source/core/style/BorderEdge.h b/third_party/WebKit/Source/core/style/BorderEdge.h
index 7a41314ac1467890ea9ee0773cb824c4384f0ee5..56942e6fd2e7d288740e57e37cae60af2b04b805 100644
--- a/third_party/WebKit/Source/core/style/BorderEdge.h
+++ b/third_party/WebKit/Source/core/style/BorderEdge.h
@@ -15,7 +15,7 @@ struct BorderEdge {
STACK_ALLOCATED();
public:
- BorderEdge(int edgeWidth,
+ BorderEdge(float edgeWidth,
const Color& edgeColor,
EBorderStyle edgeStyle,
bool edgeIsPresent = true);
@@ -26,7 +26,7 @@ struct BorderEdge {
bool presentButInvisible() const;
bool obscuresBackgroundEdge() const;
bool obscuresBackground() const;
- int usedWidth() const;
+ float usedWidth() const;
bool sharesColorWith(const BorderEdge& other) const;
@@ -34,14 +34,16 @@ struct BorderEdge {
enum DoubleBorderStripe { DoubleBorderStripeOuter, DoubleBorderStripeInner };
- int getDoubleBorderStripeWidth(DoubleBorderStripe) const;
+ float getDoubleBorderStripeWidth(DoubleBorderStripe) const;
+
+ float width() const { return m_width; }
- int width;
Color color;
bool isPresent;
private:
unsigned style : 4; // EBorderStyle
+ float m_width;
};
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/style/BorderData.h ('k') | third_party/WebKit/Source/core/style/BorderEdge.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698