Class GuitarDiagramComponent

java.lang.Object
java.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.jjazz.instrumentcomponents.guitardiagram.api.GuitarDiagramComponent
All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class GuitarDiagramComponent extends JPanel
Represent a guitar chord chart/diagram.
See Also:
  • Constructor Details

    • GuitarDiagramComponent

      public GuitarDiagramComponent()
    • GuitarDiagramComponent

      public GuitarDiagramComponent(TGChord chordModel, ChordSymbol cs)
      Parameters:
      chordModel - Can be null
      cs - Can be null
  • Method Details

    • getChordModel

      public TGChord getChordModel()
      Returns:
      the chordModel. Can be null.
    • getPreferredSize

      public Dimension getPreferredSize()
      Overrides:
      getPreferredSize in class JComponent
    • setChordModel

      public void setChordModel(TGChord chordModel)
      Parameters:
      chordModel - the chordModel to set. Can be null.
    • getNoteColor

      public Color getNoteColor()
    • setNoteColor

      public void setNoteColor(Color noteColor)
    • getTonicNoteColor

      public Color getTonicNoteColor()
    • setTonicNoteColor

      public void setTonicNoteColor(Color tonicNoteColor)
    • getFirstFretSpacing

      public float getFirstFretSpacing()
    • setFirstFretSpacing

      public void setFirstFretSpacing(float firstFretSpacing)
    • getFretSpacing

      public float getFretSpacing()
    • setFretSpacing

      public void setFretSpacing(float fretSpacing)
    • getStringSpacing

      public float getStringSpacing()
    • setStringSpacing

      public void setStringSpacing(float stringSpacing)
    • getNoteDiameter

      public float getNoteDiameter()
    • setNoteDiameter

      public void setNoteDiameter(float noteDiameter)
    • getLineWidth

      public float getLineWidth()
    • setLineWidth

      public void setLineWidth(float lineWidth)
    • getFirstFretFont

      public Font getFirstFretFont()
    • setFirstFretFont

      public void setFirstFretFont(Font firstFretFont)
    • paintComponent

      public void paintComponent(Graphics g)