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

Unified Diff: packages/charted/lib/svg/shapes/rect.dart

Issue 1521693002: Roll Observatory deps (charted -> ^0.3.0) (Closed) Base URL: https://chromium.googlesource.com/external/github.com/dart-lang/observatory_pub_packages.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « packages/charted/lib/svg/shapes/line.dart ('k') | packages/charted/pubspec.yaml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: packages/charted/lib/svg/shapes/rect.dart
diff --git a/packages/charted/lib/svg/shapes/rect.dart b/packages/charted/lib/svg/shapes/rect.dart
index 554efbf04266f79ffb53bdc29825ad6369be3280..cd89cad471828319287f17aa89c8daa6bffd4f2e 100644
--- a/packages/charted/lib/svg/shapes/rect.dart
+++ b/packages/charted/lib/svg/shapes/rect.dart
@@ -11,17 +11,17 @@ part of charted.svg.shapes;
/// Draw a rectangle at [x], [y] which is [width] pixels wide and
/// [height] pixels height. [topLeft], [topRight], [bottomRight] and
/// [bottomLeft] are the corner radius at each of the four corners.
-String roundedRect(int x, int y, int width, int height,
- int topLeft, int topRight, int bottomRight, int bottomLeft) =>
- 'M${x+topLeft},${y} '
- 'L${x+width-topRight},${y} '
- 'Q${x+width},${y} ${x+width},${y+topRight}'
- 'L${x+width},${y+height-bottomRight} '
- 'Q${x+width},${y+height} ${x+width-bottomRight},${y+height}'
- 'L${x+bottomLeft},${y+height} '
- 'Q${x},${y+height} ${x},${y+height-bottomLeft}'
- 'L${x},${y+topLeft} '
- 'Q${x},${y} ${x+topLeft},${y} Z';
+String roundedRect(int x, int y, int width, int height, int topLeft,
+ int topRight, int bottomRight, int bottomLeft) =>
+ 'M${x+topLeft},${y} '
+ 'L${x+width-topRight},${y} '
+ 'Q${x+width},${y} ${x+width},${y+topRight}'
+ 'L${x+width},${y+height-bottomRight} '
+ 'Q${x+width},${y+height} ${x+width-bottomRight},${y+height}'
+ 'L${x+bottomLeft},${y+height} '
+ 'Q${x},${y+height} ${x},${y+height-bottomLeft}'
+ 'L${x},${y+topLeft} '
+ 'Q${x},${y} ${x+topLeft},${y} Z';
/// Draw a rectangle with rounded corners on both corners on the right.
String rightRoundedRect(int x, int y, int width, int height, int radius) {
« no previous file with comments | « packages/charted/lib/svg/shapes/line.dart ('k') | packages/charted/pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698