コード例 #1
0
ファイル: print.c プロジェクト: EyMenZ/NetSurf-OS3
/**
 * This function calls print setup, prints page after page until the whole
 * content is printed calls cleaning up afterwise.
 *
 * \param content The content to be printed
 * \param printer The printer interface for the printer to be used
 * \param settings The settings for printing to use
 * \return true if successful, false otherwise
 */
bool print_basic_run(hlcache_handle *content,
		const struct printer *printer,
		struct print_settings *settings)
{
	bool ret = true;

	assert(content != NULL && printer != NULL && settings != NULL);
	
	if (print_set_up(content, printer, settings, NULL))
		return false;

	while (ret && (done_height < content_get_height(printed_content)) ) {
		ret = print_draw_next_page(printer, settings);
	}

	print_cleanup(content, printer, settings);
	
	return ret;
}
コード例 #2
0
ファイル: print.c プロジェクト: arczi84/NetSurf-68k
bool ami_print_cont(void)
{
	bool ret = false;

	if(ami_print_info.page <= ami_print_info.pages)
	{
		glob = ami_print_info.gg;
		print_draw_next_page(&amiprinter, ami_print_info.ps);
		ami_print_dump();
		ami_gui_set_default_gg();
		ret = true;
	}
	else 
	{
		print_cleanup(ami_print_info.c, &amiprinter, ami_print_info.ps);
		ret = false;
	}

	return ret;
}