Commit graph

69 commits

Author SHA1 Message Date
John Preston
187110f438 Allow unloading custom emoji data. 2022-06-24 20:33:46 +04:00
John Preston
14a7fc74af Correctly finish custom emoji entities. 2022-06-24 10:48:46 +04:00
John Preston
87cd0b6127 Add initial support for custom emoji. 2022-06-23 17:51:36 +04:00
Ilya Fedin
060eb63ce8 Get rid of qtextitemint.cpp
All the variables are public, so there's no need to use non-exported constructor
2022-05-29 10:16:10 +04:00
Sergey A. Osokin
49b4b35efa Fix -Wunused-const-variable warnings by removing unused variables 2022-04-26 08:15:13 +04:00
John Preston
5214f96bba Parse markup in Ui::Text::String::setMarkedText by default. 2022-02-27 17:48:43 +03:00
23rd
88966598b8 Removed limitations on number of indexes. 2022-02-25 12:56:10 +03:00
23rd
7e1effeeeb Added support for custom indexes of links in Ui::String::Text. 2022-02-05 18:40:23 +03:00
John Preston
6af9023eb7 Fix build with GCC. 2022-02-01 01:51:06 +03:00
23rd
5acbd74670 Fixed drawing spoiler when it ends with formatted text and space. 2022-01-24 23:30:39 +03:00
23rd
7bd7ada3ff Split qt_adapters to separated files. 2022-01-24 19:29:36 +03:00
John Preston
64fa3d83b5 Workaround selection glitches on macOS. 2022-01-18 14:11:08 +03:00
23rd
45893ec223 Excluded EntityType::Pre from clickable types. 2022-01-17 16:48:48 +03:00
23rd
19de16ba6f Fixed processing of started entities for monospace. 2022-01-17 10:10:14 +03:00
23rd
d1509436b6 Fixed possible crash in Text::String with clickable monospace. 2022-01-16 10:19:09 +03:00
23rd
2b87a251cd Fixed enumerating of Text::String with clickable monospace. 2022-01-16 10:18:23 +03:00
John Preston
4fbd226067 Fix selection of monospace text on press. 2022-01-13 13:11:16 +03:00
23rd
5e8b8d4129 Changed behavior to process paragraph selection as full for monospace. 2022-01-13 13:05:20 +03:00
23rd
c2fcbdc883 Limited monospace text selection on click only for single lines. 2022-01-13 13:05:04 +03:00
23rd
087c82e1d5 Fixed display of ellipsis under spoiler. 2022-01-08 09:12:24 +03:00
23rd
20b908ea70 Slightly optimized spoilers to avoid recreating of same click handlers. 2022-01-08 08:24:06 +03:00
23rd
b1f71ccab3 Added selection of monospace text on press. 2022-01-08 08:24:06 +03:00
23rd
4e4e54dcc5 Made monospace text clickable. 2022-01-08 08:24:06 +03:00
23rd
b81b9371e6 Removed TextParseRichText. 2022-01-08 08:24:06 +03:00
23rd
7e279bd83a Removed text commands. 2022-01-08 08:24:06 +03:00
23rd
745ce34dd5 Added new entity type for plain non-interactive links.
Increased size of the block flags by two bits.
Added a text utility to wrap a simple text with plain links.
Added a new flag to specify parsing of plain links.
2022-01-08 08:24:06 +03:00
John Preston
9da4e1e731 Fix spoiler rounding. 2021-12-30 15:58:27 +03:00
John Preston
541c8d258b Display shown spoilers as plain text. 2021-12-30 15:58:27 +03:00
John Preston
5f94fa24a0 Some fixes in spoiler geometry. 2021-12-30 15:58:27 +03:00
23rd
8b0ff16b66 Fixed isolated emoji under spoilers. 2021-12-30 03:24:11 +03:00
23rd
e961883914 Fixed spoiler width for thin characters. 2021-12-30 03:23:39 +03:00
23rd
3461c18cda Extracted ellipsis string from String::Text to global access. 2021-12-25 18:24:09 +03:00
23rd
44853e9334 Added ability to show or hide spoilers from outside. 2021-12-25 17:31:53 +03:00
23rd
db871a87f5 Added animation for spoilers. 2021-12-24 15:49:02 +03:00
23rd
2c1e6b458d Moved SpoilerClickHandler to separated file. 2021-12-24 15:49:02 +03:00
23rd
af2cfca307 Improved style of selected text with spoilers. 2021-12-24 15:49:02 +03:00
23rd
6c9d832ad8 Added nice corners for spoilers. 2021-12-24 15:49:02 +03:00
23rd
bcf16c6c80 Added spoiler support to conversion from Ui::Text::String to text. 2021-12-24 15:49:02 +03:00
23rd
6b905f7754 Added text command for spoilers. 2021-12-24 15:49:02 +03:00
23rd
1819e6e3a5 Added initial spoiler support to Ui::Text::String. 2021-12-24 15:49:02 +03:00
23rd
e19a4c6544 Added index for spoiler to AbstractBox. 2021-12-22 22:39:03 +03:00
Ilya Fedin
ee36b1f451 Use StringViewMid adapter 2021-10-20 10:27:52 +04:00
Ilya Fedin
8e5d35229a Simple replacements for Qt 6
QStringRef -> QStringView
QTextCursor constructor accepts a QTextDocument only
Some headers are moved, so paths are removed
QMatrix -> QTransform
Methods returning qsizetype are wrapped to int()s to allow compiler to deduce the type
2021-10-19 17:06:25 +04:00
John Preston
d81997194e Allow forcing links to be always underlined. 2021-09-19 12:41:44 +03:00
Ilya Fedin
a2d1114a93 Get rid of osx and linux32 special targets 2021-08-11 16:01:30 +03:00
Ilya Fedin
51cfd0ba35 Fix -Wunused-variable warnings with gcc 2021-07-19 18:59:36 +03:00
Ilya Fedin
b8485c0d8a Fix -Wunused-variable warnings 2021-07-13 21:24:22 +03:00
John Preston
f239f66ce5 Fix build with Xcode. 2021-06-22 20:31:57 +04:00
John Preston
0028a534d2 Fix parsing links with markup to entities. 2021-06-22 19:04:29 +04:00
John Preston
9c9a4bc4d8 Custom non-internal links should go to entities. 2020-10-30 18:13:50 +03:00