summaryrefslogtreecommitdiff
path: root/scm/translation-functions.scm
diff options
context:
space:
mode:
Diffstat (limited to 'scm/translation-functions.scm')
-rw-r--r--scm/translation-functions.scm22
1 files changed, 15 insertions, 7 deletions
diff --git a/scm/translation-functions.scm b/scm/translation-functions.scm
index 22f8648c31..0ed0deff0a 100644
--- a/scm/translation-functions.scm
+++ b/scm/translation-functions.scm
@@ -427,13 +427,21 @@ the current tuning?"
(ly:warning (_ "No open string for pitch ~a")
pitch)))
;; here we handle assigned strings
- (let ((this-fret
- (calc-fret pitch string tuning))
- (handle-negative
- (ly:context-property context
- 'handleNegativeFrets
- 'recalculate)))
- (cond ((or (and (>= this-fret 0) (integer? this-fret))
+ (let* ((this-fret
+ (calc-fret pitch string tuning))
+ (possible-fret?
+ (and (>= this-fret 0)
+ (if (and
+ (ly:context-property
+ context 'supportNonIntegerFret #f)
+ (null? rest))
+ (integer? (truncate this-fret))
+ (integer? this-fret))))
+ (handle-negative
+ (ly:context-property context
+ 'handleNegativeFrets
+ 'recalculate)))
+ (cond ((or possible-fret?
(eq? handle-negative 'include))
(set-fret! pitch-entry string finger))
((eq? handle-negative 'recalculate)