ChordDefinitionView
struct ChordDefinitionView: View
SwiftUI View for a ChordDefinition
-
The chord to display in a diagram
Declaration
Swift
let chord: ChordDefinition -
The width of the diagram
Declaration
Swift
let width: Double -
The height of the grid
Declaration
Swift
let gridHeight: Double -
The height of a line
Declaration
Swift
let lineHeight: Double -
The width of a cell
Declaration
Swift
let cellWidth: Double -
The horizontal padding
Declaration
Swift
let horizontalPadding: Double -
The frets of the chord; adjusted for left-handed if needed
Declaration
Swift
let frets: [Int] -
The fingers of the chord; adjusted for left-handed if needed
Declaration
Swift
let fingers: [Int] -
The offset for an instrument with less than 6 strings
Note
Used to give a barre some paddingDeclaration
Swift
let xOffset: Double -
The display options for the diagram
Declaration
Swift
let diagramDisplayOptions: AppSettings.DiagramDisplayOptions -
Init the
ViewDeclaration
Swift
init(chord: ChordDefinition, width: Double, settings: AppSettings.Song)Parameters
chordThe
ChordDefinitionwidthThe width of the diagram
settingsThe settings of the song
-
The body of the
ViewDeclaration
Swift
var body: some View
-
The diagram
ViewDeclaration
Swift
var diagram: some View
-
The top bar
ViewDeclaration
Swift
var topBar: some View
-
The grid
ViewDeclaration
Swift
var grid: some View
-
The frets grid
ViewDeclaration
Swift
var fretsGrid: some View
-
The barres grid
ViewDeclaration
Swift
var barresGrid: some View
-
The notes
ViewDeclaration
Swift
var notesBar: some View
-
The
See moreShapeof the gridDeclaration
Swift
struct GridShape: Shape
View on GitHub