From e19a29c7e51860144f02d7e7b08ac5e430e1f78f Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 7 Nov 2022 22:21:52 +0100 Subject: Support images in text, add custom emoji to matrix --- include/Text.hpp | 7 ++++--- include/types.hpp | 10 ---------- 2 files changed, 4 insertions(+), 13 deletions(-) delete mode 100644 include/types.hpp (limited to 'include') diff --git a/include/Text.hpp b/include/Text.hpp index 02a6b62..245284f 100644 --- a/include/Text.hpp +++ b/include/Text.hpp @@ -10,8 +10,6 @@ #include #include #include -#include "types.hpp" -#include namespace mgl { class Font; @@ -143,7 +141,7 @@ namespace QuickMedia bool single_line_edit = false; private: - enum class CaretMoveDirection : u8 + enum class CaretMoveDirection : uint8_t { NONE, UP, @@ -172,7 +170,10 @@ namespace QuickMedia float font_get_real_height(mgl::Font *font); float get_text_quad_left_side(const VertexRef &vertex_ref) const; float get_text_quad_right_side(const VertexRef &vertex_ref) const; + float get_text_quad_top_side(const VertexRef &vertex_ref) const; float get_text_quad_bottom_side(const VertexRef &vertex_ref) const; + float get_text_quad_height(const VertexRef &vertex_ref) const; + void move_vertex_lines_by_largest_items(int vertices_linear_end); // If the index is past the end, then the caret offset is the right side of the last character, rather than the left side float get_caret_offset_by_caret_index(int index) const; VertexRef& get_vertex_ref_clamp(int index); diff --git a/include/types.hpp b/include/types.hpp deleted file mode 100644 index dc2a016..0000000 --- a/include/types.hpp +++ /dev/null @@ -1,10 +0,0 @@ -#pragma once - -#include - -typedef uint8_t u8; -typedef uint16_t u16; -typedef uint32_t u32; -typedef uint64_t u64; -typedef intptr_t isize; -typedef uintptr_t usize; \ No newline at end of file -- cgit v1.2.3