win2xcur/README.md

55 lines
2.1 KiB
Markdown
Raw Permalink Normal View History

2023-08-02 23:42:43 -04:00
# `win2xcur` and `x2wincur` [![Build Status](https://img.shields.io/github/actions/workflow/status/quantum5/win2xcur/build.yml)](https://github.com/quantum5/win2xcur/actions) [![PyPI](https://img.shields.io/pypi/v/win2xcur.svg)](https://pypi.org/project/win2xcur/) [![PyPI - Format](https://img.shields.io/pypi/format/win2xcur.svg)](https://pypi.org/project/win2xcur/) [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/win2xcur.svg)](https://pypi.org/project/win2xcur/)
2020-09-26 19:51:08 -04:00
`win2xcur` is a tool that converts cursors from Windows format (`*.cur`,
`*.ani`) to Xcursor format. This allows Windows cursor themes to be used on
Linux, for example.
`win2xcur` is more than a simple image conversion tool. It preserves the cursor
hotspot and animation delay, and has an optional mode to add shadows that
replicates Windows's cursor shadow effect.
2020-10-03 01:56:26 -04:00
`x2wincur` is a tool that does the opposite: it converts cursors in the Xcursor
2021-02-02 19:29:45 -05:00
format to Windows format (`*.cur`, `*.ani`), allowing to use your favourite
2020-10-03 01:56:26 -04:00
Linux cursor themes on Windows.
2020-09-26 19:51:08 -04:00
## Installation
To install the latest stable version:
pip install win2xcur
To install from GitHub:
pip install -e git+https://github.com/quantum5/win2xcur.git
2020-10-03 01:56:26 -04:00
## Usage: `win2xcur`
2020-09-26 19:51:08 -04:00
2020-10-03 01:56:26 -04:00
For example, if you want to convert [the sample cursor](sample/crosshair.cur)
to Linux format:
2020-09-26 19:51:08 -04:00
mkdir output/
win2xcur sample/crosshair.cur -o output/
`-s` can be specified to enable shadows.
Multiple cursors files can be specified on the command line.
For example, to convert a directory of cursors with shadows enabled:
win2xcur input/*.{ani,cur} -o output/
For more information, run `win2xcur --help`.
2020-10-03 01:56:26 -04:00
## Usage: `x2wincur`
For example, if you want to convert DMZ-White to Windows:
mkdir dmz-white/
x2wincur /usr/share/icons/DMZ-White/cursors/* -o dmz-white/
2021-09-08 06:38:36 -04:00
## Troubleshooting
`win2xcur` and `x2wincur` should work out of the box on most systems. If you
2022-03-24 01:37:23 -04:00
are using unconventional distros (e.g. Alpine) and are getting errors related
2021-09-08 06:38:36 -04:00
to `wand`, please see the [Wand documentation on installation][wand-install].
[wand-install]: https://docs.wand-py.org/en/0.6.7/guide/install.html