Package com.softsynth.jmsl.score
Class ScoreControlPanel
java.lang.Object
com.softsynth.jmsl.view.PVPanelAdapter
com.softsynth.jmsl.score.ScoreControlPanel
- All Implemented Interfaces:
PVComponent,PVPanel,PVScrollbarListener,Playable,MeasureMetronomeListener,ScoreLayoutListener,java.awt.event.ActionListener,java.awt.event.ItemListener,java.util.EventListener
public class ScoreControlPanel extends PVPanelAdapter implements Playable, PVScrollbarListener, java.awt.event.ActionListener, java.awt.event.ItemListener, MeasureMetronomeListener, ScoreLayoutListener
ScoreControlPanel
Control zoom and measure #
JMSL Notation Project
Control zoom and measure #
JMSL Notation Project
- Author:
- Nick Didkovsky , copyright 2000 Nick Didkovsky
-
Field Summary
Fields Modifier and Type Field Description static java.lang.Stringcopyright -
Constructor Summary
Constructors Constructor Description ScoreControlPanel(Score score) -
Method Summary
Modifier and Type Method Description voidactionPerformed(java.awt.event.ActionEvent e)voidaddZoomListener(ZoomListener zl)voidclearSectionChoice()voidfinish()calls finishAll() on scorecollection, sets gui buttonsScoreSectiongetCurrentSection()booleangetLoopState()intgetMyScoreControlPanelIndex()voidhandleMeasure()voidhandleZoom()voiditemStateChanged(java.awt.event.ItemEvent e)voidlaunch(double time, int startMeasure, int endMeasure, boolean useButton)Launch the score at specified time, starting and ending at specified measuresvoidlaunchSection(double playTime, boolean useButton)launch current section.static voidmain(java.lang.String[] args)voidnotifyMeasureBeat(int measure, int beat, int beatsInMeasure)Display measure and beat in Label, notified by Score's Measure's MeasureMetronomevoidnotifyScoreLayout(Score score, int startingMeasure, int numMeasuresInLayout)voidnotifyScrollbarValueChanged(PVScrollbar jsb)voidnotifySectionUpdate(ScoreSection section)doubleplay(double time, Composable parent)Result of collection finishingvoidsetLoop(boolean flag)Set internal flag to loop playback or not.voidsetMax(int max)voidsetMeasureBar(int measureNumber)voidsetNoteFlash(boolean f)voidsetSectionName(int sectionIndex, java.lang.String sectionName)voidsetZoom(double z)java.lang.StringtoString()Methods inherited from class com.softsynth.jmsl.view.PVPanelAdapter
add, add, addKeyListener, equals, getBackground, getBounds, getComponent, getFont, getLocation, getParent, hashCode, isEnabled, remove, removeAll, removeKeyListener, setBackground, setEnabled, setFont, setLayout, setLocation, setVisible, validateMethods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
-
Field Details
-
copyright
public static final java.lang.String copyright- See Also:
- Constant Field Values
-
-
Constructor Details
-
ScoreControlPanel
-
-
Method Details
-
getMyScoreControlPanelIndex
public int getMyScoreControlPanelIndex() -
setMax
public void setMax(int max) -
addZoomListener
-
handleZoom
public void handleZoom() -
setZoom
public void setZoom(double z) -
notifyScoreLayout
- Specified by:
notifyScoreLayoutin interfaceScoreLayoutListener
-
handleMeasure
public void handleMeasure() -
setMeasureBar
public void setMeasureBar(int measureNumber) -
notifyScrollbarValueChanged
- Specified by:
notifyScrollbarValueChangedin interfacePVScrollbarListener
-
notifySectionUpdate
-
getCurrentSection
-
setNoteFlash
public void setNoteFlash(boolean f) -
itemStateChanged
public void itemStateChanged(java.awt.event.ItemEvent e)- Specified by:
itemStateChangedin interfacejava.awt.event.ItemListener
-
getLoopState
public boolean getLoopState() -
launch
public void launch(double time, int startMeasure, int endMeasure, boolean useButton)Launch the score at specified time, starting and ending at specified measures -
launchSection
public void launchSection(double playTime, boolean useButton)launch current section. Convenience call to launch(playTime, getCurrentSection().getStart(),getCurrentSection().getEnd(), useButton ) -
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener
-
setLoop
public void setLoop(boolean flag)Set internal flag to loop playback or not. Does not update checkbox -
finish
public void finish()calls finishAll() on scorecollection, sets gui buttons -
play
Result of collection finishing -
notifyMeasureBeat
public void notifyMeasureBeat(int measure, int beat, int beatsInMeasure)Display measure and beat in Label, notified by Score's Measure's MeasureMetronome- Specified by:
notifyMeasureBeatin interfaceMeasureMetronomeListener
-
clearSectionChoice
public void clearSectionChoice() -
setSectionName
public void setSectionName(int sectionIndex, java.lang.String sectionName) -
toString
public java.lang.String toString()- Overrides:
toStringin classPVPanelAdapter
-
main
public static void main(java.lang.String[] args)
-