Web Analytics Made Easy - Statcounter
Skip to content


Demo Programs Browser / Any Project Browser



python -m pip install psgdemos
python3 -m pip install psgdemos

See Cookbook for full instructions on using this utility.

NOTE- The installation will not only install the utility, but all of the PySimpleGUI Demo Programs are also included.

GitHub Repo Location

This utility does not have a standalone repo. The Demo Programs and the Demo Browser code are in the main PySimpleGUI repo.

Launching the Demo Browser

From the command line: psgdemos

You can also use the psgshortcut utility to make a double-clickable shortcut icon for Windows that can also be pinned to the Taskbar.

How to Use

The Demo Browser can be used not just to work with the over 300 Demo Programs that accompany PySimpleGUI, but it can be used with any Python project.

There are 3 primary operations that this program provides: * Search a folder tree for a filename * Search a folder tree for strings inside of files * Search a folder tree for strings inside of files using regular expressions * Edit one of more files * Run one or more files * Open folder containing file * Copy full path to a file

The high-level functionality can be thought of as a "recursive file tree" operation where each Python file in a folder tree is searched. If you are searching for a filename, then it's much like using Windows Explorer. If you are searching inside of files, then it's like using "grep".

The result of your search is shown in the file list. You can choose one or more files that can then be: * Edited using editor you specify * Run using interpreter you specify * Copy the path * Open folder using a file explorer

Example Use Case

If you are looking for all Demo Programs that use the Graph Element, then you would enter sg.Graph in the "Find" input. The files that contain this string are shown in the file list above the inputs.

If you've enabled the "Verbose" option, then the right portion of the window contains the strings that matched.

If you want to run one of the programs shown in the file list, select it and then click the "Run" button

Use With Your Projects

While the Demo Browser is written using PySimpleGUI, its use is not limited to PySimpleGUI Demo Programs. You can "point" the top of your directory tree to any location you desire and the tool will search your files, enabling you to edit and run them.