An open API service indexing awesome lists of open source software.

https://github.com/yjg30737/pyqt-list-viewer-widget

PyQt widget which consist two widgets: file list widget and viewer widget
https://github.com/yjg30737/pyqt-list-viewer-widget

pyqt pyqt-examples pyqt5 pyqt5-desktop-application pyqt5-examples pyqt5-gui pyqtsignal python python3 python37 qlistwidget qt qt-examples qt5 qt5-gui

Last synced: 5 months ago
JSON representation

PyQt widget which consist two widgets: file list widget and viewer widget

Awesome Lists containing this project

README

        

# pyqt-list-viewer-widget
PyQt widget which consist two widgets: file list widget and viewer widget

## Requirements
* PyQt5 >= 5.8

## Setup
`pip3 install git+https://github.com/yjg30737/pyqt-file-list-widget.git --upgrade`

## Method Overview
* `setView(view)` - Set the view.
* `setExtensions(extensions: list)` - Set the extensions you want to accept. ex) ['.txt', '.doc']
* `addDirectory(dirname: str, cur_filename: str = '')` - Add the files in `dirname` directory. Set `cur_filename` argument if you want to make list set current filename.
* `setDirectory(dirname: str, cur_filename: str = '')` - Clear the list and add the directory.
* `addFilenames(filenames: list, cur_filename: str = '')`
* `setFilenames(filenames: list, cur_filename: str = '')`
* `getFileWidget()` - Return `FileWidget` on the left side of whole widget.
* `getListWidget()` - Return `FileListWidget`, list widget containing files placed in the `FileWidget`)
* `getViewerWidget()` - Return `ViewerWidget` on the right side of whole widget.
* `setAddAsDirectory(f: bool)` - If this is set `True`, adding a file in certain directory is not only add the file itself, but also add the other files.
* `isAddAsDirectory() -> bool`
* `setWindowTitleBasedOnCurrentFileEnabled(f: bool, prefix: str = '')` - If this is set `True` and prefix is being set, window title's format is set like `Prefix - 1.png` -> `Prefix - 2.png` ...
* `setBottomWidgetVisible(f: bool)` - Toggle the visibility of bottom widget (navigation widget) of viewer widget.
* `getCurrentFilename() -> str`

## Included Packages
* simplePyQt5
* pyqt-svg-icon-pushbutton
* pyqt-checkbox-file-list-widget
* pyqt-viewer-widget

## App Included This Package
* pyqt-html-viewer
* pyqt-svg-viewer