Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/yjg30737/pyqt-file-list-widget
PyQt QListWidget for files (Being able to drop the files based on user-defined extensions)
https://github.com/yjg30737/pyqt-file-list-widget
py37 pyqt pyqt-examples pyqt-file-list-widget pyqt-qlistwidget pyqt-tutorial pyqt5 pyqt5-examples pyqt5-file-list-widget pyqt5-gui pyqt5-qlistwidget pyqt5-tutorial python python3 python37 qlistwidget qt
Last synced: about 1 month ago
JSON representation
PyQt QListWidget for files (Being able to drop the files based on user-defined extensions)
- Host: GitHub
- URL: https://github.com/yjg30737/pyqt-file-list-widget
- Owner: yjg30737
- License: mit
- Created: 2021-12-11T07:09:10.000Z (about 3 years ago)
- Default Branch: main
- Last Pushed: 2022-05-14T10:40:10.000Z (almost 3 years ago)
- Last Synced: 2024-04-26T05:40:47.165Z (10 months ago)
- Topics: py37, pyqt, pyqt-examples, pyqt-file-list-widget, pyqt-qlistwidget, pyqt-tutorial, pyqt5, pyqt5-examples, pyqt5-file-list-widget, pyqt5-gui, pyqt5-qlistwidget, pyqt5-tutorial, python, python3, python37, qlistwidget, qt
- Language: Python
- Homepage:
- Size: 37.1 KB
- Stars: 2
- Watchers: 1
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# pyqt-file-list-widget
PyQt QListWidget for files (Being able to drop the files based on user-defined extensions)## Requirements
PyQt5 >= 5.8## Setup
`python -m pip install pyqt-file-list-widget`## Included Packages
* pyqt-tooltip-list-widget - parent class
* pyqt-files-already-exists-dialog## Method Overview
* `addFilenames(filenames: list, cur_filename: str = '')` - Add files on the list. `cur_filename` is current file name to set. Default is first one.
* `setFilenames(filenames: list, cur_filename: str = '')` - Clear the list before adding new files on the list.
* `addDirectory(dirname: str, cur_filename: str = '')` - Add files in directory.
* `setDirectory(dirname: str, cur_filename: str = '')` - Clear the list before adding new files on the list.
* `setFilenameOnly(f: bool)` - Show file name only. ex) C:\...\abc.txt -> abc.txt
* `isFilenameOnly() -> bool`
* `getSelectedFilenames() -> list`
* `removeSelectedRows()`
* `clear()` - Overriding method.
* `getAbsFilename(basename: str) -> str` - Get the absolute file path with base file name.
* `setExtensions(extensions: list)` - Set the acceptable extensions of list.
* `setDuplicateEnabled(f: bool)` - Allow list to have duplicate item.
* `isDuplicateEnabled() -> bool`
* `getFilenameFromRow(r: int) -> str`## Example
See pyqt-top-left-right-file-list-widget