OpenLyrics xml including OpenLP specifics

Bug #745636 reported by Jonathan Corwin on 2011-03-30
This bug affects 2 people
Affects Status Importance Assigned to Milestone

Bug Description

I'll raise this bug here, since we're going to have to do something anyway in OpenLP, but it might need to lead to a wider discussion which would need to spill over into the OpenLyrics group ( because we may need to extend the schema.

We're currently exporting tags like {r} and potentially [---] into OpenLyrics XML. We can't do this because other software using will just blindly display this as-is and it will look silly.

Raoul has suggested stripping it, which from the current OpenLyrics point of view is the correct action to take. The problem is, if I want to transfer some of my nicely coloured in songs from one V2 installation to another, and I take the Export Songs route, I'm going to be a little upset that it hasn't taken my {formatting} with it.

Therefore we are going to either need to provide a specific v2 format export which keeps the tags, or we're going to have to suggest to the OpenLyrics group that we can have some form of tag that allows to embed application specific information within the song. e.g. <bespoke app="openlp">{r}</bespoke>My Red Text<bespoke app="openlp">{/r}</bespoke>. Any program would need to check whether the app is them, and if not just ignore the tag and it's contents.

Another option is suggest that OpenLyrics allows strict XHTML to be embedded, and so we just expand the tags and output the expanded information. Collapse again on import if a suitable tag value matches.
However when you have end users entering {r}'s but no {/r}'s or defining their own tags, this is going to be difficult, to enforce.

I think we also need to request a tag for suggested slide break (i.e. try and keep the text on one slide, but if you can't, this is where you should break). e.g. <break suggested="true" />. One for mandatory verse break would be good too <break />, but we already have v1a v1b in OpenLyrics, which I can't say I'm a big fan of since I feel <verse> should ideally contain a whole verse!
Looking at the schema, it could perhaps be an attribute on <line>, e.g. <line suggestedBreak="true"> and <line break="true">.

Related branches

Changed in openlp:
status: New → Confirmed
Andreas Preikschat (googol) wrote :

I don't think we'll be able to tackle this one before beta 2.

Changed in openlp:
milestone: 1.9.6 → 1.9.7
Andreas Preikschat (googol) wrote :

Increased priority, because it affects a core part of our #1 plugin and we are in beta stage.

Changed in openlp:
importance: Medium → High
matysek (mzibricky) wrote :

I updated the openlyrics schema in relaxng repository with the syntax as discussed on openlyrics mailing list. You should be now able to validate openlyrics format with new syntax when working on it in openlp.

You can get the openlyrics repo by command:

hg clone openlyrics

See files:
  example_format.xml - example containing new syntax
  openlyrics_schema.rng - xml schema extended with new syntax - script to validate openlyrics xml structure

It should help you with development. I'm going to update doc and make new release of openlyrics in following weeks.

Changed in openlp:
assignee: nobody → Andreas Preikschat (googol)
status: Confirmed → In Progress
matysek (mzibricky) wrote :

Merge request to include optional line break:

Andreas Preikschat (googol) wrote :

I started on this one (optional page brake is implemented), matysek is going to take over.

Changed in openlp:
assignee: Andreas Preikschat (googol) → matysek (mzibricky)
Andreas Preikschat (googol) wrote :

I adapted the code to cope with temporary tags. Temporary tags are not saved to the config unless the user saves the tag himself.

matysek (mzibricky) wrote :

I think I should do the following:

file: plugins/songs/lib/

- _process_lyrics(): add formating tags to parsed lyrics
- song_to_xml: append formatting tags to OpenLyrics xml (<format> section and <lyrics> section)

matysek (mzibricky) wrote :
Changed in openlp:
status: In Progress → Fix Committed
Changed in openlp:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.