/*
	ARTemis (Graphic Editor for FM-TOWNS)
	(c) MATSUUCHI Ryosuke 1992,1993

	cmdpaint.c

	｢ペイント｣コマンド
*/


#include <stdio.h>

#include "ge.h"
#include "dispman.h"


void commandPaint()
{
	for(;;)
	{
		DMdispcsr(ms.x,ms.y);
		for (;;)
		{
			ms_get(&ms);
			if (ms.dx!=0 || ms.dy!=0 || ms.btn1!=OFF || ms.btn2!=OFF ||
			 key_chk()!=0)
				break;
		}
		DMerasecsr();
		scrollForCsr(1,1);
		if (ms.btn1==OFFON)
		{
			EIMbackup();
			page_edit();
			do_paint(DMimage_getx(ms.x),DMimage_gety(ms.y));
			page_menu();
		}
		if (ms.btn2==OFFON)
			break;
	}
}


/* end of cmdpaint.c */
