Lot of code for generating code. Working on unit tests.

This commit is contained in:
eelke 2018-09-09 18:52:32 +02:00
parent da45929b12
commit 8f4845d4d2
42 changed files with 1089 additions and 267 deletions

View file

@ -0,0 +1,23 @@
#ifndef INDENTATIONCONFIG_H
#define INDENTATIONCONFIG_H
#include <QString>
class IndentationConfig {
public:
IndentationConfig();
IndentationConfig(int tab_size, int indentation_size, bool use_tabs);
/** Returns a string with the right amount of tabs and spaces for the
* requested indentation level.
*/
QString getIndentString(int level) const;
private:
int m_tabSize = 8; ///< the size of a tab
int m_indentationSize = 4; ///< Number of positions per level to indent
bool m_useTabs = true; ///< Use tabs as much as possible instead of spaces when indenting
};
#endif // INDENTATIONCONFIG_H