telegramdesktop / tdesktop

Telegram Desktop messaging app
https://desktop.telegram.org/
Other
26.23k stars 5.21k forks source link

***** becomes * #3713

Closed rehacktive closed 6 years ago

rehacktive commented 7 years ago
### Steps to reproduce 1. Write on any conversation ***** (5 times "*") 2. Send it 3. You will see just one * ### Expected behaviour Tell us what should happen You should see ***** ### Actual behaviour Tell us what happens instead You see * ### Configuration **Operating system:** OsX **Version of Telegram Desktop:** 1.1.15 **Used theme**: dark
Logs: Insert logs here (if necessary)

AliSawari commented 7 years ago

Yeah that's true. the same goes for _ (underline)

AliSawari commented 7 years ago

and also seven of ` (backtics) will be a single on

AliSawari commented 7 years ago

I guess that's because of the markdown feature :thinking:

sovietspaceship2 commented 7 years ago

yes lol

ghost commented 7 years ago

Yeah, there's no way to escape formatting characters in the official clients as far as I know. In the bot API, single * and _ are used and you can escape them with a backslash (\). You can use @bold in inline mode with the "Custom Markdown" option. Note that inline bots' responses are limited to 512 characters.

There's another caveat: you can't escape triple backticks as far as I can tell. If you need an even amount of triple backticks inside monospace text, you can use @bold with the "Fixedsys" option. But that won't work for an odd amount. Bot API allows HTML which is straightforward, so you could use a HTML formatting bot and escape special formatting characters as HTML entities (I don't know any existing ones off the top of my had).

Lonami commented 6 years ago

This is because Telegram Desktop is using ** (and __) as delimiters when entering bold and italics text as @AliSawari said (markdown feature). So it's not actually a bug, ***** is just ** around **.

stek29 commented 6 years ago

2683

github-actions[bot] commented 3 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.