#pragma once #include #include namespace dchat { struct Range { int start; int end; int length() const { return end - start; } }; struct MessagePart { enum class Type { TEXT, EMOJI }; Type type; Range textRange; }; void compose(const Glib::ustring &text, std::function callbackFunc); }