Website Summary Files Commits Branches @commit @diff @stats
path: root / src / ConsoleInterface / Toolbox.cpp
blob: 20f07dbe2afc6209b1dfb01f9ff740b082065f83 (plain) (blame)
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
#include "Toolbox.hpp"

int orderedListIndex = 1;

void resetOrderedList(int starter) {
	orderedListIndex = starter;
}

void _printOrderedListBeginning() {
	std::cout << orderedListIndex++ << ". ";
}

void _printInputBoxLabel(const char* label) {
	std::cout << "+ " << label;
}

void inputLineBox(const char* label, char* output, unsigned maxWidth) {
	_printInputBoxLabel(label);
	std::cin.getline(output, maxWidth);
}

void printTitle(const char* title) {
	std::cout << "## " << title << " ##" << std::endl;
}

void printSuccess(const char* message) {
	std::cout << ") " << message << std::endl;
}

void printError(const char* message) {
	std::cout << "! Err: " << message << std::endl;
}