John Preston
ab35829358
Remove App::app(), App::uploader(), App::api().
...
Also use Auth() instead of AuthSession::Current*().
2017-08-25 14:39:18 +03:00
John Preston
65371ec1b8
Fix selected text render on Retina.
...
QPainter::viewport() can be a too large rect to be passed as a
clipping region to QPainter on Retina displays.
QPainter in case of Retina displays tries to transform QRegion using
scale matrix and fails with "QRegion: creating region from big
polygon failed" warning message and disables painting completely.
2017-07-26 15:51:24 +03:00
John Preston
0402b4f5f4
Add X / V vector icon to checkbox Toggle view.
...
Also use them in the admin rights / restrictions boxes.
2017-07-09 18:06:27 +03:00
John Preston
28f7dc73a5
Optimize markdown parser, use less regex matches.
2017-07-06 19:57:19 +03:00
John Preston
8d43bdb084
Use std::unique_ptrs for ITextBlocks.
2017-07-06 18:59:47 +03:00
John Preston
8550099110
Improve markdown parsing.
2017-07-06 18:59:38 +03:00
John Preston
921c27c9b1
Apply markdown bold/italic when editing a message.
2017-07-06 18:19:50 +03:00
John Preston
148c04fb41
Fix multiline monospace pre blocks editing.
...
Now we pass current flags and lnkIndex to the NewlineBlock, so that
we don't get one multiline pre block split to separate line blocks.
2017-07-06 17:10:33 +03:00
John Preston
eaf91bba58
Parse bold / italic markdown entities.
2017-07-06 16:44:11 +03:00
John Preston
da0d78135d
Some refactoring in working with text entities.
...
Also move this code to TextUtilities namespace.
2017-07-06 14:37:42 +03:00
John Preston
816ee794e8
Event log context menu + improved text selection.
2017-06-30 09:21:43 +03:00
John Preston
624f33c5e2
Allow to select and copy text in the events log.
...
Also better handle window resize in the events log.
2017-06-30 09:21:42 +03:00
John Preston
e39b95175b
Handle channel event log mouse events.
2017-06-30 09:21:42 +03:00
John Preston
4962fdf5ae
Add phrases and layout for all events in log.
2017-06-30 09:21:41 +03:00
John Preston
110e7c8074
Finalize rename / move.
2017-06-29 11:39:38 +03:00
John Preston
297856db32
Load and use Segoe UI [Semibold] if no Open Sans.
...
Sometimes Open Sans Semibold fails to load properly on the latest
Windows Creators Update. In that case try to load Segoe UI instead.
An attempt to fix #3276 .
2017-04-30 19:03:12 +03:00
John Preston
5444b8166c
Finalize rename / move of files.
2017-04-07 18:13:18 +03:00
John Preston
3b373e236e
Make all owned MTPD types immutable.
...
Remove custom refcounting in mtpData, use std::shared_ptr instead.
2017-03-10 23:27:23 +03:00
John Preston
83720d8789
Finalizing file renaming.
2017-03-04 13:23:56 +03:00
John Preston
08167a6a91
Removed #include "stdafx.h" from all files.
...
Currently the build without implicitly included precompiled header
is not supported anyway (because Qt MOC source files do not include
stdafx.h, they include plain headers).
So when we decide to support building without implicitly included
precompiled headers we'll have to fix all the headers anyway.
2017-03-04 12:27:52 +03:00
John Preston
fb230a443e
Fixed text with right bearings display.
...
Sometimes Text::_maxWidth was not accumulated correctly because
the intermediate text blocks had negative right bearing larger
than the whole width of the next text block, so the final computed
line width was less than some intermediate value. Now we accumulate
the _maxWidth value after each block making this value correct.
2017-02-28 19:38:23 +03:00
John Preston
5195b4d3ef
RTL strings with trailing spaces render fix.
...
Commit 8d354382a4
introduced a regression in RTL phrases display.
When an RTL line had trailing spaces we started displaying them in
front of the text still assuming counted line width value that did
not include those trailing spaces.
Line width is not including trailing spaces width because it is
allowed to fit in the line any number of spaces.
Also text block "left padding" entity was eliminated. If we have
some spaces in the start of the text block (for example a text block
after a link) we just add an empty word and mark those spaces as its
right padding.
2017-02-26 21:02:45 +03:00
John Preston
63c61637f8
Moved MTP::authedId() to AuthSession::Current().
2017-02-25 19:48:19 +03:00
John Preston
7fa1986b27
Version 1.0.14: crash fix in text rendering.
...
Fix a regression introduced in 8d354382a4
which caused an overflow
in _parAnalysis access. We were resizing _parAnalysis array for a
line width without the pending newline character while we used it
for painting a line including the pending newline character. It was
not a problem before, when we were trimming them from the end of
the string, but it results in a buffer overflow and crashes in the
lastest versions. So now we just don't include the newline in the
painted string, so it has exactly the same size as _parAnalysis.
2017-02-20 23:58:54 +03:00
John Preston
695733f520
Alpha 1.0.10: fix clang/GCC and old OS X build.
2017-02-17 12:56:42 +03:00
John Preston
8d354382a4
Text selection display fixes.
...
- Use QPainter current pen for selected text in cases we
didn't specify it explicitly in the TextPalette.
- Better rounding of QRectF from QFixed values to QRect selected
background filling areas.
- Using QPainter::viewport() instead of random huge QRect() in
clipping, because it fails to apply this huge QRect() clip region
in Retina paint devices: 2x scale QMatrix::map() is not defined for
QRegion-s having rects with sum of dimensions larger than 100000.
2017-02-16 17:07:16 +03:00
John Preston
9757489645
Moved to the latest emoji set.
...
Also the old MetaEmoji project was converted to codegen_emoji.
All emoji now use full string identifiers for local storage.
2017-02-15 21:27:31 +03:00
John Preston
8e3274cd8f
Colors added in palette for selected messages.
...
User names in groups, text and links in messages and names
in files and shared contacts not can have different colors
in plain inbox / outbox messages and in selected messages.
Now we can use a separate color for selected parts in Text.
2017-02-09 16:46:14 +03:00
John Preston
d1b9b8e3a3
Alpha 1.0.4: Click and drag to reorder pinned chats.
2017-01-30 18:27:13 +03:00
John Preston
47aa03ce37
Logging string in case of crash inside Qt text processing.
...
There are some crash reports from OS X 10.6 and it is the way
to find out which string exactly crashes the app in that place.
2017-01-16 13:18:34 +03:00
John Preston
7fb1463c43
Version 1.0 stable: bump copyright date to 2017.
2017-01-11 23:02:13 +04:00
John Preston
ef927c8465
Theme preview ready.
...
Also style::color is now copyable, constructed only inside a palette.
Also macOS setup new background ready.
2016-12-30 17:53:05 +04:00
John Preston
7fa274a68e
Improved ripple animation colors and styles for different buttons.
...
Also moved FlatLabel and LabelSimple to ui/widgets/labels module.
Also moved ScrollArea to ui/widgets/scroll_area module.
2016-12-30 17:52:10 +04:00
John Preston
2a3fd0066d
Closed beta 10019001: style::color copy is denied, only const refs.
2016-12-30 17:51:33 +04:00
John Preston
e08f5437a6
Palette usage improvements.
2016-12-30 17:51:29 +04:00
John Preston
538ffb9727
Moved History[Media] classes to history_media_types module.
2016-09-28 13:15:03 +03:00
John Preston
5df54371b5
ConfirmPhoneBox support added.
...
Limiting StartUrl to 8k symbols to prevent share url text overflow.
Better working with many cases of regular expression switch.
2016-07-28 20:01:08 +03:00
John Preston
dbdf28d0a0
Version bumped to 0.9.61 stable.
...
Merge branch 'archived_stickers' into cancel_reset.
Conflicts:
Telegram/Resources/winrc/Telegram.rc
Telegram/Resources/winrc/Updater.rc
Telegram/SourceFiles/app.cpp
Telegram/SourceFiles/core/version.h
Telegram/SourceFiles/localstorage.cpp
Telegram/Telegram.vcxproj.filters
Telegram/Telegram.xcodeproj/project.pbxproj
Telegram/build/version
2016-07-25 22:54:40 +03:00
John Preston
cb0c99acc8
Seek done in video player in MediaView. Some memory leaks fixed.
...
Using pixmapFromImageInPlace() instead of QPixmap::fromImage().
2016-07-13 20:34:57 +03:00
John Preston
991c6ddd99
Saving featured stickers for new 0.9.57 version in local storage.
2016-06-27 19:25:21 +03:00
John Preston
963000386f
Fixed crash in BotKeyboard resize. Fixed elided single-line Text layout.
2016-06-17 16:27:21 +03:00
John Preston
0fa6b5bc90
Unread bar in a service message display fixed.
...
Elided text with a skip block in the end display fixed.
2016-06-13 13:42:55 +03:00
John Preston
19cacd0efb
New layout of service messages (complex shape of a bubble).
2016-06-09 14:51:24 +03:00
John Preston
23a598ba3d
Crash in Qt fixed for OS X. Edited badge removed for bot messages.
...
Sticker with reply layout fixed once more.
2016-06-08 21:46:37 +03:00
John Preston
8b2c351933
Phone numbers starting with '0' are not formatted with '+'.
...
Sticker with reply layout fixed. Report box title corrected.
Elided text display sometimes didn't restore last block, fixed.
Removed non-existent class diagram file from MSVC project.
2016-06-08 19:40:33 +03:00
John Preston
520260f207
Merge branch 'profile' into drafts
...
Conflicts:
Telegram/SourceFiles/app.cpp
Telegram/SourceFiles/codegen/style/processor.cpp
Telegram/SourceFiles/history.cpp
Telegram/SourceFiles/historywidget.cpp
Telegram/SourceFiles/mainwidget.cpp
Telegram/SourceFiles/mainwidget.h
Telegram/SourceFiles/profilewidget.cpp
Telegram/SourceFiles/profilewidget.h
Telegram/Telegram.vcxproj
Telegram/Telegram.vcxproj.filters
2016-06-06 18:16:52 +03:00
John Preston
cd2615d8d0
Cloud stored message drafts support added.
2016-06-03 21:24:27 +03:00
John Preston
ab59ef8498
FlatLabel now can allow to select text and copy to clipboard.
...
Used for peer name in the new profile cover widget.
2016-05-26 18:31:20 +03:00
John Preston
cb025b3aa8
Fixed access hash storing in EntityInTextMentionName.
...
Editing message timer is shown for the last five minutes.
2016-05-12 19:55:45 +03:00
John Preston
107a1e7e5d
Merge branch 'master' into mentions
...
Conflicts:
Telegram/SourceFiles/core/version.h
Telegram/SourceFiles/localstorage.cpp
Telegram/build/version
2016-05-10 14:19:01 +03:00
John Preston
9e6243bedf
Version 0.9.48 with bugfixes.
2016-05-10 11:57:55 +03:00
John Preston
3e5f51f45a
Everywhere TextWithTags and TextWithEntities are used.
...
Copy tags from messages to clipboard, to drag mime data.
Sorting entities while processing (links, monospace, mentions).
2016-05-06 20:33:48 +03:00
John Preston
45143c40c9
FlatTextarea handles tags on insertFromMime and tags editing.
...
Fixed dependent messages update when message was edited.
Fixed entities parsing in Text when they follow one after another.
2016-05-04 19:46:24 +03:00
John Preston
5f440a0cbe
Merge branch 'dev' into mentions
...
Conflicts:
Telegram/SourceFiles/core/version.h
Telegram/Telegram.vcxproj.filters
2016-05-04 13:21:04 +03:00
John Preston
dff5765f9f
0.9.47 alpha: fixed crash in text processing (Qt pach updated).
2016-05-02 16:42:09 +03:00
John Preston
21f462a77e
Mention names support added to FlatTextarea, messages.
...
Copy of mention names to clipboard done, pasting started.
2016-04-30 20:04:14 +03:00
John Preston
af248a6714
EntityInText made class instead of struct. Scheme updated.
...
No left trim of monospace text block when sending / displaying text.
New entity type (mention name) introduced, but not supported yet.
2016-04-29 15:00:48 +03:00
John Preston
390a1b0754
Some improvements for winrt.
2016-04-26 16:00:23 +03:00
John Preston
2834ce0344
Moving to Qt 5.6.0, instructions can be broken.
2016-04-23 14:40:42 +03:00
John Preston
705358993d
New style::icon class added, colorized icons by codegen_style.
...
Moved style_core to /ui/style/, Xcode and QtCreator builds are broken.
2016-04-21 20:57:29 +03:00
John Preston
18d8666312
Moved to g++ 4.9, fixed some warnings, codegen used for Linux build.
2016-04-19 16:52:51 +03:00
John Preston
b61c0941ef
Some better source organization. Removed C++11 STL usage (old OS X).
2016-04-15 12:59:02 +03:00
John Preston
bb70a76b9c
Several crashes fixed.
2016-04-14 22:24:42 +03:00
John Preston
d80850a439
Fixed QtCreator build.
2016-04-14 17:30:47 +03:00
John Preston
246e39adb1
Fixed Xcode build, improved project folders (similar to MSVC), warnings fixed.
2016-04-14 16:03:03 +03:00
John Preston
68a9a0a12e
Text copy from HistoryItem/HistoryMedia/combined is done and tested.
...
Moved text module to ui/text/ and split it to several modules.
Xcode build currently broken.
2016-04-14 14:00:23 +03:00