src/system/helpers.cpp: Add cutString() function

This commit is contained in:
M. Liebmann
2016-08-12 19:19:24 +02:00
parent c317e4dbb4
commit 71674d0f8a
2 changed files with 24 additions and 0 deletions

View File

@@ -37,6 +37,8 @@
#include <sys/stat.h>
#include <sys/types.h>
#include <driver/fontrenderer.h>
int my_system(const char * cmd);
int my_system(int argc, const char *arg, ...); /* argc is number of arguments including command */
@@ -67,6 +69,7 @@ std::string getFileName(std::string &file);
std::string getFileExt(std::string &file);
std::string getNowTimeStr(const char* format);
std::string trim(std::string &str, const std::string &trimChars = " \n\r\t");
std::string cutString(const std::string str, Font *msgFont, const int width);
std::string strftime(const char *format, const struct tm *tm);
std::string strftime(const char *format, time_t when, bool gm = false);
time_t toEpoch(std::string &date);