Files
Nomi/source/editor.c

68 lines
1.1 KiB
C
Raw Normal View History

2025-10-30 18:08:11 -07:00
#ifndef EDITOR_H
#define EDITOR_H
#include <tart.h>
2025-10-31 16:53:27 -07:00
#include "editor.h"
2025-10-30 18:08:11 -07:00
struct tart_window window;
struct commandMode {
struct tart_cstring prompt_cstr;
struct tart_cstring input_cstr;
char inputBuffer[255];
int inputBufferIdx;
char* input;
};
2025-10-31 16:53:27 -07:00
struct bottomBar {
struct tart_cstring mode_cstr;
struct tart_cstring file_cstr;
struct tart_cstring branch_cstr;
struct tart_cell bottomBar_cell;
};
2025-10-30 18:08:11 -07:00
struct InsertMode {
};
void Create_commandMode();
void CreateWindow() {
}
void InitCommandMode() {
}
void InitInsertMode();
void InitNormalMode();
void InitNomiMode();
2025-10-31 16:53:27 -07:00
void CommandMode(struct commandMode cmdm) {
2025-10-30 18:08:11 -07:00
tart_draw_cstring_position(tart_get_buffer(&window, 0),
2025-10-31 16:53:27 -07:00
cmdm.input_cstr,
2025-10-30 18:08:11 -07:00
(struct tart_vec2){16,10});
tart_draw_cstring_position(tart_get_buffer(&window, 0),
2025-10-31 16:53:27 -07:00
cmdm.prompt_cstr,
2025-10-30 18:08:11 -07:00
(struct tart_vec2){0,10});
}
void InsertMode();
void NormalMode();
void NomiMode();
void Update();
void UpdateBigin();
void UpdateEnd();
void OnQuit();
void OnStart();
void Draw();
#endif /* ifndef EDITOR_H */