Skip to content

Instantly share code, notes, and snippets.

@jcleblanc
Created March 18, 2010 22:20
Show Gist options
  • Select an option

  • Save jcleblanc/336983 to your computer and use it in GitHub Desktop.

Select an option

Save jcleblanc/336983 to your computer and use it in GitHub Desktop.
var example = document.getElementById('test_canvas');
var context = example.getContext('2d');
context.fillStyle = "rgb(255,0,0)";
context.fillRect(30, 30, 50, 50);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment