ugsEditorPlus.reformat Class
Item Index
Methods
countChords
-
words
Looks for supported chords.
Parameters:
-
words
Array of words
Returns:
[int] number found
hasChords
()
Bool
TRUE if one or more chord lines detected
Returns:
isTabBlock
-
lines
-
index
TRUE if we can make a Tab block using this and the following 3 linrd (we need a set of four tab lines followed by a non-tab line)
Parameters:
-
lines
Array of Lines -
index
Intcurrent line's index within line array
Returns:
[bool]
merge
-
lines
Return merged song -- chords embedded within lyrics
Parameters:
-
lines
Array of Lines
Returns:
[string]
mergeLines
-
chordLine
-
lyricsLine
Return a single line
Parameters:
-
chordLine
Stringthe line containing the chord names
-
lyricsLine
Stringthe line of lyrics
Returns:
[string] merged lines
read
-
text
Accepts a text block
Parameters:
-
text
Stringstring RAW song
Returns:
run
-
text
Accepts a text block, returns "ChordPro" text block with chord lines merged into lyric lines with chords enclosed in square-brackets (i.e. [Cdim])
Parameters:
-
text
Stringsongstring
Returns:
ChordPro format text block
toLineType
-
line
Guesses as to the line's tyupe --
Parameters:
-
line
Line
Returns:
wrapChords
-
chordLine
Wraps the words on the line within square brackets " C D " is returned as "[C] [D]"
Parameters:
-
chordLine
Stringthe line containing the chord names
Returns:
[string] each word of input line gets bracketed
Properties
_enums
Unknown
private
_public
JsonObject
attach public members to this object