资 源 简 介
//建立顶级窗口
toplevel = XtVaAppInitialize[&app, "DrawArea", NULL, 0,
&argc, argv, NULL, NULL]
//建立drawarea
n = 0
XtSetArg[args[n], XmNwidth, 500 ] n++
XtSetArg[args[n], XmNheight, 500 ] n++
drawarea = XmCreateDrawingArea[toplevel, "drawarea", args, n]
XtManageChild[drawarea]
//建立绘图所用的GC
prepare[]