-
Notifications
You must be signed in to change notification settings - Fork 0
/
common.h
48 lines (34 loc) · 1.2 KB
/
common.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#pragma once
#include <windows.h>
#include <string>
#include <codecvt>
#include <filesystem>
//#include <fmt/base.h>
//#include <fmt/core.h>
//#include <fmt/format.h>
//#include <fmt/chrono.h>
#include "SDL.h"
extern const wchar_t szProgramName[];
extern bool debug;
extern std::wstring folder_path;
extern std::wstring filename;
extern std::wstring file_path;
extern std::wstring captures_location;
extern bool capture_border;
extern bool capture_cursor;
void message(const LPCWSTR&& text);
void error(const LPCWSTR&& text);
void fatal_error(const LPCWSTR&& text);
std::string get_date_time();
std::wstring replace_wstring_with_pattern(__in const std::wstring& message, __in const std::wstring& pattern, __in const std::wstring& replace);
extern const std::wstring forbidden_chars;
bool is_forbidden(wchar_t c);
std::wstring string_to_wstring(const std::string& str);
void ltrim(std::wstring& s);
void rtrim(std::wstring& s);
void trim(std::wstring& s);
//const std::string currentDateTime();
//const std::wstring get_current_date_time();
//std::wstring get_current_date_time2();
//std::string get_current_date_time3();
void set_file_path(std::wstring extension);