Fretboard plugin

• Oct 8, 2019 - 10:03

Hello everyone!

A few days ago I have created a plugin that tries to implement a simple guitar fretboard tool for tablature input and visualization, similarly to the existing Piano keyboard tool or similar fretboard tools in other score editors. The result looks approximately like this (see the full screenshot here):

This plugin currently supports both visualizing the currently selected chord on the fretboard and doing note input by adding new chords (in Note Input mode) or editing existing chords in the tablature.

The project has largely been started to explore possibilities the of plugins framework in its current (as per 3.3 RC version) state and to figure out whether this framework is suitable to extend MuseScore user interface in some reasonable way. The answer seems to be mostly "yes", although the plugins framework lacks an access to some aspects of information about a score (like staff/instrument properties) and means to trigger most of GUI events (like viewport positioning and doing chords playback without entering Play mode).

So I hope this project will be useful both for users working on tablature scores and for other plugin developers trying to create something similar. Any feedback, both on this plugin and on similar GUI plugins development in general, would be greatly appreciated!

Here is the link to the plugin:
Source code:


To forward this comment :

IMHO, tooltips (or labels, sorry, I don't know how you define the difference) are missing currently. And I think the example of Guitar Pro (logically, it got the approval of the guitarists!) is the right approach.

That is to say: when the mouse hovers over a fret, the dot/note is drawn in light yellow/transparent - it provides you with the essential information -, before being validated by the click (and a brighter yellow).

gp.jpg THEN gp1.jpg
Also note that the name of the note (and its octave) is reported to the left of the fretboard. I don't know if this is also possible with the plugin - useful, but a bit less of a priority (for me).

In reply to by cadiz1

Maybe a small explanation you might benefit from:
A tooltip is a text that pops-up when "hoovering" over an object with your mouse.
Labels will always be visible (sometimes maybe they can be hidden by setting a selection checkbox, or similar method)....

Hi dmitrio

BIG Surprise !! THANK YOU SO MUCH :)
Working so well as far as I used.

One thing I was aware of ;
Translated word “frets” width is not wide enough to show in my language (Japanese).
Make it little wider ?
Thank you!

Attachment Size
fret.jpg 95.67 KB

Fantastic plugin. Thanks!
Currently, clicking on the fretboard to add a note gives audible feedback only for the first note.
Adding any subsequent notes on the same measure has no audible feedback.
In fact, as soon as there's one note in a measure, there won't be audible feedback when clicking any fret on the fretboard.

Fantastic plugin dmitrio.

I didn't know it was in active development. It is so good it inspired me to add some more features, like chord detection, interval names, notes being played by each finger and support for rootless chords and non played notes. Also, fixed some issues with the tunning detection and have some more ideas like laying out scales, chord extensions and modes.

Let me know if you are interested in the code and I can share it with you.

Thank you all for your feedback!

I have just uploaded a small update to this plugin. It mainly adds an ability to play a chord when adding a note to it so editing a score with a fretboard should no longer be in silence (this feature will work only since 3.3.4 version of MuseScore). Also there are some minor styling changes one of which should resolve the issue with Japanese translation reported by Kazuma Yamamoto. A full list of changes is available in the changelog.

The updated version is available on the project page (or with this direct link to the updated plugin).

I would also like to add labels for notes on the fretboard like @cadiz1 suggested. This has been implemented as a part of a pull request by gsc-dev (I guess, the author of this comment above), so I hope to be able to integrate at least some of the proposed changes soon.

In reply to by cadiz1

Thanks again and congratulations for this fretboard plugin. These "new" plugins are really fine and bring an undeniable added value to the program.
This makes me think again about this feature request (#153016: Ability to enter Tabs for diatonic fretted instruments) that has remained a dead letter (perhaps due to the difficulty of implementing it in the current code?), despite its interest and the many requests.
So, do you think it could be a good candidate for another specific plugin?

EDIT: for the record, there were for version 2, a few plugins related to this question, but which were really very limited and inconvenient. Ie:

In reply to by cadiz1

@cadiz1, that is a good question. Right now MuseScore strictly binds note pitch to tablature markings according to chromatic fretting law, and this is not something that can be overridden in plugins. So without changing MuseScore itself (and implementing a fully working support for diatonic fretting would indeed be not a trivial task) plugins can only emulate some of the desired properties of diatonic tablature. I can think of two options how to achieve something similar:
1) Draw tablature manually based on a pitched staff content. This seems to be something that is done by the plugins you listed above.
2) Use the existing tablature facility and change notes tuning to obtain the desired sound. Some tweaks could also be used to visually emulate unusual tablature markings like "6+" for dulcimer. This method has certain drawbacks (for example, notes would internally have wrong pitches so linkes staves would work incorrectly) but this would allow to make use of most of the existing features for tablature visual layout.

