#include "GForcePixPort.h"


#if EG_MAC
#define __consoleFont		"Monaco"

#elif EG_WIN
#define __consoleFont		"Courier New"

#else
#define __consoleFont           "charter"
/* FIXME */
#endif



GForcePixPort::GForcePixPort() {

	mConsoleFontID = CreateFont();
	AssignFont( mConsoleFontID, __consoleFont, 9 );

	mTrackTextFontID = CreateFont();
}


void GForcePixPort::SetTrackTextFont( UtilStr& inName, long inSize ) {

	AssignFont( mTrackTextFontID, inName.getCStr(), inSize );
}
/*
void GForcePixPort::CopyBits( GrafPtr inPort, const Rect* inSrce, const Rect* inDest )
{
#define sf ((GForcePixPort*) inPort)->surface
	SDL_Rect srcrect, destrect;
	int result;

	g_print("%p / %p / %p\n", sf, surface, SDL_GetVideoSurface());
	
	if ((sf == SDL_GetVideoSurface()) && 
		(inSrce -> left <= inSrce -> right && inSrce -> top <= inSrce -> bottom &&
		inDest -> left <= inDest -> right && inDest -> top <= inDest -> bottom ))
	{
		g_print("Blit all: %i / %i / %i / %i || %i / %i / %i / %i\n",
			srcrect.x, srcrect.y, srcrect.w, srcrect.h,
			destrect.x, destrect.y, destrect.w, destrect.h);
		srcrect.x = inSrce -> left;
		srcrect.y = inSrce -> top;
		srcrect.w = inSrce -> right - inSrce -> left;
		srcrect.h = inSrce -> bottom - inSrce -> top;

		destrect.x = inDest -> left;
		destrect.y = inDest -> top;
		destrect.w = inDest -> right - inDest -> left;
		destrect.h = inDest -> bottom - inDest -> top;

//		g_print("SF: %i / %i / %i / %i\n", sf->offset, 
//			sf->flags & SDL_HWSURFACE,
//			sf->flags & SDL_ASYNCBLIT,
//			sf->flags & SDL_RLEACCEL);

		result = SDL_BlitSurface(surface, &srcrect, ((GForcePixPort*) inPort)->surface, &destrect);
	}
#undef df
}
*/
