See also e575 The Quintessential Drawing Program. public void paint(Graphics g) { // Set the desired font if different from default font String family = "Serif"; int style = Font.PLAIN; int size = 12; Font font = new Font(family, style, size); g…
var c = canvas.getContext("2d");//get canvas 2d context canvas including a proposed 3D context; c.fillStyle("#ffffff");//rawing canvas background color c.fillRectangle(sx,sy,ex,ey);//drawing a rectanle ,the (sx,sy) is start point,(ex,e…
微软出的IE9支持HTML5,但因为不支持XP系统,暂时我还用不了. 即使能用,现阶段如果开发HTML5页面,并考虑到兼容性问题的话,恐怕也得让自己的界面支持IE6-8吧. 首先,需要让IE支持HTML5标签.这个简单,随便在网上搜一下就能找到.下载一个html5.js,并拷贝到自己的目录里就可以了. 现在写一段简单代码,其功能是在页面上放置一个canvas,并画一个红色圆圈. 1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transition…
Subline Text中,点击Preferences,选择Settings - Default 全部属性解析 // While you can edit this file, it's best to put your changes in // "User/Preferences.sublime-settings", which overrides the settings in here. // // Settings may also be placed in file typ…