Both these approaches could probably be implemented in a non-interactive mode with plugins in MuseScore 2 as well. The new plugins possibilities allow to implement interactive editing of such a custom tablature, so I believe some version of such plugin that would be more convenient to use could indeed be implemented. The second approach (based on the existing tablature) should probably be not really difficult to implement within the Fretboard plugin so, as an experiment, I could try to add a support for diatonic fretting to this plugin. If you (or whoever would like to work with diatonically fretted instruments in MuseScore) find it a usable solution we could think on how to expand its possibilities further.

In reply to by dmitrio95

Thank you Dmitrio for looking into this question.
I must admit that I do not understand everything about the difference (and their result) between the two approaches.
Two simple thoughts:
The fact that it would not work with linked staves does not seem to me to be a crippling handicap. Would copying and pasting it into another staff work, with the right display of course?
Then, it seems to me that it would be expected, by default, that the tablature would only contain three lines/strings? So rather than a guitar fretboard that should be reduced? (sorry, it's not very clear to me)

In any case, the really important and crucial point is to make sure that the entry of this or that fret (even the special fret 6+) corresponds to the right sound, and to the right display of the notes in standard notation.
And vice versa (if possible?): this or that standard note should correspond to the right fret and sound on this type of instrument.

In reply to by cadiz1

With the second method copying and pasting to a normal staff also wouldn't work as it would be impossible currently to convince MuseScore to assign pitches to notes in a tablature not following a chromatic fretting law. So it looks like it is better currently to develop such a plugin based on the existing MuseScore 2 plugins which draw the needed tablature notation themselves. Anyway, a possibility to edit such a tablature in an interactive way rather than having to manually run a plugin to convert the existing notation to a tablature should make it more convenient to use.

Another small update: I have just uploaded a version with note labels and semi-transparent note markers on fret hovering. I am not sure about their visual appearance, so please let me know if it would be better to change it or make it customizable. Anyway, they should be already useful as they are.

In reply to by dmitrio95

wooow… it’s super ! Thank you so much for labeling notes. very very useful :D

Two things I’m aware of ( well, I don’t mind, though )
>Accidental note’s names are extending out beyond a red circle
>Labeling color is similar to fretboard

But again, Thank you so much for labeling notes!

Attachment Size
fret.jpg 9.09 KB

In reply to by kazuma yamamoto

Wow, too! Thanks Dmitri. Really helpful, and as expected. Also, I noticed the same color, or lack of contrast between the fingerboard itself and the background of the labeling notes. Since we have to go out and come up with some ideas, maybe a faded/washed pink? (but I haven't tested it, so there's no certainty about what it will actually look like).) So much the better if there are other proposals.

In reply to by cadiz1

Actually if needed I could make the color customizable so users could define the color of their own preference. Still I also like this scheme with pink color so if it (or maybe some other similar color?) suits everyone else I could just make the change to the "main" version of plugin.

In reply to by dmitrio95

I had tested this plugin, but not yet in a multi-voice context (which is almost the majority of my use cases)
Unfortunately, there is a problem with the voice change.
For example, pictures below: I'm trying, in voice 4 (but it's the same thing with voice 2, etc.), to enter a C half note on the first beat. When I click this C on fretboard (fifth string, third fret), I get a failure and the warning "String-above command not valid in current state".

Moreover, it is very difficult, and unexpected, to get rid of this dialog. From what I observe, I have to click ten times (why ten, or eleven?) on the closing cross so that the window finally disappears. And surprise, at that moment, the C is entered?!

EDIT: And for the pink labeling, I observe that we are very close to the color default of voice 4 in the program. So, somehow, it's coherent.

essai basse Do.jpg
commande string above.jpg

Do you still have an unanswered question? Please log in first to post your question.