skip to navigation
skip to content

qrc-pathlib 1.0.2

Extension for pathlib that implements Path and PurePath for Qt Resources System.

qrc_pathlib

Qt Resource System allows to store files inside binaries and read them by using Qt’s file system abstraction (QFile, QDir etc).

This package extends pathlib introduced in Python 3.4 by implementing Path and PurePath for QRS:

from qrc_pathlib import QrcPath

QrcPath(':my_resource.svg').read_bytes()

with QrcPath(':hello.txt').open() as f:
    print(f.read())

Since QRS is read-only all methods that are supposed to modify files raise PermissionError. Other inapplicable methods such as stat will raise NotImplementedError.

 
File Type Py Version Uploaded on Size
qrc_pathlib-1.0.2-py3-none-any.whl (md5) Python Wheel py3 2016-04-29 6KB
qrc_pathlib-1.0.2.tar.gz (md5) Source 2016-04-29 5KB