Description
A fast and easy way to add sharable web interfaces to Python programs.
'Sharable' means that you can use your program on your smartphone without having to reconfigure it (to connect it to the local network), or the router to which the computer running the program is connected (to open a port to your computer). And by sending the URL of the program to someone, they can immediately use it on their own smartphone or other device with a modern web browser connected to internet.
Only basic knowledge of HTML needed.
Python version of the Atlas toolkit alternatives and similar packages
Based on the "GUI" category.
Alternatively, view Python version of the Atlas toolkit alternatives based on common mentions on social networks and blogs.
-
kivy
Open source UI framework written in Python, running on Windows, Linux, macOS, Android and iOS -
PySimpleGUI
Launched in 2018. It's 2023 and PySimpleGUI is actively developed & supported. Create complex windows simply. Supports tkinter, Qt, WxPython, Remi (in browser). Create GUI applications trivially with a full set of widgets. Multi-Window applications are also simple. 3.4 to 3.11 supported. 325+ Demo programs & Cookbook for rapid start. Extensive docs -
DearPyGui
Dear PyGui: A fast and powerful Graphical User Interface Toolkit for Python with minimal dependencies -
Flet
Flet enables developers to easily build realtime web, mobile and desktop apps in Python. No frontend experience required. -
Eel
A little Python library for making simple Electron-like HTML/JS GUI apps [Moved to: https://github.com/ChrisKnott/Eel] -
pywebview
Build GUI for your Python program with JavaScript, HTML, and CSS -
Flexx
Write desktop and web apps in pure Python -
urwid
Console user interface library for Python (official repo) -
enaml
Declarative User Interfaces for Python -
wxPython
A blending of the wxWidgets C++ class library with the Python. -
PyGObject
Tutorial for using GTK+ 3 in Python -
PySide
ATTENTION: This project is deprecated, please refer to PySide2 -
Python bindings for Sciter
Python bindings for Sciter -
Qt Style Sheet Inspector
A inspector to be able to view and edit Qt style sheet while an application is running -
signalum-desktop
A Desktop application for the signalum python library -
pyglet
A cross-platform windowing and multimedia library for Python. -
curses
Built-in wrapper for ncurses used to create terminal GUI applications. -
Tkinter
Tkinter is Python's de-facto standard GUI package. -
PyQt
Python bindings for the Qt cross-platform application and UI framework, with support for both Qt v4 and Qt v5 frameworks.
Access the most powerful time series database as a service
* Code Quality Rankings and insights are calculated and provided by Lumnify.
They vary from L1 to L5 with "L5" being the highest.
Do you think we are missing an alternative of Python version of the Atlas toolkit or a related project?
README
Python version of the Atlas toolkit
<!-- Si la table ci-dessous est modifiée, alors modifier également (pages du site atlastk.org) :
- la page '_index' ;
- la page 'Online demonstrations' ; -->
The Atlas toolkit is available for: | Language / Demo | Repositories | Popularity | |:-:|:-:|:-:| |
|
![]()
|
| |
|
![]()
|
| |
|
![]()
|
| |
|
![]()
|
| |
|
![]()
|
|
WebGPIO (Raspberry Pi/ODROID-C2): the WebGPIO application, with which you can control the Raspberry Pi/ODROID-C2 (and probably other similar devices) GPIOs with your smartphone, is described in the Raspberry Pi/ODROID-C2 below section.
A GUI with Python in a couple of minutes
Click the animation to see a screencast of programming this "Hello, World!" program with Python in a matter of minutes:
Same video on Peertube: https://q37.info/s/qfcng9j4.
Source code:
import atlastk
BODY = """
<fieldset>
<input id="Input" xdh:onevent="Submit" value="World"/>
<button xdh:onevent="Submit">Hello</button>
<hr/>
<fieldset>
<output id="Output">Greetings displayed here!</output>
</fieldset>
</fieldset>
"""
def acConnect(dom):
dom.inner("", BODY)
dom.focus("Input")
def acSubmit(dom):
name = dom.getValue("Input")
dom.begin("Output", f"<div>Hello, {name}!</div>")
dom.setValue("Input", "")
dom.focus("Input")
CALLBACKS = {
"": acConnect,
"Submit": acSubmit
}
atlastk.launch(CALLBACKS)
See for yourself right now - it's quick and easy!
Online, with nothing to install
To run above "Hello, World!" program directly in your browser, as seen in corresponding video, follow this link: https://replit.com/@AtlasTK/hello-python.
Thanks to Replit, an online IDE, you can write and run programs using the Atlas toolkit directly in your web browser, without having to install Python on your computer .
To see more examples, like the following TodoMVC, simply:
- go here (also accessible with the
button at the top of this page),
- click on the green
Run
button, - choose the Python entry (this clones the corresponding GitHub repository),
- choose the demonstration to launch,
- wait for the application to open,
- … and, as you wish, fork the Replit repository and run your own tests directly in your browser, by modifying the code of the examples or by writing your own code.
With Python on your computer
# You can replace 'github.com' with 'framagit.org' or 'gitlab.com'.
# DON'T copy/paste this and above line!
git clone http://github.com/epeios-q37/atlas-python
cd atlas-python/examples
python Hello/
Android devices
Programs made with the Atlas toolkit work perfectly on your Android devices (smartphone or tablet) using the Termux application. Simply install (pkg intall …
) the git and python packages. That's all!
Jupyter notebooks
When using the Atlas toolkit in a Jupyter notebook, the GUI is embedded in the notebook, as shown here:
Jupyter notebook examples can be found in the tutorials directory.
Your turn
If you want to take your code to the next level, from CLI to GUI, then you found the right toolkit.
With the Atlas toolkit, you transform your programs in modern web applications (SPA) without the usual hassles:
- no JavaScript to write; only HTML(/CSS) and Python,
- no front and back end architecture to bother with,
- no web server (Apache, Nginx…) to install,
- no need to deploy your application on a remote server,
- no incoming port to open on your internet box or routeur.
The Atlas toolkit is written in pure Python, with no native code and no dependencies, allowing the Atlas toolkit to be used on all environments where Python is available.
And simply by running them on a local computer connected to internet, applications using the Atlas toolkit will be accessible from the entire internet on laptops, smartphones, tablets…
The Atlas toolkit is particularly well suited for educational purposes, to write modern programming exercises, i.e. with a true graphical interface instead of the usual outdated textual one. More about this can be found here.
Python is much more powerful then Excel macros to automate (boring) tasks, and you can also work with PDF, Word, Google files…. And with the Atlas toolkit, you have much more possibilities then with VBA forms. There are some examples here.
There is also a stub to for this library at address https://q37.info/s/zzcn3wnx.
You will also find programs from The Big Book of Small Python Projects by Al Sweigart to which a graphical user interface using the Atlas toolkit were added in this repository: epeios-q37/AlSweigartTheBigBookPython.
Content of the repository
The atlastk
directory contains the Python source code of the Atlas toolkit, which is the directory you have to reference in PYTHONPATH
in order to use the Atlas toolkit in your own program, unless you have installed the atlastk package (pip install atlastk
…).
You can also retrieve the atlastk.zip
file, and add to your source code :
__import__("sys").path.append("<path to>/atlastk.zip")
import atlastk
If the atlastk.zip
file is in the current folder, replace <path-to>/atlastk.zip
with ./atlastk.zip
and not only atlastk.zip
.
In the examples
directory, you will found following examples:
Blank
: very basic example,Hello
: "Hello, World!",Chatroom
: multi-user chatroom,Notes
: note taking program,TodoMVC
: TodoMVC,Hangman
: Hangman game,15-puzzle
: 15-puzzle game,Contacts
: a basic address book,Widgets
: some widgets handled with the Atlas toolkit,Chatrooms
: same as aboveChatroom
, but with several rooms,PigGame
: Pig game for one or two players,Reversi
: Reversi game for one or two players,MatPlotLib
: the Atlas toolkit displaying some graphics made with matplotlib; this example needs, of course, the matplotlib package to be installed…
Other examples are detailed in the next section.
Except for the ErgoJr, GPIO and RGB applications, which are detailed in the next section, to run an example, launch, from within the examples
directory, python <Name>/
(don't forget the final /
), where <Name>
is the name of the example (Blank
, Chatroom
…).
The Stars application is an example where the Atlas toolkit is used to control a Pygame based application. Of course, Pygame needs to be installed.
The tutorials
directory contains some Jupyter notebooks about the Atlas toolkit.
Raspberry Pi/ODROID-C2
If the applications does not work on your Raspberry Pi, please see this issue: https://github.com/epeios-q37/atlas-python/issues/1
The GPIO and RGB applications are designed to be used on a Raspberry Pi or a ODROID-C2.
Here is how the WebGPIO application looks like:
For the Raspberry Pi, the RPi.GPIO
Python module have to be installed (this is probably already the case).
For the ODROID-C2, The Python version of WiringPi must be installed, and the application has to be launched, from within the examples
directory, with sudo
(sudo python GPIO/
or sudo python RGB/
).
The ErgoJr application is experimental and to control a Poppy Ergo Jr robot.
The RGB application is dedicated to the control of a RGB led, and the GPIO (aka WebGPIO) application allows to control the basic pins. Click below picture to see a YouTube video on how they work (same video on PeerTube: https://q37.info/s/49pbmwv9):
*Note that all licence references and agreements mentioned in the Python version of the Atlas toolkit README section above
are relevant to that project's source code only.