From f7aca803b1f566fb03c52bab4427c36f50faa7ec Mon Sep 17 00:00:00 2001 From: Dan <14043624+delivrance@users.noreply.github.com> Date: Fri, 11 May 2018 16:03:25 +0200 Subject: [PATCH] Hint about text.markdown in docstrings --- pyrogram/client/types/message.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/pyrogram/client/types/message.py b/pyrogram/client/types/message.py index d22def65..81dbf1e0 100644 --- a/pyrogram/client/types/message.py +++ b/pyrogram/client/types/message.py @@ -71,6 +71,9 @@ class Message(Object): text (``str``, *optional*): For text messages, the actual UTF-8 text of the message, 0-4096 characters. + If the message contains entities (bold, italic, ...) you can access *text.markdown* or + *text.html* to get the marked up message text. In case there is no entity, the fields + will contain the same text as *text*. entities (List of :obj:`MessageEntity `, *optional*): For text messages, special entities like usernames, URLs, bot commands, etc. that appear in the text. @@ -108,6 +111,9 @@ class Message(Object): caption (``str``, *optional*): Caption for the audio, document, photo, video or voice, 0-200 characters. + If the message contains caption entities (bold, italic, ...) you can access *caption.markdown* or + *caption.html* to get the marked up caption text. In case there is no caption entity, the fields + will contain the same text as *caption*. contact (:obj:`Contact `, *optional*): Message is a shared contact, information about the contact.