mirror of
https://github.com/vicliu624/trail-mate.git
synced 2026-10-22 21:22:14 +00:00
Add optional emoji extension pack
Fixes #33 Adds an installable emoji content/input extension, a generic candidate-picker IME backend, and registry support for small content supplement fonts.
This commit is contained in:
1 parent
fc4a3c6261
commit
b8352bc5e6
21 files changed
+830
-45
No files matched your search
@@ -28,6 +28,7 @@ struct ImeInfo
|
||||
const char* display_name = nullptr;
|
||||
const char* backend = nullptr;
|
||||
const char* layout = nullptr;
|
||||
std::size_t candidate_count = 0;
|
||||
bool builtin = true;
|
||||
};
|
||||
|
||||
@@ -46,6 +47,8 @@ const lv_font_t* locale_preview_font(const char* locale_id, const lv_font_t* asc
|
||||
bool ensure_content_font_for_text(const char* text);
|
||||
std::size_t ime_count();
|
||||
const ImeInfo* ime_at(std::size_t index);
|
||||
std::size_t ime_candidate_count(const char* ime_id);
|
||||
const char* ime_candidate_at(const char* ime_id, std::size_t index);
|
||||
std::size_t enabled_ime_count();
|
||||
bool ime_enabled(const char* ime_id);
|
||||
bool set_ime_enabled(const char* ime_id, bool enabled, bool persist = true);
|
||||
|
||||
@@ -62,6 +62,7 @@ class ImeWidget
|
||||
bool commit_candidate(int candidate_index);
|
||||
bool pinyin_mode() const;
|
||||
bool direct_keyboard_mode() const;
|
||||
bool candidate_picker_mode() const;
|
||||
|
||||
static void on_toggle_clicked(lv_event_t* e);
|
||||
static void on_touch_key_event(lv_event_t* e);
|
||||
@@ -85,6 +86,8 @@ class ImeWidget
|
||||
std::string committed_text_;
|
||||
bool touch_keyboard_enabled_ = false;
|
||||
int candidate_window_start_ = 0;
|
||||
int script_input_index_ = 0;
|
||||
int candidate_picker_index_ = 0;
|
||||
};
|
||||
|
||||
} // namespace widgets
|
||||
|
||||
Reference in new issue
Block a user