Age | Commit message (Collapse) | Author |
|
This also changes the minimal height of the emoji dialog
to hold about 8 emoji rows.
Test-Information:
Tested on macOS 10.12.3 with Qt 5.7.1 that the categories
are sorted in a more sensible manner and that the dialog
at least shows about 8 emoji rows.
Change-Id: I8c5518f8d552a581d5073b5f155425580f72938a
|
|
FlowLayout is an official BSD-licensed Qt example showing
how to implement custom layouts. It will layout items
dynamically in rows.
This way we don’t need static column/row calculations for
QGridLayout and it looks better.
Test-Information:
Build and ran on macOS 10.12.3 with Qt 5.7 to test that it has
a better, less spacious look.
Change-Id: Ief1299b0d3fb1e516a1973469f4f9a26824942f2
|
|
The new selector behaves like the old one. However, selection
of an emoji results in the corresponding UTF-8 sequence to be
inserted into the input widget instead of a ASCII emoticon.
The code is based on the Emojione library which is MIT
licensed. Emojione provides a mapping from shortnames to
relevant Unicode codepoint, as well as mappings from textual
emoticons (e.g. ). This commit does not modify the existing
emoticon parser and so does not include any ability to enter
emojis via text entry.
The part of the Emojione library required to generate the mappings
in C++ is included in this patch, specifically the emoji.json
file. It is used to generate a corresponding .cpp file.
Mapping code can be generated as follows:
* cd BuildTools/EmojisGenerator/
* (optional) update emoji.json from
https://github.com/Ranks/emojione/blob/master/emoji.json)
- Version used with this commit: ba845a7
* npm install
* node generate.js
Test-information:
General
* Click the emoji button opens the selector
* Change tab
* Click an emoji and check it appears correctly
* Click outside emoji dialog hides it
Emojis
* Emojis are well printed on macOS with Qt 5.7.1
* Emojis are black/white on Windows 10 with Qt 5.7.1
* Emojis have the right tooltip (when mouse is hover)
* Check emojis are rendered appropriately by the receiving client
Tabs
* Tabs have the right tooltip
* Click an emoji adds to recent tab
* Emojis in the Recent tab are ordered by last click date
(with a maximum of 50 "recent" emojis)
* Recent emojis are saved in the QtSetting under "recentEmojis"
Change-Id: Ibd07b8713d6272da6a8a4c9c35ddf866473f662b
|