Last active
August 29, 2015 14:20
-
-
Save eseidelGoogle/56973c1495e1d256c827 to your computer and use it in GitHub Desktop.
Painting a full-screen circle
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "dart:sky"; | |
Screen screen = window.screen; | |
double width = screen.availableWidth; | |
double height = screen.availableHeight; | |
PaintingContext ctx = new PaintingContext(width, height); | |
double radius = min(width, height) * .9; | |
Paint paint; | |
paint.setARGB(1, 0, 1, 0); | |
ctx.drawCircle(width / 2, height / 2, radius, paint); | |
window.rootDisplayList = ctx; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment