/*
QtWagon: a project about 3D objects.
Science and technology promotion license applied. Third party license automatically cascaded.
Zhikai Wang/ www.heteroclinic.net 2013
You can do anything with this file or any file(s) published as part QtWagon project, given this header is kept.
*/
#ifndef __TO_STRING
#define __TO_STRING
#include <sstream>
#include <iostream>
#include <sstream>
#include <iomanip>
int getWidth (int d);
const std::string getFormatedIntegerString (int d, int a,char c= '0');

template <class T>
inline std::string to_string (const T& t)
{
	std::stringstream ss;
	ss << t;
	return ss.str();
}

const std::string formatDouble (double d, int precision_len=3 ) ;
#endif