Last active
April 26, 2021 10:56
-
-
Save Stilic/175dd31c2be385cb4f53ba4cea2571ea to your computer and use it in GitHub Desktop.
"Pro type" RSS reader
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Rich Reader | |
=========== | |
"Pro type" RSS reader GUI writtent in Python 3 with Feedparser and GUIzero. | |
Install for first launch | |
------------------------ | |
For launch it, just type in a terminal `pip3 install --upgrade feedparser guizero || python3 RichReader.py`. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from guizero import * | |
import feedparser | |
app = App(title="Rich Reader") | |
url = TextBox(app, width=23) | |
def list_view(v): | |
try: | |
txt.value = feed["feed"][v] | |
except KeyError: | |
txt.value = "<Nothing here>" | |
def conn(): | |
global feed, list | |
list.destroy() | |
feed = feedparser.parse(url.value) | |
list = ListBox(app, items=feed.entries[1], scrollbar=True, command=list_view) | |
connect = PushButton(app, text="Connect", command=conn) | |
txt = TextBox(app, multiline=True, scrollbar=True, width=30, height=5, enabled=False) | |
list = ListBox(app) | |
app.display() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment