diff --git a/.github/workflows/ci.yml b/.github/workflows/build.yml similarity index 99% rename from .github/workflows/ci.yml rename to .github/workflows/build.yml index 78567f59..a5284c03 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,4 @@ -name: ci +name: build on: push: diff --git a/.gitignore b/.gitignore index 91a20989..5f68f6fc 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,6 @@ -# --------------------------------------------- Custom +# Custom themes - # Byte-compiled / optimized / DLL files __pycache__/ *.py[cod] diff --git a/CHANGELOG.md b/CHANGELOG.md index 42a3822d..7334a440 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Add cursor top_left_arrow cursor ful1e5/BreezeX_Cursor#10 ful1e5/BreezeX_Cursor#11 - Uninstall docs ful1e5/apple_cursor#79 ful1e5/apple_cursor#80 - feat: CLI for bitmapper #104 +- doc: build docs updated ### Changed diff --git a/README.md b/README.md index b4ae52b8..eeddcf84 100644 --- a/README.md +++ b/README.md @@ -1,43 +1,26 @@ # Bibata Cursor -[![ci](https://github.com/ful1e5/Bibata_Cursor/actions/workflows/ci.yml/badge.svg)](https://github.com/ful1e5/Bibata_Cursor/actions/workflows/ci.yml) -[![twitter](https://img.shields.io/badge/Notification-twitter-blue)](https://twitter.com/ful1e5) +[![build](https://github.com/ful1e5/Bibata_Cursor/actions/workflows/build.yml/badge.svg)](https://github.com/ful1e5/Bibata_Cursor/actions/workflows/build.yml) -**TLDR; This cursor set is the masterpiece of all cursors available on the internet.** +TLDR; This cursor set is the masterpiece of cursors available on the internet, +Hand designed by [Kaiz Khatri](https://twitter.com/ful1e5). -Bibata is **OpenSource**, compact, and material designed cursor set. This project masterelop for +Bibata is open source, compact, and material designed cursor set. This project masterelop for improve cursor experience. Bibata is one of the most popular cursors set in the Linux community so far and is now available for freely with multiple colors and size options for Windows as well. The aim of this project is to -provide the best personalized cursors to users. +provide the personalized cursors to users. -#### Future!? +![Bibata Amber](https://i.imgur.com/2DEYWDC.png) +![Bibata Classic](https://i.imgur.com/C8mMQ3j.png) +![Bibata Ice](https://i.imgur.com/ovzTw6u.png) -Until now Bibata was funded by [pling.com](https://www.pling.com) but since the -[pling-factor](https://www.pling.com/terms/payout) on the website has decreased and monthly payments -are <100$ it is now dependent on community funding and sponsorships. If you want to help us build -future cursors or if you use Bibata as the default cursor theme, consider becoming a partner. +> **Note** +> All cursor's `.svg` files are found in [svg](./svg) directory or you can also find them on +> [Figma](https://www.figma.com/file/Y9RKZLXhSvaxpUzsKGJkp6/Bibata-Cursor?node-id=0%3A1). -Your support will also be beneficial for my upcoming projects like: - -- [cursrs](https://github.com/ful1e5/cursrs) - Superior cursors platform. A open source web app - where you can customize customize and download cursors. - -Visit the [GitHub Sponsor](https://github.com/sponsors/ful1e5) page to become a partner. -DM me on [Twitter](https://twitter.com/ful1e5) if your company would like to support this project, -I will gladly look into it and post your logo in the README. - -#### Sponsors - -I appreciate all these wonderful people who patronize and sponsoring my work. -Your support will help me actively maintain Bibata and other open source projects. - - - -_Be you first._ - -#### Variants: +## Variants: - **Bibata Original Amber:** Yellowish and rounded edge bibata cursors. - **Bibata Modern Amber:** Yellowish and sharp edge bibata cursors. @@ -46,7 +29,9 @@ _Be you first._ - **Bibata Original Ice:** White and sharp edge bibata cursors. - **Bibata Modern Ice:** White and rounded edge bibata cursors -#### Xcursor Sizes: +## Cursor Sizes + +### Xcursor Sizes: 22 24 @@ -61,35 +46,47 @@ _Be you first._ 88 96 -#### Windows Cursor Size: +### Windows Cursor Size: - 16x16 - Small - 24x24 - Regular - 32x32 - Large - 48x48 - Extra Large -#### Gallery +## Colors: -> **Note** -> All svg files are found in [svg](./svg) directory or you can also use -> [Figma](https://www.figma.com/file/Y9RKZLXhSvaxpUzsKGJkp6/Bibata-Cursor?node-id=0%3A1). +### Bibata Amber -![Bibata Amber](https://i.imgur.com/2DEYWDC.png) -![Bibata Classic](https://i.imgur.com/C8mMQ3j.png) -![Bibata Ice](https://i.imgur.com/ovzTw6u.png) +- Base Color - `#FF8300` (Amber) +- Outline Color - `#FFFFFF` (White) +- Watch Background Color - `#001524` (Rich Black) -## Binaries +### Bibata Classic + +- Base Color - `#000000` (Black) +- Outline Color - `#FFFFFF` (White) +- Watch Background Color - `#000000` (Black) + +### Bibata Ice + +- Base Color - `#FFFFFF` (White) +- Outline Color - `#000000` (Black) +- Watch Background Color - `#FFFFFF` (White) + +## How to get it + +### Easiest Way You can download latest `stable` & `development` releases from [Release Page](https://github.com/ful1e5/Bibata_Cursor/releases). -## Packages +### Packages > **Note** > If you're having trouble with the packages please submit a request to the package maintainer > before creating an issue. -### Arch Linux/Manjaro +#### Arch Linux/Manjaro Arch Linux/Manjaro users can install from the [AUR](https://aur.archlinux.org/packages/bibata-cursor-theme) currently maintained by [_@Shatur_](https://aur.archlinux.org/packages/?K=Shatur&SeB=m) & @@ -104,16 +101,16 @@ paru -S bibata-cursor-theme Alternatively, Bibata binaries can be also installed using the PKGBUILD `bibata-theme-bin`, available on the AUR. -### Fedora +#### Fedora -#### copr-repo by @peterwu (recommended) +##### copr-repo by @peterwu (recommended) ```bash sudo dnf copr enable peterwu/rendezvous sudo dnf install bibata-cursor-themes ``` -#### copr-repo by @muhalantabli +##### copr-repo by @muhalantabli ```bash sudo dnf copr enable muhalantabli/copr-repo @@ -166,10 +163,26 @@ Run the `uninstall.bat` script packed with the `.zip` archive ## Build From Source +#### Notes + +- Bibata build configuration and cursor hotspot settings are bundled in the `build.toml` file. +- Check out the scripts section in [package.json](./package.json) to see how we build the cursor theme, + excluding the render scripts. They are useful for converting `.svg` files to `.png` files. +- yarn is optional, For building XCursors and Windows cursors from `.png` files or resizing them + you don't need that. If you want to develop/modify Bibata's colors, and bitmaps, or generate a png + file from a svg, Then you can use yarn because bitmapper is written in TypeScript. +- Since Bibata Modern and Bibata Original are designed similarly, they share the same hotspot settings so a + single configuration file `build.toml` is responsible for building all variants. Due to this, you will have + to change the following options in `ctgen` to build the appropriate variant: + - **-d**: bitmaps directory + - **-n**: The name you want to give to the generated theme. + - **-c**: Theme comment. + - See `ctgen --help` for all available options. + ### Build prerequisites - Python version 3.7 or higher -- [clickgen](https://github.com/ful1e5/clickgen) >= 2.0.0 Python package (`pip install clickgen`) +- [clickgen](https://github.com/ful1e5/clickgen)>=2.1.1 (`pip install clickgen`) - [yarn](https://github.com/yarnpkg/yarn) ### Quick start @@ -181,59 +194,52 @@ Run the `uninstall.bat` script packed with the `.zip` archive ### Building +> **Note** +> Bitmaps are already generated in the `bitmaps` directory and **managed by the maintainer** +> (do not edit them directly). + First make sure you installed the [build prerequisites](#build-prerequisites). Now that you have the dependencies, you can try build individual themes from bitmaps and customize sizes, target platform, and etc. with the `ctgen` CLI (packed with `clickgen`). -**Notes :** - -- Bibata build configuration and cursor hotspot settings are bundled in the `build.toml` file. -- Check out the scripts section in [package.json](./package.json) to see how we created the cursor theme, - excluding the render scripts. They are useful for converting `.svg` files to `.png` - that are already generated in the **bitmaps directory** and **managed by the maintainer**. -- **Yarn is optional**. For building XCursor and Windows Cursor or resizing it you don't need that. - If you want to develop/modify Bibata's colors, and bitmaps, or generate a png file from a svg, you can use - yarn because bitmapper is written in TypeScript. -- Since Bibata variants are designed similarly, they share the same hotspot settings so a single configuration - file `build.toml` is responsible for building all variants. Due to this, you will have to change the following - options in `ctgen` to build the appropriate variant: - - **-d**: bitmaps directory - - **-n**: The name you want to give to the generated theme. - - **-c**: Theme comment. - - See `ctgen --help` for all available options. - -##### Default Build Commands or `yarn build` +#### `yarn build` aberration Here are the default commands we used to build the Bibata's variants and packed them into `yarn build`: ```bash -ctgen build.toml -n 'Bibata-Modern-Amber' -c 'Yellowish and rounded edge bibata cursors.' -d 'bitmaps/Bibata-Modern-Amber' -ctgen build.toml -n 'Bibata-Modern-Classic' -c 'Black and rounded edge Bibata cursors.' -d 'bitmaps/Bibata-Modern-Classic' -ctgen build.toml -n 'Bibata-Modern-Ice' -c 'White and rounded edge Bibata cursors.' -d 'bitmaps/Bibata-Modern-Ice' +ctgen build.toml -d 'bitmaps/Bibata-Modern-Amber' -n 'Bibata-Modern-Amber' -c 'Yellowish and rounded edge bibata cursors.' +ctgen build.toml -d 'bitmaps/Bibata-Modern-Classic' -n 'Bibata-Modern-Classic' -c 'Black and rounded edge Bibata cursors.' +ctgen build.toml -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata-Modern-Ice' -c 'White and rounded edge Bibata cursors.' -ctgen build.toml -n 'Bibata-Original-Amber' -c 'Yellowish and sharp edge Bibata cursors.' -d 'bitmaps/Bibata-Original-Amber' -ctgen build.toml -n 'Bibata-Original-Classic' -c 'Black and sharp edge Bibata cursors.' -d 'bitmaps/Bibata-Original-Classic' -ctgen build.toml -n 'Bibata-Original-Ice' -c 'White and sharp edge Bibata cursors.' -d 'bitmaps/Bibata-Original-Ice' +ctgen build.toml -d 'bitmaps/Bibata-Original-Amber' -n 'Bibata-Original-Amber' -c 'Yellowish and sharp edge Bibata cursors.' +ctgen build.toml -d 'bitmaps/Bibata-Original-Classic' -n 'Bibata-Original-Classic' -c 'Black and sharp edge Bibata cursors.' +ctgen build.toml -d 'bitmaps/Bibata-Original-Ice' -n 'Bibata-Original-Ice' -c 'White and sharp edge Bibata cursors.' ``` -Afterwards, the themes can be found in the `themes/` directory. +Afterwards, the themes can be found in the `themes` directory. + +#### Customize Sizes + +> **Note** +> You can change the cursor size up to 200 because pngs are rendered with 200x200. +> If the cursor is resized by more than rendered png size, the final cursor will be blurred. ##### Customize Windows Cursor size To build Windows cursor with size `16`: > **Warning** -> Windows cursor supports only one size, if multiple sizes are given in `-s` the first size will +> Windows cursor supports only one size, if multiple sizes are given with `-s` the first size will > be considered in build. ```bash -ctgen build.toml -s 16 -p windows -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata Modern Ice' -c 'White and rounded egde bibata cusors with size 16' +ctgen build.toml -s 16 -p windows -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata-Modern-Ice' -c 'White and rounded egde bibata cusors with size 16' ``` You can also customize output directory with `-o` option: ```bash -ctgen build.toml -s 16 -p windows -d 'bitmaps/Bibata-Modern-Ice' -o 'out/' -n 'Bibata Modern Ice' -c 'White and rounded egde Bibata cursors with size 16' +ctgen build.toml -s 16 -p windows -d 'bitmaps/Bibata-Modern-Ice' -o 'out' -n 'Bibata-Modern-Ice' -c 'White and rounded egde Bibata cursors with size 16' ``` ##### Customize XCursor size @@ -241,15 +247,109 @@ ctgen build.toml -s 16 -p windows -d 'bitmaps/Bibata-Modern-Ice' -o 'out/' -n 'B To build XCursor with size `16`: ```bash -ctgen build.toml -s 16 -p x11 -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata Modern Ice' -c 'White and rounded egde Bibata cursors with size 16' +ctgen build.toml -s 16 -p x11 -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata-Modern-Ice' -c 'White and rounded egde Bibata cursors with size 16' ``` You can also assign multiple sizes to `ctgen` for XCursors build: ```bash -ctgen build.toml -s 16 24 32 -p x11 -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata Modern Ice' -c 'White and rounded egde Bibata cursors with size 16' +ctgen build.toml -s 16 24 32 -p x11 -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata-Modern-Ice' -c 'Custom white and rounded egde Bibata cursors' ``` +#### Customize Colors + +To customize bibata's color you have to compile the bibata-bitmapper with `yarn compile` command. +After compiling bibata-bitmapper form source code you can customize the colors via `cli.js` node script, +Which you will find in the `dist` directory. + +##### `cli.js` Help + +``` +Usage: bibata-bitmapper [OPTIONS]... + +Options: + -V, --version output the version number + -d, --dir Specifies the directory for placement of SVG files. + -o, --out Specifies the output directory. (default './bitmaps') + -n, --themeName Specifies the name of output directory. + -bc, --baseColor Specifies the Hexadecimal color for inner part of cursor. + -oc, --outlineColor Specifies the Hexadecimal color for cursor's ouline. + -wc, --watchBackgroundColor Specifies the Hexadecimal color for animation background. + -h, --help display help for command +``` + +##### `yarn render` aberration + +Here are the default commands we used for generating the Bibata's bitmaps and packed them into `yarn render`: + +```bash +node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Amber' -bc '#FF8300' -oc '#FFFFFF' -wc '#001524' +node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Classic' -bc '#000000' -oc '#FFFFFF' +node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Ice' -bc '#FFFFFF' -oc '#000000' +node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Amber' -bc '#FF8300' -oc '#FFFFFF' -wc '#001524' +node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Classic' -bc '#000000' -oc '#FFFFFF' +node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Ice' -bc '#FFFFFF' -oc '#000000' +``` + +#### Examples + +Lets generate modern Bibata with green base color and black outline: + +```bash +node dist/cli.js -d 'svg/modern' -n 'Bibata-Hacker' -bc '#00FE00' -oc '#000000' -wc '#001524' +``` + +After rendering custom color you have to build cursor through `ctgen`: + +```bash +ctgen build.toml -d 'bitmaps/Bibata-Hacker' -n 'Bibata-Hacker' -c 'Green and black Bibata cursors.' +``` + +Afterwards, Generated theme can be found in the `themes` directory. + +###### Bibata Gruvbox + +```bash +node dist/cli.js -d 'svg/original' -n 'Bibata-Gruvbox' -bc '#282828' -oc '#EBDBB2' -wc '#000000' +ctgen build.toml -d 'bitmaps/Bibata-Gruvbox' -n 'Bibata-Gruvbox' -c 'Groovy Bibata cursors.' +``` + +###### Bibata Solarized Dark + +```bash +node dist/cli.js -d 'svg/original' -n 'Bibata-Solarized-Dark' -bc '#002b36' -oc '#839496' -wc '#000000' +ctgen build.toml -d 'bitmaps/Bibata-Solarized-Dark' -n 'Bibata-Solarized-Dark' -c 'Solarized Dark Bibata cursors.' +``` + +###### Bibata Solarized Light + +```bash +node dist/cli.js -d 'svg/original' -n 'Bibata-Solarized-Light' -bc '#839496' -oc '#002b36' +ctgen build.toml -d 'bitmaps/Bibata-Solarized-Light' -n 'Bibata-Solarized-Light' -c 'Solarized Light Bibata cursors.' +``` + +###### Bibata Dracula + +```bash +node dist/cli.js -d 'svg/original' -n 'Bibata-Dracula' -bc '#282a36' -oc '#f8f8f2' +ctgen build.toml -d 'bitmaps/Bibata-Dracula' -n 'Bibata-Dracula' -c 'Dracula Bibata cursors.' +``` + +## Consider Sponsoring my work + +Until now my cursors projects were funded by [pling.com](https://www.pling.com) but since the +[pling-factor](https://www.pling.com/terms/payout) on the website has decreased and monthly payments +are <500$, It is now dependent on community funding and sponsorships. If you want to help me to maintain +Bibata and my other open source projects actively, consider sponsoring my work on [GitHub Sponsor](https://github.com/sponsors/ful1e5) +or DM me on [Twitter](https://twitter.com/ful1e5) if your company would like to support this project, +I will gladly look into it and post your avatar in the README. + +I appreciate all the wonderful people who patronize and sponsoring my work. + + + +_Be you first._ + ## You may also like... - [**Bibata Adapta**](https://gitlab.com/cscs/Bibata_AdaptaBreath_Cursors) - Bibata Based Cursor Made for AdaptaBreath and Manjaro. diff --git a/build.toml b/build.toml index 4d2aecbd..ba6be57d 100644 --- a/build.toml +++ b/build.toml @@ -4,7 +4,7 @@ comment = 'Bibata is open source, compact, and material designed cursor set.' website = 'https://www.github.com/ful1e5/Bibata_Cursor' [config] -bitmaps_dir = '' # This config will assigned with CLI +bitmaps_dir = '' # This config will assigned with `ctgen -d ` out_dir = 'themes' platforms = ['x11', 'windows'] x11_sizes = [22, 24, 28, 32, 40, 48, 56, 64, 72, 80, 88, 96] @@ -20,7 +20,7 @@ win_delay = 1 [cursors.bd_double_arrow] png = 'bd_double_arrow.png' -x_hotspot = 98 +x_hotspot = 99 y_hotspot = 100 win_name = 'Diagonal_1' x11_name = 'bd_double_arrow' @@ -28,15 +28,15 @@ x11_symlinks = ["c7088f0f3e6c8088236ef8e1e3e70000", "nwse-resize", "size_fdiag"] [cursors.bottom_left_corner] png = 'bottom_left_corner.png' -x_hotspot = 31 +x_hotspot = 30 y_hotspot = 172 x11_name = 'bottom_left_corner' x11_symlinks = ["sw-resize"] [cursors.bottom_right_corner] png = 'bottom_right_corner.png' -x_hotspot = 170 -y_hotspot = 172 +x_hotspot = 171 +y_hotspot = 173 x11_name = 'bottom_right_corner' x11_symlinks = ['se-resize'] @@ -49,34 +49,34 @@ x11_symlinks = ['s-resize'] [cursors.bottom_tee] png = 'bottom_tee.png' -x_hotspot = 100 +x_hotspot = 98 y_hotspot = 164 x11_name = 'bottom_tee' [cursors.center_ptr] png = 'center_ptr.png' x_hotspot = 98 -y_hotspot = 131 +y_hotspot = 13 x11_name = 'center_ptr' [cursors.circle] png = 'circle.png' -x_hotspot = 48 -y_hotspot = 25 +x_hotspot = 43 +y_hotspot = 14 win_name = 'Unavailiable' x11_name = 'circle' x11_symlinks = ['forbidden'] [cursors.context-menu] png = 'context-menu.png' -x_hotspot = 48 -y_hotspot = 25 +x_hotspot = 43 +y_hotspot = 14 x11_name = 'context-menu' [cursors.copy] png = 'copy.png' -x_hotspot = 48 -y_hotspot = 25 +x_hotspot = 43 +y_hotspot = 14 x11_name = 'copy' x11_symlinks = [ "1081e37283d90000800003c07f3ef6bf", @@ -101,53 +101,53 @@ x11_symlinks = ["03b6e0fcb3499374a867c041f52298f0", "not-allowed"] [cursors.crosshair] png = 'crosshair.png' -x_hotspot = 99 -y_hotspot = 99 +x_hotspot = 100 +y_hotspot = 101 x11_name = 'crosshair' [cursors.dnd_no_drop] png = 'dnd_no_drop.png' -x_hotspot = 86 -y_hotspot = 79 +x_hotspot = 89 +y_hotspot = 61 x11_name = 'dnd_no_drop' x11_symlinks = ["no-drop"] [cursors.dnd-ask] png = 'dnd-ask.png' -x_hotspot = 86 -y_hotspot = 79 +x_hotspot = 89 +y_hotspot = 61 x11_name = 'dnd-ask' [cursors.dnd-copy] png = 'dnd-copy.png' -x_hotspot = 86 -y_hotspot = 79 +x_hotspot = 89 +y_hotspot = 61 x11_name = 'dnd-copy' [cursors.dnd-link] png = 'dnd-link.png' -x_hotspot = 86 -y_hotspot = 79 +x_hotspot = 89 +y_hotspot = 61 x11_name = 'dnd-link' x11_symlinks = ['alias'] [cursors.dnd-move] png = 'dnd-move.png' -x_hotspot = 86 -y_hotspot = 79 +x_hotspot = 89 +y_hotspot = 61 x11_name = 'dnd-move' [cursors.dotbox] png = 'dotbox.png' -x_hotspot = 100 -y_hotspot = 100 +x_hotspot = 97 +y_hotspot = 99 x11_name = 'dotbox' x11_symlinks = ["dot_box_mask", "draped_box", "icon", "target"] [cursors.fd_double_arrow] png = 'fd_double_arrow.png' -x_hotspot = 98 -y_hotspot = 100 +x_hotspot = 99 +y_hotspot = 99 win_name = 'Diagonal_2' x11_name = 'fd_double_arrow' x11_symlinks = ["fcf1c3c7cd4491d801f1e1c78f100000", "nesw-resize", "size_bdiag"] @@ -155,14 +155,14 @@ x11_symlinks = ["fcf1c3c7cd4491d801f1e1c78f100000", "nesw-resize", "size_bdiag"] [cursors.grabbing] png = 'grabbing.png' x_hotspot = 106 -y_hotspot = 79 +y_hotspot = 59 x11_name = 'grabbing' x11_symlinks = ["closedhand", "dnd-none", "fcf21c00b30f7e3f83fe0dfd12e71cff"] [cursors.hand1] png = 'hand1.png' -x_hotspot = 113 -y_hotspot = 95 +x_hotspot = 117 +y_hotspot = 39 win_name = 'Move' x11_name = 'hand1' x11_symlinks = ["grab", "openhand"] @@ -170,7 +170,7 @@ x11_symlinks = ["grab", "openhand"] [cursors.hand2] png = 'hand2.png' x_hotspot = 88 -y_hotspot = 32 +y_hotspot = 14 win_name = 'Link' x11_name = 'hand2' x11_symlinks = [ @@ -182,16 +182,16 @@ x11_symlinks = [ [cursors.left_ptr] png = 'left_ptr.png' -x_hotspot = 53 -y_hotspot = 36 +x_hotspot = 42 +y_hotspot = 15 win_name = 'Default' x11_name = 'left_ptr' x11_symlinks = ["arrow", "default", "top_left_arrow"] [cursors.left_ptr_watch] png = 'left_ptr_watch-*.png' -x_hotspot = 50 -y_hotspot = 28 +x_hotspot = 44 +y_hotspot = 14 win_name = 'Work' x11_name = 'left_ptr_watch' x11_symlinks = [ @@ -204,20 +204,20 @@ x11_symlinks = [ [cursors.left_side] png = 'left_side.png' x_hotspot = 35 -y_hotspot = 100 +y_hotspot = 101 x11_name = 'left_side' x11_symlinks = ['w-resize'] [cursors.left_tee] png = 'left_tee.png' x_hotspot = 165 -y_hotspot = 95 +y_hotspot = 96 x11_name = 'left_tee' [cursors.link] png = 'link.png' -x_hotspot = 48 -y_hotspot = 25 +x_hotspot = 43 +y_hotspot = 14 x11_name = 'link' x11_symlinks = [ "3085a0e285430894940527032f8b26df", @@ -228,19 +228,19 @@ x11_symlinks = [ [cursors.ll_angle] png = 'll_angle.png' x_hotspot = 34 -y_hotspot = 165 +y_hotspot = 164 x11_name = 'll_angle' [cursors.lr_angle] png = 'lr_angle.png' -x_hotspot = 167 -y_hotspot = 164 +x_hotspot = 165 +y_hotspot = 165 x11_name = 'lr_angle' [cursors.move] png = 'move.png' -x_hotspot = 100 -y_hotspot = 100 +x_hotspot = 99 +y_hotspot = 99 x11_name = 'move' x11_symlinks = [ "4498f0e0c1937ffe01fd06f973665830", @@ -252,8 +252,8 @@ x11_symlinks = [ [cursors.pencil] png = 'pencil.png' -x_hotspot = 37 -y_hotspot = 161 +x_hotspot = 28 +y_hotspot = 172 win_name = 'Handwriting' x11_name = 'pencil' x11_symlinks = ['draft'] @@ -267,14 +267,14 @@ x11_symlinks = ['cell'] [cursors.pointer-move] png = 'pointer-move.png' -x_hotspot = 48 -y_hotspot = 25 +x_hotspot = 43 +y_hotspot = 14 x11_name = 'pointer-move' [cursors.question_arrow] png = 'question_arrow.png' -x_hotspot = 102 -y_hotspot = 102 +x_hotspot = 43 +y_hotspot = 105 win_name = 'Help' x11_name = 'question_arrow' x11_symlinks = [ @@ -287,8 +287,8 @@ x11_symlinks = [ [cursors.right_ptr] png = 'right_ptr.png' -x_hotspot = 150 -y_hotspot = 29 +x_hotspot = 156 +y_hotspot = 14 win_name = 'Alternate' x11_name = 'right_ptr' x11_symlinks = ["draft_large", "draft_small"] @@ -302,20 +302,20 @@ x11_symlinks = ['e-resize'] [cursors.right_tee] png = 'right_tee.png' -x_hotspot = 30 +x_hotspot = 31 y_hotspot = 96 x11_name = 'right_tee' [cursors.sb_down_arrow] png = 'sb_down_arrow.png' x_hotspot = 100 -y_hotspot = 126 +y_hotspot = 178 x11_name = 'sb_down_arrow' x11_symlinks = ['down-arrow'] [cursors.sb_h_double_arrow] png = 'sb_h_double_arrow.png' -x_hotspot = 100 +x_hotspot = 99 y_hotspot = 100 win_name = 'Horizontal' x11_name = 'sb_h_double_arrow' @@ -332,14 +332,14 @@ x11_symlinks = [ [cursors.sb_left_arrow] png = 'sb_left_arrow.png' -x_hotspot = 86 +x_hotspot = 20 y_hotspot = 100 x11_name = 'sb_left_arrow' x11_symlinks = ['left-arrow'] [cursors.sb_right_arrow] png = 'sb_right_arrow.png' -x_hotspot = 113 +x_hotspot = 178 y_hotspot = 100 x11_name = 'sb_right_arrow' x11_symlinks = ['right-arrow'] @@ -347,13 +347,13 @@ x11_symlinks = ['right-arrow'] [cursors.sb_up_arrow] png = 'sb_up_arrow.png' x_hotspot = 99 -y_hotspot = 86 +y_hotspot = 21 x11_name = 'sb_up_arrow' x11_symlinks = ['up-arrow'] [cursors.sb_v_double_arrow] png = 'sb_v_double_arrow.png' -x_hotspot = 100 +x_hotspot = 99 y_hotspot = 100 win_name = 'Vertical' x11_name = 'sb_v_double_arrow' @@ -371,8 +371,8 @@ x11_symlinks = [ [cursors.tcross] png = 'tcross.png' -x_hotspot = 98 -y_hotspot = 100 +x_hotspot = 100 +y_hotspot = 99 x11_name = 'tcross' x11_symlinks = ['color-picker'] @@ -386,21 +386,21 @@ x11_symlinks = ['nw-resize'] [cursors.top_right_corner] png = 'top_right_corner.png' x_hotspot = 170 -y_hotspot = 28 +y_hotspot = 26 x11_name = 'top_right_corner' x11_symlinks = ['ne-resize'] [cursors.top_side] png = 'top_side.png' x_hotspot = 98 -y_hotspot = 34 +y_hotspot = 36 x11_name = 'top_side' x11_symlinks = ['n-resize'] [cursors.top_tee] png = 'top_tee.png' -x_hotspot = 98 -y_hotspot = 29 +x_hotspot = 99 +y_hotspot = 30 x11_name = 'top_tee' [cursors.ul_angle] @@ -412,7 +412,7 @@ x11_name = 'ul_angle' [cursors.ur_angle] png = 'ur_angle.png' x_hotspot = 164 -y_hotspot = 34 +y_hotspot = 35 x11_name = 'ur_angle' [cursors.vertical-text] @@ -450,12 +450,12 @@ x11_symlinks = ["ibeam", "text"] [cursors.zoom_in] png = 'zoom-in.png' -x_hotspot = 90 -y_hotspot = 89 +x_hotspot = 91 +y_hotspot = 90 x11_name = 'zoom-in' [cursors.zoom_out] png = 'zoom-out.png' -x_hotspot = 93 +x_hotspot = 89 y_hotspot = 90 x11_name = 'zoom-out' diff --git a/package.json b/package.json index 9da7e9e0..dbeeb45f 100644 --- a/package.json +++ b/package.json @@ -1,8 +1,8 @@ { "name": "bibata-bitmapper", - "description": "A bitmapper CLI for Bibata cursor.", + "description": "This package generate '.png' file from '.svg'", "author": "Kaiz Khatri", - "version": "1.1.2", + "version": "2.0.0", "private": false, "license": "GPL-3.0", "main": "dist/cli.js", @@ -15,16 +15,22 @@ }, "scripts": { "compile": "tsc -p .", - "render:bibata-modern": "yarn compile && node dist/cli.js modern", - "render:bibata-original": "yarn compile && node dist/cli.js original", + "render:bibata-modern-amber": "yarn compile && node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Amber' -bc '#FF8300' -oc '#FFFFFF' -wc '#001524'", + "render:bibata-modern-classic": "yarn compile && node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Classic' -bc '#000000' -oc '#FFFFFF'", + "render:bibata-modern-ice": "yarn compile && node dist/cli.js -d 'svg/modern' -n 'Bibata-Modern-Ice' -bc '#FFFFFF' -oc '#000000'", + "render:bibata-modern": "yarn render:bibata-modern-amber && yarn render:bibata-modern-classic && yarn render:bibata-modern-ice", + "render:bibata-original-amber": "yarn compile && node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Amber' -bc '#FF8300' -oc '#FFFFFF' -wc '#001524'", + "render:bibata-original-classic": "yarn compile && node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Classic' -bc '#000000' -oc '#FFFFFF'", + "render:bibata-original-ice": "yarn compile && node dist/cli.js -d 'svg/original' -n 'Bibata-Original-Ice' -bc '#FFFFFF' -oc '#000000'", + "render:bibata-original": "yarn render:bibata-original-amber && yarn render:bibata-original-classic && yarn render:bibata-original-ice", "render": "yarn render:bibata-modern && yarn render:bibata-original", - "build:bibata-modern-amber": "ctgen build.toml -n 'Bibata-Modern-Amber' -c 'Yellowish and rounded edge Bibata cursors.' -d 'bitmaps/Bibata-Modern-Amber'", - "build:bibata-modern-classic": "ctgen build.toml -n 'Bibata-Modern-Classic' -c 'Black and rounded edge Bibata cursors.' -d 'bitmaps/Bibata-Modern-Classic'", - "build:bibata-modern-ice": "ctgen build.toml -n 'Bibata-Modern-Ice' -c 'White and rounded edge Bibata cursors.' -d 'bitmaps/Bibata-Modern-Ice'", - "build:bibata-original-amber": "ctgen build.toml -n 'Bibata-Original-Amber' -c 'Yellowish and sharp edge Bibata cursors.' -d 'bitmaps/Bibata-Original-Amber'", - "build:bibata-original-classic": "ctgen build.toml -n 'Bibata-Original-Classic' -c 'Black and sharp edge Bibata cursors.' -d 'bitmaps/Bibata-Original-Classic'", - "build:bibata-original-ice": "ctgen build.toml -n 'Bibata-Original-Ice' -c 'White and sharp edge bibata cursors.' -d 'bitmaps/Bibata-Original-Ice'", + "build:bibata-modern-amber": "ctgen build.toml -d 'bitmaps/Bibata-Modern-Amber' -n 'Bibata-Modern-Amber' -c 'Yellowish and rounded edge Bibata cursors.'", + "build:bibata-modern-classic": "ctgen build.toml -d 'bitmaps/Bibata-Modern-Classic' -n 'Bibata-Modern-Classic' -c 'Black and rounded edge Bibata cursors.'", + "build:bibata-modern-ice": "ctgen build.toml -d 'bitmaps/Bibata-Modern-Ice' -n 'Bibata-Modern-Ice' -c 'White and rounded edge Bibata cursors.'", "build:bibata-modern": "yarn build:bibata-modern-amber && yarn build:bibata-modern-classic && yarn build:bibata-modern-ice", + "build:bibata-original-amber": "ctgen build.toml -d 'bitmaps/Bibata-Original-Amber' -n 'Bibata-Original-Amber' -c 'Yellowish and sharp edge Bibata cursors.'", + "build:bibata-original-classic": "ctgen build.toml -d 'bitmaps/Bibata-Original-Classic' -n 'Bibata-Original-Classic' -c 'Black and sharp edge Bibata cursors.' ", + "build:bibata-original-ice": "ctgen build.toml -d 'bitmaps/Bibata-Original-Ice' -n 'Bibata-Original-Ice' -c 'White and sharp edge bibata cursors.'", "build:bibata-original": "yarn build:bibata-original-amber && yarn build:bibata-original-classic && yarn build:bibata-original-ice", "build": "yarn build:bibata-modern && yarn build:bibata-original" }, diff --git a/src/cli.ts b/src/cli.ts index 4538127f..50dc5de5 100644 --- a/src/cli.ts +++ b/src/cli.ts @@ -2,10 +2,9 @@ require("module-alias/register"); import path from "path"; -import { Argument, Command, Option } from "commander"; +import { Command, Option } from "commander"; import { builder } from "#root/modules"; -import * as commands from "#root/commands"; import { exitWithError } from "#root/utils/exitWithError"; @@ -20,23 +19,12 @@ interface ProgramOptions { const cliApp = async () => { const program = new Command(); - let style: string = ""; program .name("bibata-bitmapper") - .version("1.1.2") + .version("2.0.0") .usage("[OPTIONS]...") - .addArgument( - new Argument( - "