Major updates/cleanup.
This commit is contained in:
@@ -1,23 +1,31 @@
|
||||
#pragma once
|
||||
|
||||
#include "definitions.h"
|
||||
#include "internal/syntax/miniparser.h"
|
||||
#include "pch.h"
|
||||
|
||||
namespace bed::internal::ui {
|
||||
namespace bed::internal::ui::text_mode {
|
||||
struct TextMode {
|
||||
std::string cmd;
|
||||
uint16_t cursor;
|
||||
struct Row {
|
||||
uint64_t start;
|
||||
uint64_t length;
|
||||
};
|
||||
using Lines = std::vector<Row>;
|
||||
vase::Shard *vase;
|
||||
vase::Point cursor;
|
||||
std::optional<syntax::MiniParser> parser;
|
||||
std::vector<Lines> lines;
|
||||
uint16_t start;
|
||||
uint16_t height;
|
||||
uint16_t term_height;
|
||||
uint16_t term_width;
|
||||
BEd &bed;
|
||||
|
||||
TextMode(BEd &);
|
||||
TextMode(BEd &, vase::Shard *, syntax::Language *, void *);
|
||||
std::pair<vase::Shard *, bool> run();
|
||||
std::pair<vase::Shard *, bool> run_pipe();
|
||||
std::pair<vase::Shard *, bool> run_terminal();
|
||||
void grow();
|
||||
void redraw();
|
||||
void layout_lines();
|
||||
};
|
||||
} // namespace bed::internal::ui
|
||||
} // namespace bed::internal::ui::text_mode
|
||||
|
||||
Reference in New Issue
Block a user