[Tablegen] Implement a basic table generator
This commit is contained in:
parent
133c3d1a01
commit
35ce1d8e19
6 changed files with 353 additions and 0 deletions
38
Libraries/Tablegen/Source/Settings.cpp
Normal file
38
Libraries/Tablegen/Source/Settings.cpp
Normal file
|
@ -0,0 +1,38 @@
|
|||
#include "Tablegen/Settings.hpp"
|
||||
|
||||
#include <utility>
|
||||
|
||||
namespace Tablegen
|
||||
{
|
||||
std::string ToString(FontSizeUnits units)
|
||||
{
|
||||
switch (units) {
|
||||
case FontSizeUnits::Px: return "px";
|
||||
case FontSizeUnits::Em: return "em";
|
||||
default: std::unreachable();
|
||||
};
|
||||
}
|
||||
|
||||
Settings Settings::Default()
|
||||
{
|
||||
return {
|
||||
.FullDocument = Flag::Enable,
|
||||
.OverrideIndentLevel = Flag::Disable,
|
||||
.IndentLevel = 0,
|
||||
.TableWidth = 90,
|
||||
.TableMargin = 5,
|
||||
.TableItemWidth = 30,
|
||||
.TableItemPadding = 2,
|
||||
.TableItemColour = RGB::FromHex("#666666"),
|
||||
.LabelFontSize = 1.75,
|
||||
.LabelFontUnits = FontSizeUnits::Em,
|
||||
.ButtonColour = RGB::FromHex("#FF6347"),
|
||||
.ButtonHoverColour = RGB::FromHex("#FFA500"),
|
||||
.ButtonAnimationLength = 0.5,
|
||||
.CharactersPerRow = 3,
|
||||
.ImageFormat = "https://3011.io/Assets/Images/Kanji/Static/{}.png",
|
||||
.AnimationFormat = "https://3011.io/Assets/Temp/{}.svg",
|
||||
.Characters = {},
|
||||
};
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue