com.softsynth.jmsl.score.justify
Class NoteJustifier

java.lang.Object
  extended by com.softsynth.jmsl.score.justify.NoteJustifier

public class NoteJustifier
extends java.lang.Object

Prepare a Measure of Notes for Justifier, pass to Justifer and justify them.
Justification algorithm from D. Blostein and L. Haken, "Justification of Printed Music," Communications of the ACM, Vol. 34, No. 3, March 1991, pp. 88-99.

Author:
Nick Didkovsky, (c) 2005 Nick Didkovsky, didkovn@mail.rockefeller.edu

Field Summary
static double MIN_SPACE_A_NOTE_NEEDS
           
 
Constructor Summary
NoteJustifier(Measure measure)
           
 
Method Summary
static double getTextualSpacingAfterNote(Note note)
           
static double getTextualSpacingBeforeNote(Note note)
           
 void justify()
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

MIN_SPACE_A_NOTE_NEEDS

public static final double MIN_SPACE_A_NOTE_NEEDS
See Also:
Constant Field Values
Constructor Detail

NoteJustifier

public NoteJustifier(Measure measure)
Method Detail

justify

public void justify()

getTextualSpacingAfterNote

public static double getTextualSpacingAfterNote(Note note)
Returns:
spacing required AFTER notehead (like for dot or double dot). Not related to duration. Just textual, like laying out a letter of an alphabet

getTextualSpacingBeforeNote

public static double getTextualSpacingBeforeNote(Note note)
Returns:
spacing required BEFORE notehead (like for accidental)