/// @brief Prints a value to a stream, with optional formatting parameters. /// @tparam TFmt If true, applies formatting. /// @tparam TResetFmt If true, resets current formatting before applying new one. template<bool TFmt, bool TResetFmt = true, typename T> inline void printFmt(std::ostream& mStream, const T& mValue, Console::Color mColor = Console::Color::Default, Console::Style mStyle = Console::Style::None) { if(TFmt) { if(TResetFmt) resetFmt(mStream); mStream << Console::setColorFG(mColor) << Console::setStyle(mStyle); } mStream << mValue; }
inline void callStringifyImpl(std::ostream& mStream, const T& mValue) { if(TResetFmt) resetFmt(mStream); stringify<TFmt>(mStream, mValue); if(TResetFmt) resetFmt(mStream); }
template<bool TFmt, bool TResetFmt = true, typename T> inline void callStringifyImpl(std::ostream& mStream, const T& mValue) { if(TResetFmt) resetFmt(mStream); stringify<TFmt>(mStream, mValue); if(TResetFmt) resetFmt(mStream); }