import Graphics; import Graphics2D; import GUI; // グラフィックスデータとレンダラーの生成 int graphicsID = newGraphics( ); int rendererID = newGraphics2DRenderer( 800, 600, graphicsID ); // 表示画面の生成 int windowID = newWindow( 0, 0, 800, 600, " Hello 2DCG ! " ); int labelID = newImageLabel( 0, 0, 800, 600, graphicsID ); mountComponent( labelID, windowID ); // 背景色を青に設定 setGraphics2DColor( rendererID, 0, 0, 255, 255 ); // グラフィックスを背景色でクリア clearGraphics2D( rendererID ); // GUI の描画 paintComponent( labelID ); paintComponent( windowID );