mirror of
https://github.com/MCV-Software/TWBlue.git
synced 2025-07-20 23:06:07 -04:00
Mastodon: Implemented OCR for images in posts
This commit is contained in:
@@ -30,7 +30,7 @@ class Handler(object):
|
||||
unfav=_("Remove from favorites"),
|
||||
view=_("&Show post"),
|
||||
view_conversation=_("View conversa&tion"),
|
||||
ocr=None,
|
||||
ocr=_("Read text in picture"),
|
||||
delete=_("&Delete"),
|
||||
# In user menu.
|
||||
follow=_("&Actions..."),
|
||||
|
@@ -269,4 +269,12 @@ class viewPost(post):
|
||||
def share(self, *args, **kwargs):
|
||||
if hasattr(self, "item_url"):
|
||||
output.copy(self.item_url)
|
||||
output.speak(_("Link copied to clipboard."))
|
||||
output.speak(_("Link copied to clipboard."))
|
||||
|
||||
class text(messages.basicMessage):
|
||||
def __init__(self, title, text="", *args, **kwargs):
|
||||
self.title = title
|
||||
self.message = postDialogs.viewText(title=title, text=text, *args, **kwargs)
|
||||
self.message.text.SetInsertionPoint(len(self.message.text.GetValue()))
|
||||
widgetUtils.connect_event(self.message.spellcheck, widgetUtils.BUTTON_PRESSED, self.spellcheck)
|
||||
widgetUtils.connect_event(self.message.translateButton, widgetUtils.BUTTON_PRESSED, self.translate)
|
Reference in New Issue
Block a user