Hey I had an idea to implement twitter like formatting for captions which I've made work locally as an addition to the caption function. And features:
tweet like captioning using the text widget instead of labels
turns a standard image file into a circle box so the image is 'like twitter'
Colour emoji support for captions using Pillow Image.draw
Essentially you can rip a whole lot of tweets from twitter -> clean them -> and then plug into your captions JSON.
I'm sharing because I thought it was a decent idea -> and I couldn't see a way to make a branch of the repo. If it's worth taking forwards I think some of this code belongs in other modules and should accept parameterization for the 'tweeter'.
` def try_caption(self) -> None:
if self.settings.captions_in_popups and self.pack.has_captions(self.settings, self.media) and self.width > 400:
import random import time from threading import Thread from tkinter import Button, Label, TclError, Tk, Toplevel, font as tkFont import tkinter as tk from PIL import ImageTk, Image, ImageDraw, ImageFont from features.misc import open_web from features.theme import get_theme from pack import Pack from panic import panic from roll import roll from screeninfo import get_monitors from settings import Settings from state import State from utils import utils from datetime import date import numpy as np import textwrap
Hey I had an idea to implement twitter like formatting for captions which I've made work locally as an addition to the caption function. And features:
Essentially you can rip a whole lot of tweets from twitter -> clean them -> and then plug into your captions JSON.
I'm sharing because I thought it was a decent idea -> and I couldn't see a way to make a branch of the repo. If it's worth taking forwards I think some of this code belongs in other modules and should accept parameterization for the 'tweeter'.
` def try_caption(self) -> None: if self.settings.captions_in_popups and self.pack.has_captions(self.settings, self.media) and self.width > 400:
extensions used
import random import time from threading import Thread from tkinter import Button, Label, TclError, Tk, Toplevel, font as tkFont import tkinter as tk from PIL import ImageTk, Image, ImageDraw, ImageFont from features.misc import open_web from features.theme import get_theme from pack import Pack from panic import panic from roll import roll from screeninfo import get_monitors from settings import Settings from state import State from utils import utils from datetime import date import numpy as np import textwrap