国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 編程 > JSP > 正文

用jsp繪圖擇

2024-09-05 00:19:30
字體:
來源:轉載
供稿:網友



<object id=directdraw
classid="clsid:369303c2-d7ac-11d0-89d5-00a0c90833e6"
style="positiion:absolute;top:0;left:0;width:320;height:200"
>
<param name="line0001" value="繪圖指令1">
<param name="line0002" value="繪圖指令2">
...
</object>
繪圖指令分類:
(一)常見形狀
1.矩形類 //rotation是以度為單位的旋轉角度
rect(x ,y, width, height, rotation) //矩形
oval(x ,y, width, height, rotation) //橢圓
roundrect(x ,y, width, height, arcwidth, archeight, rotation)
2.弧形類
arc(x ,y, width, height, startangle, arcangle, rotation) //弧形
pie(x ,y, width, height, startangle, arcangle, rotation) //餅圖
3.多邊形類
polygon(npoints, x1, y1, x2, y2, [x3, y3, ....], rotation) //閉合
polyline(npoints, x1, y1, x2, y2, [xn, yn, ....], rotation) //不閉合
(二)效果函數
1.線條效果
setlinecolor(r, g, b) //設置畫線顏色
setlinestyle(style) //style=(1:實線;2:虛線;0:隱藏)
2.填充效果
setfillcolor(r, g, b, backr, backg, backb)
setfillstyle(style) //style=(1:實心;2:透明;3:-;4:|;5:/;6:/;7:+;8:x)
(三)文字輸出函數
setfont('字體',width,height,r,g,b) //設置字體
text('要輸出的文字內容', x,y,z) //輸出文字

控制函數 //定義<object>后在<script></script>里使用。
引用格式:directdraw.functionname()
rotate(x-rotation, y-rotation, z-rotation) //旋轉
scale(x-scale,y-scale,z-scale) //縮放
translate(x-coordinate,y-coordinate,z-coordinate) //平移
setidentity() //復原
clear() //清除,清除后無法恢復!


發表評論 共有條評論
用戶名: 密碼:
驗證碼: 匿名發表
主站蜘蛛池模板: 上林县| 青神县| 青铜峡市| 乌拉特前旗| 石河子市| 日土县| 定边县| 西林县| 齐齐哈尔市| 新昌县| 南皮县| 红原县| 寻乌县| 龙岩市| 南安市| 乌鲁木齐县| 阜阳市| 堆龙德庆县| 龙胜| 牟定县| 阜新| 凭祥市| 永川市| 资中县| 江永县| 克山县| 台北县| 临高县| 边坝县| 扶余县| 清流县| 渭南市| 县级市| 沈丘县| 花莲县| 禹州市| 卢湾区| 铜山县| 新野县| 平利县| 四会市|