Package com.softsynth.jmsl.score
Class ScoreEditPanel
java.lang.Object
com.softsynth.jmsl.view.PVPanelAdapter
com.softsynth.jmsl.score.ScoreEditPanel
- All Implemented Interfaces:
PVComponent
,PVPanel
,EditStateProvider
,NumTracksPerStaffChangedListener
,java.awt.event.ItemListener
,java.util.EventListener
public class ScoreEditPanel extends PVPanelAdapter implements java.awt.event.ItemListener, EditStateProvider, NumTracksPerStaffChangedListener
ScoreEditPanel
GUI Interface for edit functions
JMSL Notation Project
GUI Interface for edit functions
JMSL Notation Project
- Author:
- Nick Didkovsky, copyright 2000 Nick Didkovsky
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
copyright
-
Constructor Summary
Constructors Constructor Description ScoreEditPanel(Score score)
-
Method Summary
Modifier and Type Method Description void
addEditStateListener(EditStateListener editStateListener)
int
getAccidental()
int
getActiveTrackIndex()
int
getDots()
int
getDuration()
int
getEditMode()
boolean
getNoteElseRest()
int
getTuplet()
void
itemStateChanged(java.awt.event.ItemEvent e)
static void
main(java.lang.String[] args)
void
notifyNumTracksPerStaff(Score score)
notified by Score when numtracks per staff changesvoid
setDuration(int durCode)
index of selected duration 0..7Methods 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, toString, validate
Methods 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
-
ScoreEditPanel
-
-
Method Details
-
addEditStateListener
-
getEditMode
public int getEditMode()- Specified by:
getEditMode
in interfaceEditStateProvider
- Returns:
- edit mode (cursor mode or insert mode)
-
getDuration
public int getDuration()- Specified by:
getDuration
in interfaceEditStateProvider
- Returns:
- index of selected duration 0..7
-
setDuration
public void setDuration(int durCode)index of selected duration 0..7 -
getTuplet
public int getTuplet()- Specified by:
getTuplet
in interfaceEditStateProvider
- Returns:
- selected tuplet value
-
getAccidental
public int getAccidental()- Specified by:
getAccidental
in interfaceEditStateProvider
- Returns:
- selected accidental value: Note.ACC_NONE, Note.ACC_SHARP, Note.ACC_FLAT
-
getDots
public int getDots()- Specified by:
getDots
in interfaceEditStateProvider
- Returns:
- selected number of dots 0, 1, or 2
-
getNoteElseRest
public boolean getNoteElseRest()- Specified by:
getNoteElseRest
in interfaceEditStateProvider
- Returns:
- true if note selected, false if rest selected
-
itemStateChanged
public void itemStateChanged(java.awt.event.ItemEvent e)- Specified by:
itemStateChanged
in interfacejava.awt.event.ItemListener
-
main
public static void main(java.lang.String[] args) -
getActiveTrackIndex
public int getActiveTrackIndex()- Specified by:
getActiveTrackIndex
in interfaceEditStateProvider
- Returns:
- Returns the activeTrackIndex.
-
notifyNumTracksPerStaff
notified by Score when numtracks per staff changes- Specified by:
notifyNumTracksPerStaff
in interfaceNumTracksPerStaffChangedListener
-