Expand description
ChordPro parser, AST definitions, and transforms.
Re-exports§
pub use abc_importer::convert_abc;pub use chord::Accidental;pub use chord::ChordDetail;pub use chord::ChordQuality;pub use chord::Note;pub use chord::parse_chord;pub use chord_diagram::canonical_chord_name;pub use chord_diagram::resolve_diagrams_instrument;pub use formatter::FormatOptions;pub use formatter::format as format_chordpro;pub use heuristic::InputFormat;pub use heuristic::PlainTextImporter;pub use heuristic::convert_plain_text;pub use heuristic::detect_format;pub use heuristic::song_to_chordpro;pub use lexer::Lexer;pub use parser::MultiParseResult;pub use parser::ParseError;pub use parser::ParseOptions;pub use parser::ParseResult;pub use parser::Parser;pub use parser::parse;pub use parser::parse_image_attributes;pub use parser::parse_lenient;pub use parser::parse_lenient_with_options;pub use parser::parse_multi;pub use parser::parse_multi_lenient;pub use parser::parse_multi_lenient_with_options;pub use parser::parse_multi_with_options;pub use parser::parse_with_options;pub use render_result::RenderResult;pub use token::Position;pub use token::Span;pub use token::Token;pub use token::TokenKind;pub use voicings::guitar_voicing;pub use voicings::keyboard_voicing;pub use voicings::lookup_diagram;pub use voicings::lookup_keyboard_voicing;pub use voicings::ukulele_voicing;
Modules§
- abc_
importer - ABC notation → ChordPro converter.
- ast
- Abstract Syntax Tree (AST) definitions for the ChordPro format.
- chord
- Chord notation parser for structured chord analysis.
- chord_
diagram - SVG chord diagram generator.
- config
- Hierarchical configuration loading for ChordPro.
- escape
- XML/HTML character escaping utilities.
- external_
tool - Utilities for detecting and invoking external tools.
- formatter
- ChordPro source formatter.
- grid
- Structured tokeniser for
{start_of_grid}body lines. - heuristic
- Heuristic plain-text chord+lyrics importer.
- image_
path - Shared image-path validation utilities.
- inline_
markup - Inline markup parser for ChordPro lyrics text.
- json
- Zero-dependency JSON serializer for the ChordPro AST.
- lexer
- Single-pass lexer for ChordPro documents.
- notation
- Notation block kinds recognised by the text and PDF renderers.
- parser
- Parser that transforms a token stream into a ChordPro AST.
- render_
result - Structured render result type for capturing warnings during rendering, plus the canonical warning-accumulation helpers used by every renderer.
- rrjson
- Really Relaxed JSON (RRJSON) parser for ChordPro configuration files.
- selector
- Selector resolution for conditional directives.
- token
- Token and span types for the ChordPro lexer.
- transpose
- Chord transposition — shift all chords in a song by N semitones.
- typography
- Music-typography helpers shared by every renderer
(
chordsketch-render-text,chordsketch-render-html,chordsketch-render-pdf, plus the React JSX walker sister- site in@chordsketch/react). - voicings
- Built-in chord voicing database for guitar, ukulele, charango, and piano/keyboard.
Functions§
- capitalize
- Capitalize the first character of a string.
- version
- Returns the library version.