1
Fork 0
This repository has been archived on 2025-04-09. You can view files and clone it, but cannot push or open issues or pull requests.
ctrorganizer/include/utility.h
2024-01-03 15:59:26 -05:00

11 lines
No EOL
310 B
C++

#pragma once
#include <string>
//Taken from http://stackoverflow.com/a/5590404
#define SSTR( x ) static_cast< std::ostringstream & >( \
( std::ostringstream() << std::dec << x ) ).str()
class Utility {
public:
static std::string truncate(std::string str, size_t width, bool show_ellipsis = true);
};