2024-05-17 03:44:49 发布
网友
我想用框架python telegram bot创建一个telegram bot!
现在,bot必须用一种特殊的字体发送消息,这意味着bot用不同的漂亮字体发送消息,一种不同于电报字体的字体。
我该怎么办???
没有人(甚至你这个官员)可以用不同的字体/颜色发送消息,你可以向@Telegram提出建议,他们会考虑将此作为功能添加。
消息文本中的formatting options有限,您可能会喜欢它。
唯一可以使用的颜色是红色或将背景颜色设置为灰色。
str = "`Hello`" #this will turn the text red on Telegram. str = "```Hello```" #this will turn the background color gray of the text on Telegram
然后在sendMessage函数中,需要添加参数parse_mode并将其设置为“Markdown”。
没有人(甚至你这个官员)可以用不同的字体/颜色发送消息,你可以向@Telegram提出建议,他们会考虑将此作为功能添加。
消息文本中的formatting options有限,您可能会喜欢它。
唯一可以使用的颜色是红色或将背景颜色设置为灰色。
然后在sendMessage函数中,需要添加参数parse_mode并将其设置为“Markdown”。
相关问题 更多 >
编程相关推荐