-
-
Notifications
You must be signed in to change notification settings - Fork 699
Tools and Widgets
The following small apps and widgets have been made with Dear PyGui. As these examples can be instructional for other developers, they are shared here. Click the images to visit the GitHub repositories.
The EditThemePlugin for Dear PyGui allows you to change theme settings, e.g. the font color or spacing of elements, and save them to a theme file that can be used in other Dear PyGui applications.
In addition to the file explorer built into Dear PyGui, there are two file explorer libraries that offer extra functionality, e.g. file_dialog
and Dear PyGui Extend: File browser
. Dear PyGui's file explorer is the same as imgui's file explorer and cannot be customized in any way. The two file explorers listed here are written in Python and Dear PyGui and can be customized in Python if required. Alternative file browsers (not created with Dear PyGui) are xdialog or windows_filedialogs (Windows only).
File_dialog is a beautiful file dialog add-on for DearPyGui applications, released under an MIT license.
Features
- Nice and beautiful interface
- Modern icons
- Shortcut menu
- Drives menu
- Customization of the the file dialog window
- Can be used at all time by using show_file_dialog()
Dear PyGui Extend offers a custom file browser with extended functionality compared to the built-in file browser. It is released under an MIT license.
Features
- Supports file sequence entries: image.001.jpg, image.002.jpg, image.003.jpg --> 'image.###.jpg (001-003)'
- Multi-selection (pick single or multiple files/sequences)
- Breadcrumb path with navigation icons & folder quick access
- Filetype filters
- Sorting (smart sorting for collapsed sequences)
- Draggable items (ability to expand file sequences on a drop callback)
DearPyGui-Markdown is a markdown implementation that supports nearly all basic markdown functionality in Dear PyGui, as well as provides additional support in the form of text customization (color, size) as a custom HTML tag.
This tools extends Dear PyGui's text layout by allowing a different color and/or font type and size for each word while wrapping and aligning the text appropriately.
A date picker with extended functionality compared to the date picker that is built into Dear PyGui.
Benefits
- Works with datetime, not dictionaries.
- You can set both minimum and maximum value limits.
- Supports translations
- Can be customized for your needs (for example, you can add tooltips on items).
Drawbacks
- Wrong width and no calendar visible in the first frame
- No support for dpg.get_value/dpg.set_value, you have to work directly with the class object (DatePicker().set_value/DatePicker().get_value)
- Python >= 3.11 (to support python < 3.11, remove Self/typing.Self)
DearPyGui-Grid is a layout management tool for Dear PyGui. Grid
does not create or use items for layout aids. Instead, it emulates a table-like structure and works by leveraging common configuration options supported by most items.
Features
- create simple to complex layouts without the messy web of group, table, theme, and spacer items
- position widgets in individual cells or over a cell range
- supports overlapping widgets
- edge-level padding customization per-slot (row/column) or per widget
- control spacing between rows and columns
- static and dynamic sizing (policy emulation)
- optional overlay outlining the grid and its' slots - useful for debugging or designing layouts
The Dear PyGui Map Widget allows for an interactive map based on OpenStreetMap data. The user can pan in all directions and zoom in and out of areas. The widget caches all map tiles that have been loaded and shown.
DPG Swiss controls is a small library made with Dear PyGui with a dependency on Numpy and Pandas. It contains a number of tools, including displaying DataFrames and managing items on a grid. An example of the latter is shown below.
Automatically scrolling logger window that meets the following requirements.
- Regularly update
- Scrollable
- Ability to automatically scroll to newest entry
- Ability to show and hide the log with a toggle button
- Text should be selectable
- Automatic scrolling can be turned on and off
A simple, responsive, text-based layouting system that abstracts table creation process away from the user.
Add Drag'n'drop ability to groups ("swap" or "replace" behaviors).
Cresliant is a powerful node-based image editor made in Python. It offers an easy way to manipulate and enhance images through a user-friendly interface. With Cresliant, users can take advantage of a wide range of features and functionalities, all powered by Python's extensive libraries for image processing.
Loading textures takes up a considerable amount of GPU memory. This textures example app optimizes RAM consumption by loading images into memory when necessary and unloading images when the image is no longer visible.
An example implementation of a progress bar for Dear PyGui. The user can can pause, resume or reset the progress bar. It uses threading to asynchronously run the progress bar, so that it doesn't interfere with the rest of the application or GUI.
DimensionMe is an application for sending multiple images to a neural network site and retrieving and showing the resulting, processed images. The application combines networking with loading images from the web API as textures, GUI and threading.
Image to PDF converter with drag-and-drop functionality (Windows only) for adding image files and converting to a PDF document. It also shows an image while hovering over a file name or miniature preview image. In addition, the application supports a theming system where the user can select one of the predefined themes.
MQTT chat, made with Dear PyGui, that supports the following glyphs (characters).
- Latin extended
- Cyrillic
- Japanese
- Chinese (traditional and simplified)
- Vietnamese
- Thai
- Korean
Slippi labeler automatically fetches a list of players from a Start.gg url. During a tournament, use the Slippi Labeler to group games into sets. Label the players on each port. Then at the end, export the labels for record keeping.
PyFaceRenderer uses an off-screen renderer for rendering face models and displays the result using Dear PyGui.
Vaultea is simple and easy to use file encryption app. It supports batch file processing and folder encryption while ensuring data authenticity.
A simple calculator demonstrating how to create buttons and use callbacks.
RSTP video stream viewer, e.g. for viewer for security cameras, is a small utility that shows four video streams concurrently. It provides an example of how to use threading combined with video playback.
Working Drag-and-drop widget for Dear PyGui for dragging files from File Explorer or even the Desktop. It's Windows only as it uses pywin32 for Windows API calls.
Example of dragging and dropping nodes onto the Node Editor in Dear PyGui.
In case you'd like to see more examples, you can check out the Showcase gallery, that highlights a variety of interesting apps made with Dear PyGui.
You can also have a look at the Showcase apps for older Dear PyGui versions. These apps were made with older versions of Dear PyGui. The release of Dear PyGui version 1.0 included a few breaking changes, so that these apps are not compatible with the latest version.