mstn-ebooks-gui/wizard.py

19 lines
767 B
Python
Executable File

#!/usr/bin/env python3
from tkinter import *
from tkinter import ttk
import urllib
#https://github.com/Lynnesbian/mstdn-ebooks/archive/master.zip
# "Welcome", "Select instance", "Create account", "Paste link", "Confirm follows", "Set info", "Install Python", "Install mstdn-ebooks", "Download toots", "Schedule automatic posting", "Enable replies", "Finished"
# CUSTOM CLASSES
class SmartLabel(ttk.Label):
#label that automatically adjusts to wrap to screen length
#pilfered from https://www.reddit.com/r/learnpython/comments/6dndqz/how_would_you_make_text_that_automatically_wraps/di42keo
def __init__(self, master=None, **kwargs):
ttk.Label.__init__(self, master, **kwargs)
self.bind('<Configure>', lambda e: self.config(wraplength=self.winfo_width()))