Skip to main content

Package for opening native file dialogs on linux, macOS and windows.

Project description

filedialpy

Python package for opening native file dialogs on linux, macOS and windows. It uses either zenity or kdialog on linux, pywin32 on windows and applescript on macOS.

Installation

pip install filedialpy

Usage

import filedialpy

f=filedialpy.openFile()    # Open a single file (return a string)
f=filedialpy.openFiles()   # Open multiple files (return a list of strings)
f=filedialpy.openDir()     # Open a directory (return a string)
f=filedialpy.saveFile()    # Save to a new file (return a string)

# Using additional options
f=filedialpy.saveFile(initial_dir="/home/user/Documents",initial_file="config.json",title="Save config file", filter=["*.json","*"])

Options

  • initial_dir: Initial directory where to start the search (current working directory if not specified).
  • initial_file: Initial filename.
  • title: Title for the dialog window.
  • filter: string "*.json *.txt" (different accepted extensions can be separated by a space), or a list of such strings in order to provide several possible filters.
  • confirm_overwrite: Only for saveFile. If true (default), will prompt the user for a confirmation before overwriting an existing file. On some platforms (mac, kdialog), this overwrite confirmation cannot be disabled.

Acknowledgements

The implementation of filedialpy was inspired by crossfiledialog.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

filedialpy-1.3.2.tar.gz (16.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

filedialpy-1.3.2-py3-none-any.whl (18.4 kB view details)

Uploaded Python 3

File details

Details for the file filedialpy-1.3.2.tar.gz.

File metadata

  • Download URL: filedialpy-1.3.2.tar.gz
  • Upload date:
  • Size: 16.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.9

File hashes

Hashes for filedialpy-1.3.2.tar.gz
Algorithm Hash digest
SHA256 cd8aedb8168dceb01860a40fe8fee6b5a598012d247bd9674e2c904fcbb62cf2
MD5 d386f59f0c92a5b2bb3e2d0925c80eaf
BLAKE2b-256 cc89266e9497a25c960662667acf23814921c750775101e49862fe089c0ec548

See more details on using hashes here.

File details

Details for the file filedialpy-1.3.2-py3-none-any.whl.

File metadata

  • Download URL: filedialpy-1.3.2-py3-none-any.whl
  • Upload date:
  • Size: 18.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.7.9

File hashes

Hashes for filedialpy-1.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 07e73bd4231cb1647960684d3e283583c0ebdd52d7023a0fb7b75854625ba3e6
MD5 dd37ba986d334fbb62a7c552b1fcb917
BLAKE2b-256 f24ab5941674779d66d55b9d9872f04289e0176458905e32a8b31e4fcd15d366

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page