• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
tabulature text size in chordpro file
#1
Is it possible to decrease the text size only for a tablature in a chrodpro file without changing the rest of the text?
Reply
#2
Unfortunately, this is not currently supported. The chord pro spec lists a couple of commands that could be utilized for this, namely {textsize:fontsize} and {chordsize:fontsize}. I will go ahead and add proper support for these as well as a new one specifically for tabs, which will be {tabsize:fontsize}. For the sake of staying consistent with the spec, {textsize:fontsize} will modify the font size for both lyrics and tablature. This means you could adjust the font size before a tab and then after, or you could just utilize the new {tabsize:fontsize} directive. The advantage of the former approach is that your files would be properly supported by other programs.

Mike
Reply
#3
I was just going back through feature requests, and noticed that I had a requester for additional settings to set the size for all tab and chorus sections, so I will be adding sliders for these that will show up when the advanced settings slider is on. It will still be possible to use the keywords to drive these if desired.
Reply
#4
Without conflicting with the ChordPro standard the font settings could be handled by MSP. Many ChordPro apps do it this way.
I really would appreciate:
- being able to specify independent settings for {subtitle:, {comment:, {comment_italic:
  (different to lyrics and chords settings)
- being able to specify font colour, background colour, bold, italic independently for all types
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 2004
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#5
As maintainer of the original Chord program (now called Chordii) and keeper of the ChordPro standard, I've been thinking about this for a long while now. And the answer is "Yes, it is highly desired" and "No, there's no end to what would be needed."
So I am considering a different approach.
We have a mechanism that allows flexible formatting of text and other things: HTML. With CSS, you can control everything to the level of precision you need. The only thing required is a ChordPro processing tool that produces HTML. This is actually quite simple and I have an experimental version that produces the following HTML:

Code:
<div class="title">Everybody Hurts</div>
<div class="subtitle">REM</div>
<div class="tab">...</div>
<div class="verse">
<table class="songline">
 <tr class="chords">
   <td>D </td><td>G </td><td>D </td><td>G </td><td>D </td>
 </tr>
 <tr class="lyrics">
   <td>When your day is </td><td>long and the </td><td>night, the night is </td><td>yours a</td><td>lone</td>
 </tr>
</table>
<table class="songline">
 <tr class="chords">
   <td>D </td><td>G </td><td>D </td><td>G </td>
 </tr>
 <tr class="lyrics">
   <td>When you’re sure you’ve had e</td><td>nough of this </td><td>life, well </td><td>hang on</td>
 </tr>
</table>
<div>

There are additional <div> classes for chorus, comments, and so on. You can view the resultant HTML in a browser, and tools like weasyprint can be used to generate good looking PDF pages. The CSS provides styles for screen and print media.

I think this approach has a much greater future than trying to crap in all kinds of {commentfont} {commentsize} {tabfont} and so on.

What do you think?
Johan
www.johanvromans.nlwww.hetgeluidvanseptember.nlwww.howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 11.0, AirTurn Duo & Digit.
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Reply
#6
I think the HTML approach is certainly interesting and would provide an excellent amount of flexibility with the formatting of files. As far as MS Pro, I could probably leverage the WebView component which can render a web page, and just provide it the file instead of needing to write my own renderer. One nice thing about the ChordPro format is that it's relatively simple to view and edit. Some users probably wouldn't like having to modify HTML. It would also probably mean that I wouldn't be able to provide settings to modify the way the file is displayed, as I wouldn't be rendering it myself. I would need to provide an editor of sorts for the HTML I suppose.

itsme - I will try to add support for all that, but it's going to be stuff you have to insert in the chord pro file itself (versus something you set in MobileSheets). In order to support all that, I'm either going to need to add support for tons of new directives, or I'm going to have to provide a directive that takes multiple inputs, such as which font type is being modified (lyrics, chords, tabs, etc), the color to use, the size, etc.
Reply
#7
Mike, I suspect a little misunderstanding -- it's still the familiar ChordPro file that is maintained. The renderer converts it to HTML, and then uses a HTML renderer for the final result. Users would not edit the HTML directly, although they may need to edit the CSS (or supply a custom CSS). But a couple of standard CSS files would suffice for most needs, while the power users can change the CSS at will.
Johan
www.johanvromans.nlwww.hetgeluidvanseptember.nlwww.howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 11.0, AirTurn Duo & Digit.
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Reply
#8
I understand, so I would need to implement the conversion from chord pro to HTML.
Reply
#9
Only if you'd want to do formatting with extreme flexibility/customizability.
IMHO, the way MSPro currently handles formatting ChordPro files is sufficient for the purposes MSPro is intended for. MSPro is not a typesetter, it should format the songs for maximum readability on a tablet screen. Yes, it would be nice to have some additional settings for tab size and such but I don't think much more would be needed. Of course, users will ask for more, that's human Smile .
Just like nicely formatted PDF scores, with heading and footers and so on. With MSPro, you apply cropping to get rid of the frills and obtain maximum readability.
Johan
www.johanvromans.nlwww.hetgeluidvanseptember.nlwww.howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 11.0, AirTurn Duo & Digit.
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Reply
#10
I really miss the feature to change the formatting of just a part of a line, e.g. make a single word within a lyrics line bold or underlined, highlight a certain chord or such. Could that css approach allow that without giving up compatibility to standard ChordPro?
Any plans by now to implement something like that?
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 2004
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#11
Currently, there are no plans for in-line markup. It would be rather straightforward to add simple markdown-style markup for bold, underline and italic in the lyrics.
Highlighting individual chords would be harder.
But in any case I'd like to avoid ChordPro becoming some kind of bloated XML, and Chordii cs. becoming typesetter engines. Simplicity is the key.
Johan
www.johanvromans.nlwww.hetgeluidvanseptember.nlwww.howsagoin.nl
Samsung Galaxy Note S7FE (T733) 12.4", Android 11.0, AirTurn Duo & Digit.
Samsung Galaxy Note S4 (T830) 10.5", Android 10.0 (backup).
Samsung A3 (A320FL), Android 8.0.0 (emergency).
Reply


Digg   Delicious   Reddit   Facebook   Twitter   StumbleUpon  


Users browsing this thread:
3 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2021 MyBB Group.