add checkbox

This commit is contained in:
Fabien Freling 2023-10-31 14:21:35 +01:00
parent ac2748ea6b
commit 0e0e900048

View file

@ -52,9 +52,9 @@ pub fn main() !void {
raylib.SetTargetFPS(60);
var file_dialog_state = raylib.InitGuiWindowFileDialog(raylib.GetWorkingDirectory());
var active_tab: c_int = 0;
// const ext = ".sqlite3";
// @memcpy(file_dialog_state.filterExt[0..ext.len], ext);
var checked = false;
while (!raylib.WindowShouldClose()) {
//
@ -95,8 +95,8 @@ pub fn main() !void {
.loaded => |*db| {
_ = db;
var tabs = [_][*c]const u8{ "Fabs", "Marvel" };
_ = raylib.GuiTabBar(.{ .x = 20, .y = screen_height - 60, .width = screen_width - 40, .height = 40 }, &tabs, tabs.len, &active_tab);
const label_rect: raylib.Rectangle = .{ .x = 10, .y = 10, .width = 40, .height = 40 };
_ = raylib.GuiCheckBox(label_rect, "Eat well", &checked);
},
}