On Mon, 2005-08-08 at 09:14 +0200, Guillaume Laurent wrote: > On Monday 08 August 2005 00:30, Stephen Torri wrote: > > On Sun, 2005-08-07 at 23:50 +0200, Guillaume Laurent wrote: > > > That's all very nice, but just what exactly are you using this library > > > for ? What are you parsing with it ? > > > > Well when I posted to this mailing list that if a user wanted to add new > > chord files to Rosegarden that they would be creating an XML file. That > > drew the response that XML is not meant for humans to be creating. So I > > changed it so that I had a text file format, see example below, that was > > easier to read. > > How about this instead : > > A o222o > AMaj7 o212o > > Trivial to parse (the 'AMaj7' too, we have code for that), much faster to > write, instantly understandable by every guitar player of the face of the > earth. > > Your format is way too verbose, looks like a programming language and is, in > fact XML in disguise. It's not any easier to write than XML, actually it's > probably harder because of all the ';'. If it's supposed to be > human-writable, it should be as simple as possible, and the parser should be > as forgiving as possible, which can't be done with a format as heavily > structured as yours. > > Sorry to send you back to the drawing board again, but had you discussed the > format here before starting to code it, we'd have pointed out the problem > right away.
Emm... if we had been consulted .. Ok. I will say this troubled me reading this and I will leave it at that. A few observations about the condensed format. While it is indeed condense I do t find it roughly understandable from a guitarist point of view I am lost from a programmers point of view. 1. How do I parse it? A ChordName object, used as the central means of sorting chords, has a scale (e.g. A), a modifier (e.g. Major) and a suffix (e.g. 7th). 2. If I want tell a guitarist to use a barre instead of a series of notes what do I use? While I appreciate your input into this I personally feel its too condense. As Chris said "Are there no pre-existing chord formats available?" (my paraphrase). Stephen
signature.asc
Description: This is a digitally signed message part