Skip to content
🎨 Click on a pixel on your screen and show its color value
Shell Makefile
Branch: master
Clone or download
sdushantha Merge pull request #14 from Noah2610/master
Fix --version description, kunst -> farge
Latest commit 1164f4b Aug 17, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
extra first commit Jul 23, 2019
LICENSE Create LICENSE Jul 23, 2019
Makefile first commit Jul 23, 2019
README.md fix --version description, kunst -> farge Aug 17, 2019
farge fix --version description, kunst -> farge Aug 17, 2019

README.md


✨ Click on a pixel on your screen and show its color value ✨

farge is command line tool to select pixel on the screen and return the value of the color in either HEX or RGB format. The color code is automatically saved to the clipboard. If you want to save the color, farge is able to show the color in a image viewer with the color code on it. This tool is able to use a varaiety of image viewers like feh, mΜ€pv andsxiv. This tool works on X11 and Wayland.

Dependencies

  • bash
  • imagemagick
  • feh (Other: mpv or sxiv, but you must specify it using the --image-viewer flag)

If you use X11

If you use Wayland

Installation

Install using make

# Clone the repo
$ git clone https://github.com/sdushantha/farge

# Change your current directory to farge
$ cd farge

# Install it
$ sudo make install

Install it locally

# Download the farge source code, save it as farge
# and make it executeable
$ curl -L https://git.io/raw-farge > farge && chmod +x farge

# Then move farge to somewhere in your $PATH
# Here is an example
$ mv farge ~/scripts/

Usage

$ farge --help
usage: farge [-h] [--no-preview] [--no-color-code] [--rbg]  [--version]
 
β”Œβ”€β”β”Œβ”€β”β”¬β”€β”β”Œβ”€β”β”Œβ”€β”
β”œβ”€ β”œβ”€β”€β”œβ”¬β”˜β”‚ β”¬β”œβ”€ 
β”΄  β”΄ β”΄β”΄β””β”€β””β”€β”˜β””β”€β”˜
Click on a pixel on your screen and show its color value

optional arguments:
   --help                show this help message and exit
   --no-preview          dont show the selected color in a preview window
   --no-color-code       dont write the color code on the preview window
   --rgb                 show the color code as RGB instead of HEX
   --image-viewer        image viewer to use to show the preview (feh, mpv, sxiv)
   --stdout              output the color value to stdout
   --version             show the version of farge you are using

Tips

It would be smart to bind farge to a keybinding. Here is an example for i3wm users:

bindsym $mod+Shift+f --release exec farge

If you use a window manager, you can assign rules the windows so they are always floating. For i3wm user, put this in your config:

# Let the windows created by Farge be floating
for_window [instance="Farge"] floating enable

License

MIT License

Copyright Β© 2019 Siddharth Dushantha

You can’t perform that action at this time.