Gfret

Introduction

Gfret renders an svg image template of a fretboard for a stringed instrument. It has a Gtk interface as well as a command line interface and can produce templates for instruments ranging from a piccolo mandolin to an upright bass. Multiscale designs are also supported. Currently, all measurements are expressed in metric units only.

Getting Gfret

Gfret is distributed primarily in source form. The main repo is at codeberg.org) with a mirror at github.com. Releases are recommended.

=> Codeberg repo
=> Github mirror

Usage

Gfret can be used from the command line or using the Gtk+ interface.

Running the command line interface

gfret-cli

Output an svg without running the interface

USAGE:
   gfret cli [OPTIONS] [OUTPUT]

ARGS:
       Name of the output file [default: output.svg]

OPTIONS:
   -b, --bridge 
           Bridge spacing [default: 56]

   -c, --count 
           Total fret count [default: 24]

   -e, --external 
           Open output file in external program [default: inkscape]

   -h, --help
           Print help information

   -l, --left
           Multiscale fretboard reversed (left handed)

   -m, --multi 
           Creates a multiscale fretboard with  as the treble scale. [default: 610]

   -n, --nut 
           Nut width [default: 43]

   -o, --output 
           Name of the output file [default: output.svg]

   -p, --perpendicular 
           Set which fret is perpendicular to the centerline [default: 8]
   -s, --scale 
           Scale length in mm [default: 648]

Running the gui

Calling the program by invoking gfret without any arguments will run the Gtk interface. Additionally, a .desktop file and icon are included, and can be used for launching the program from desktop menus or creating shortcuts.

Keybindings

| Key          | Action                        |
| ------------ | ----------------------------- |
| Ctrl/S       | save file                     |
| Ctrl/Shift/S | save file as                  |
| Ctrl/E       | open with an external program |
| Ctrl/O       | load a template from file     |
| Ctrl/Shift/P | open the `preferences` dialog |
| Ctrl/A       | open the `about` dialog       |
| Ctrl/Q       | quit the program              |

Templates

Along with the svg output, Gfret will save the specifications used to generate the rendering in a Toml file with it's name corresponding to the name of the svg file. These templates can be loaded later, either as an argument when invoking the program, in which case the output will be immediately generated, or else loaded from the Gui interface for further editing. This is useful for sharing a common scale among multiple designs to use as a starting point.

Configuration

On Unix systems the default configuration directory is ~/.config/gfret. Gfret will maintain a configuration file here in Toml format.

Note: The graphical interface has a preferences dialog and will take care of maintaining the preferences file for you. There will be no need to edit this file by hand in normal use.

Building

You will need a Rust toolchain installed, including cargo. Gtk+4x is also required.

cargo build --release

If desired, a release distribution can then be generated which will include the binary, svg and png icons, Unix man pages, XDG .desktop file and shell completions.

cargo xtask dist

Roadmap

Tags for this page

=> software
=> gfret
=> lutherie
=> rust
=> gtk

=> Home

All content for this site is licensed as CC BY-SA.

© 2022 by JeanG3nie

=> Finger | Contact

Proxy Information
Original URL
gemini://gemini.hitchhiker-linux.org/software/gfret.gmi
Status Code
Success (20)
Meta
text/gemini;lang=en-US
Capsule Response Time
585.086002 milliseconds
Gemini-to-HTML Time
0.939351 milliseconds

This content has been proxied by September (ba2dc).