// display a simple splash screen until launcher is ready void BadaGraphicsManager::showSplash() { Canvas canvas; canvas.Construct(); canvas.SetBackgroundColor(Color::COLOR_BLACK); canvas.Clear(); int x = _videoMode.hardwareWidth / 3; int y = _videoMode.hardwareHeight / 3; Font *pFont = new Font(); pFont->Construct(FONT_STYLE_ITALIC | FONT_STYLE_BOLD, 55); canvas.SetFont(*pFont); canvas.SetForegroundColor(Color::COLOR_GREEN); canvas.DrawText(Point(x, y), L"ScummVM"); delete pFont; pFont = new Font(); pFont->Construct(FONT_STYLE_ITALIC | FONT_STYLE_BOLD, 35); canvas.SetFont(*pFont); canvas.SetForegroundColor(Color::COLOR_WHITE); canvas.DrawText(Point(x + 70, y + 50), L"Loading ..."); delete pFont; canvas.Show(); }
void JMChattControl::CreateElementCaptureImage(long nIndex) { stCHATT_DATA* pChattData = (stCHATT_DATA*)(__pArrayChattData->GetAt(nIndex)); rtCanvas.x = 0; rtCanvas.y = 0; rtCanvas.width = __stScreenInfo.rtScreen.width; rtCanvas.height = pChattData->rtElementBox.height; if( pChattData->nDataType != DATA_TYPE_DATE && !pChattData->bISend ) { rtCanvas.height += __stScreenInfo.nYouNameHeight; } Canvas *pCanvas = new Canvas(); pCanvas->Construct(rtCanvas); if( pChattData->nDataType == DATA_TYPE_TEXT ) { DrawChattDataText(pCanvas, pChattData); } else if( pChattData->nDataType == DATA_TYPE_IMAGE ) { DrawChattDataImage(pCanvas, pChattData); } else if( pChattData->nDataType == DATA_TYPE_DATE ) { DrawChattDataDate(pCanvas, pChattData); } if( pChattData->pBitmapCapture ) { delete pChattData->pBitmapCapture; pChattData->pBitmapCapture = null; } pChattData->pBitmapCapture = new Bitmap(); pChattData->pBitmapCapture->Construct(*pCanvas, rtCanvas); delete pCanvas; pCanvas = null; }