![](http://www.gnu-darwin.org/hexley-gd-sm.png)
|
Go to the first, previous, next, last section, table of contents.
- open_canvas(id[,geometry])
-
:: 描画用ウィンドウ (キャンバス) を生成する.
- clear_canvas(id,index)
-
:: キャンバスをクリアする.
- draw_obj(id,index,pointorsegment [,color])
-
:: キャンバス上に点または線分を描画する.
- draw_string(id,index,[x,y],string [,color])
-
:: キャンバス上に文字列を描画する.
- return
-
0
- id, index, color, x, y
-
整数
- pointorsegment
-
リスト
- string
-
文字列
-
これらは OpenXM サーバ `ox_plot' (Windows 上では `engine')
により提供される.
-
open_canvas は, 描画用のウィンドウ(キャンバス)を生成する.
geometry によりウィンドウのサイズを pixel 単位で [x,y] で指定する.
default size は [300 ,300 ].
キャンバスの識別子として, 整数値を OpenXM サーバのスタックに push する.
この識別子は draw_obj の呼び出しに必要であり, ox_pop_cmo に
より取り出して保持する必要がある.
-
clear_canvas は, サーバ id id, キャンバス id index
で指定されるキャンバスをクリアする.
-
draw_obj は, サーバ id id, キャンバス id index
で指定されるキャンバスに点または線分を描画する. pointorsegment
が [x,y] の場合点の座標, [x,y,u,v] の場合 [x,y],
[u,v] を結ぶ線分を表すと見なされる.
キャンバスの座標は, 左上隅を原点として横方向に
第一座標, 縦方向に第二座標をとる. 値は pixel 単位で指定する.
color の指定がある場合, color/65536 mod 256,
color/256 mod 256, color mod 256 をそれぞれ Red, Green, Blue
の値 (最大 255) とみなす.
-
draw_string は, サーバ id id, キャンバス id index
で指定されるキャンバスに文字列を描画する. 位置は [x,y] により指定する.
[182] Id=ox_launch_nox(0,"ox_plot");
0
[183] open_canvas(Id);
0
[184] Ind=ox_pop_cmo(Id);
0
[185] draw_obj(Id,Ind,[100,100]);
0
[186] draw_obj(Id,Ind,[200,200],0xffff);
0
[187] draw_obj(Id,Ind,[10,10,50,50],0xff00ff);
0
[187] draw_string(Id,Ind,[100,50],"hello",0xffff00);
0
[189] clear_canvas(Id,Ind);
0
- 参照
-
section
ox_launch , ox_launch_nox , ox_shutdown , section ox_reset ,ox_intr ,register_handler , section ox_pop_cmo , ox_pop_local .
Go to the first, previous, next, last section, table of contents.
|