summaryrefslogtreecommitdiff
path: root/emojis.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'emojis.hpp')
-rw-r--r--emojis.hpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/emojis.hpp b/emojis.hpp
index cbcb2ca..61b8a71 100644
--- a/emojis.hpp
+++ b/emojis.hpp
@@ -12,15 +12,13 @@ public:
EmojiResource(std::string filepath);
bool Load();
Glib::RefPtr<Gdk::Pixbuf> GetPixBuf(const Glib::ustring &pattern);
- static Glib::ustring PatternToHex(const Glib::ustring &pattern);
- static Glib::ustring HexToPattern(Glib::ustring hex);
const std::vector<Glib::ustring> &GetPatterns() const;
const std::map<std::string, std::string> &GetShortCodes() const;
void ReplaceEmojis(Glib::RefPtr<Gtk::TextBuffer> buf, int size = 24);
std::string GetShortCodeForPattern(const Glib::ustring &pattern);
private:
- std::unordered_map<std::string, std::string> m_pattern_shortcode_index;
+ std::unordered_map<std::string, std::vector<std::string>> m_pattern_shortcode_index;
std::map<std::string, std::string> m_shortcode_index; // shortcode -> pattern
std::unordered_map<std::string, std::pair<int, int>> m_index; // pattern -> [pos, len]
FILE *m_fp = nullptr;