-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsb_config.h
More file actions
45 lines (38 loc) · 973 Bytes
/
Copy pathsb_config.h
File metadata and controls
45 lines (38 loc) · 973 Bytes
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
34
35
36
37
38
39
40
41
42
43
44
45
/*
* ShellBar v1.9.0 — A command-bar terminal emulator built on libghostty-vt
* Copyright (c) 2026 Xavier Araque <xavieraraque@gmail.com>
* MIT License
*/
#ifndef SB_CONFIG_H
#define SB_CONFIG_H
#include <gtk/gtk.h>
typedef enum {
SB_ACTION_COPY,
SB_ACTION_PASTE,
SB_ACTION_SELECT_ALL,
SB_ACTION_COUNT
} SbAction;
typedef struct {
char *name;
char *command;
char *icon;
} SbConfigButton;
typedef struct {
SbAction action;
guint keyval;
GdkModifierType mods;
} SbConfigKeybind;
typedef struct {
SbConfigButton *buttons;
int button_count;
SbConfigKeybind *keybinds;
int keybind_count;
char *toolbar_position;
} SbConfig;
SbConfig *sb_config_load(void);
void sb_config_save(SbConfig *config);
void sb_config_free(SbConfig *config);
void sb_config_add_defaults(SbConfig *config);
const SbConfigKeybind *sb_config_find_keybind(SbConfig *config, guint keyval,
GdkModifierType mods);
#endif