Configurable default window size ; default is "intelligent".

This commit is contained in:
KikooDX 2021-02-27 16:56:22 +01:00
parent f412956c83
commit bd9cbf44a3
3 changed files with 7 additions and 1 deletions

1
.gitignore vendored
View File

@ -1,2 +1,3 @@
zig-cache/
sample_*.kble
backup_*.kble

View File

@ -37,6 +37,11 @@ pub const default_grid_size = .{
pub const default_scaling_level = 32;
pub const default_window_size = .{
.width = default_grid_size.width * default_scaling_level,
.height = default_grid_size.width * default_scaling_level,
};
pub const theme = .{
.background = ray.BLACK,
.mode = .{

View File

@ -41,7 +41,7 @@ pub fn main() void {
// Create window.
ray.SetConfigFlags(ray.FLAG_WINDOW_RESIZABLE);
ray.InitWindow(640, 480, "KBLE");
ray.InitWindow(conf.default_window_size.width, conf.default_window_size.height, "KBLE");
defer ray.CloseWindow();
// Limit FPS for performance.