예제 #1
0
void main()
{
	CApplicationFonts oFonts;
	oFonts.Initialize();

	CMetaFile oMetaFile(&oFonts);
	ConvertFolder(oMetaFile, L"D://test//_svm//1//", c_lMetaSvm);
	//ConvertFolder(oMetaFile, L"D://Test Files//Wmf//Test//", c_lMetaWmf);
	//ConvertFolder(oMetaFile, L"D://Test Files//Emf//Temp//", c_lMetaEmf);

	//_CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF);
	//_CrtDumpMemoryLeaks();
}
예제 #2
0
int _tmain(int argc, _TCHAR* argv[])
{
	CApplicationFonts oFonts;
	oFonts.Initialize();

	std::wstring	sMetafilesFolder	= L"D://test//_emf//";
	int				nType				= MetaFile::c_lMetaEmf;
	if (argc > 1)
		sMetafilesFolder = argv[1];

	if (argc > 2)
	{
		try
		{
			nType = _wtoi(argv[2]);
		}
		catch(...)
		{
		}
	}

	MetaFile::CMetaFile oMetaFile(&oFonts);

	if (NSFile::CFileBinary::Exists(sMetafilesFolder))
	{	
		NSHtmlRenderer::CASCSVGWriter oWriterSVG;		
		oWriterSVG.SetFontManager(oMetaFile.get_FontManager());
		
		ConvertFileToSVG(oMetaFile, oWriterSVG, sMetafilesFolder);
	}
	else if (NSDirectory::Exists(sMetafilesFolder))
	{
		ConvertFolder(oMetaFile, sMetafilesFolder, nType);
	}

	return 0;
	//_CrtSetDbgFlag(_CRTDBG_ALLOC_MEM_DF | _CRTDBG_LEAK_CHECK_DF);
	//_CrtDumpMemoryLeaks();
}