예제 #1
0
 def setInitialPitch(self, pitch):
     if not self.language:
         self.setLanguage("nederlands")
     if not self.initialPitchSet:
         index = self.fromPitch.findText(pitch.output(self.language))
         if index != -1:
             self.fromPitch.setCurrentIndex(index)
             self.toPitch.setCurrentIndex(index)
             self.initialPitchSet = True
예제 #2
0
 def output(self, relativemode=False, language='nederlands'):
     if relativemode:
         pitch = self._pitch.copy()
         pitch.makeRelative(Note.LastPitch)
         Note.LastPitch.note = self._pitch.note
         Note.LastPitch.octave = self._pitch.octave
     else:
         pitch = self._pitch
     # also octavecheck if Shift is held
     return pitch.output(language) + (('='+ly.pitch.octaveToString(self._pitch.octave)) if QApplication.keyboardModifiers() & Qt.SHIFT else '')
예제 #3
0
 def output(self, relativemode=False, language='nederlands'):
     if relativemode:
         pitch = self._pitch.copy()
         pitch.makeRelative(Note.LastPitch)
         Note.LastPitch.note = self._pitch.note
         Note.LastPitch.octave = self._pitch.octave
     else:
         pitch = self._pitch
     # also octavecheck if Shift is held
     return pitch.output(language) + (
         ('=' + ly.pitch.octaveToString(self._pitch.octave))
         if QApplication.keyboardModifiers() & Qt.SHIFT else '')