Skip to main content

hidpi-tk

https://img.shields.io/pypi/v/hidpi-tk.svg

hidpi-tk is a Python library designed to enhance Tkinter-based GUI applications by automatically adjusting DPI scaling and font sizes, particularly for high-DPI monitors.

./screenshot.png

Features

  • Automatic DPI Scaling

  • Automatic Font Size Adjustment

  • Without side-effects

  • Cross-Platform

Usage

To use this library, simply replace the standard Tk class with DPIAwareTk. The library will handle DPI and font adjustments automatically:

from hidpi_tk import DPIAwareTk
# from tkinter import Tk

# root = Tk()
root = DPIAwareTk()
# After that use like Tk instance
root.mainloop()

Details

On Windows systems, it provides full support for scaling on high-DPI monitors, particularly for Windows 8.1 and newer. For older Windows systems (Vista & Win7) , it still adjusts DPI and font scaling to an extent.

For other systems, such as macOS and Linux, the operating systems themselves provide excellent high-DPI support, so this library does not include specific code for DPI adjustments. However, using this library is still beneficial as it adjusts font scaling, which makes cross-platform development easier and more consistent.

License

hidpi-tk library is offered under Apache 2 license.

Thanks

The library development is based on high-dpi-tkinter.

Added: High-DPI font scaling support, legacy Windows support, bug fixes, and modern Python standards.

Developed from v1, the original project has now been completely rewritten.

Metadata

Release files for hidpi-tk 1.4.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for hidpi-tk 1.4.1
File Size Uploaded Provenance Actions
hidpi_tk-1.4.1.tar.gz 8.7 kB Without provenance Details for hidpi_tk-1.4.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for hidpi-tk 1.4.1
File Interpreter ABI Platform Actions
hidpi_tk-1.4.1-py3-none-any.whl Python 3 none any Details for hidpi_tk-1.4.1-py3-none-any.whl

Total release size: 17.4 kB

Release files / hidpi_tk-1.4.1.tar.gz

Download URL hidpi_tk-1.4.1.tar.gz
Size 8.7 kB
Tags Source
SHA-256 checksum
How to use checksums
d9d4e265efb94a15c4da84bb0f4d03d7d8c580f882f132faebca899f1f0e0a37
BLAKE2b-256 checksum
How to use checksums
11c83c61803b096334fba4349b7b7b53817f6534ff21e5788c32c289a94eac65
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.26 {"installer":{"name":"uv","version":"0.11.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / hidpi_tk-1.4.1-py3-none-any.whl

Download URL hidpi_tk-1.4.1-py3-none-any.whl
Size 8.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
774b3b568591c70d40b386af71b155c3dc900c002e3f5225519dcc3f5f00fded
BLAKE2b-256 checksum
How to use checksums
f669c091f071d8fc739f52ba514279d7432ec3b5823088db383b755d206aa7a2
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.26 {"installer":{"name":"uv","version":"0.11.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for hidpi-tk 1.4.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page