• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Problem with scaling and lyrics font in abc files
#1
Hi. These issues have come up as differences between two platforms.

I've been using the ipad air 13" and I'm very happy with it. However, I found out through this forum that a couple of new android tablets are now available that are very close to a "piece-of-paper" aspect ratio, and inexpensive!

So I decided to try the Teclast Artpad Pro 12.7 (with Android 15) as a second device. Physically, they are the same size, although the actual space for the music is somehow different, slightly smaller, but very close.

I wanted to explore using the two devices in book mode, but here, I've run into a problem. Pdfs and image files are fine, but I've been changing as many songs as I can into abc lead sheets.

Here's the info I have at the beginning of each file (all created on the ipad):
%%scale 1
%%staffscale 1.5
%%stretchlast
%%titlefont Helvetica-Bold 28
%%subtitlefont Helvetica 20
%%composerfont Helvetica 20
%%tempofont Helvetica 18
%%annotationfont musejazztext 12
%%repeatfont musejazztext 16
%%gchordfont musejazztext 15
%%vocalfont condensed 20
(I have other settings, but not relative to this post.)

(This looks best on the ipad with a nice readable lead line and large enough lyrics to see from the piano music stand. I adjust the page scale setting, per song, sometimes smaller, to fit a song on one page if it's got only one or two lines on p. 2.)

On the android version, the scaling is way off (zoomed in more). I discovered I can reduce the page scaling in the abc settings and not have to change the code. That way it's got the same number of lines as the ipad, per page. Note, this only works on .abc files. It's a problem on my .cho files where I'm showing the leadsheet with start and end tags, and then the chordpro chart after it. I don't think there's a way to adjust the page scaling independently apart from changing the code. 

I guess I shouldn't be surprised at how different the same song looks on each device. Somehow %%pagescale 1.5 does things differently on each one.

I'm not sure how to edit these files so they can be read by both platforms, and look similar enough to use the book feature. And if I edit them independently, how does that affect syncing and using book mode for seeing two pages?

Now to the lyrics: When I ported my database to the android, the lyrics are in the wrong font.

The jazz font (for chords), Helvetica-Bold (the title), and regular Helvetica for the composer are all rendering the same.

The problem is the vocalfont "condensed". This is one of the default fonts and I like it best for the lyrics, the most readable, for me. 

On the android, all lyrics are rendering as a serif font, like Times. This is just in the abc portion. The chordpro font in the advanced settings is set to system default. So they look alike.

I checked on the android, and in looking at the font options in the annotation overlay, the same options exist for both platforms, including Condensed. Even if it's a slightly different looking font than on the ipad, I'm pretty sure it shouldn't be using a serif font, which is much harder for me to read while performing.

On the ipad, I tried changing the vocalfont to Helvetica, but it looks different, shorter and wider. Condensed definitely looks better.

I attached 2 pics, showing each. The underlying code is identical. I changed the abcsettings on the android to get a similar look to the ipad, sizewise.

Ipad:
margins: 30, 0, 30, 0
pagescale: .99

android:
margins: 20, 0, 20, 0 
pagesacle: .85

I haven't attempted the book mode yet. I want to iron out some of these issues first.

Thanks, as always, for your help, Mike.


Attached Files Thumbnail(s)
       
Reply
#2
Did you try "Fixed Page Size"? To do so, open a ChordPro or ABC file and open "Set Page Size" in the "A" menu top right. It's recommended to use the smallest Width / Height of your devices in the display ratio you want.

Regarding fonts: herehttps://www.zubersoft.com/mobilesheets/forum/thread-11444.html is a list of the fonts that are integrated in MobileSheets.
@Mike: is this list still correct or did you change something recently? Jazz and Campania are missing. I know Jazz is MuseJazz Text, what's Campania? Campania seems to be missing in MobileSheets for Windows, see below. _DELL2024 (W11) and _Boox (eink) are different.

I wrote test files to investigate the tracking (Laufweite) of the included fonts. To reproduce my results import and open the ChordPro files and choose the specified fonts in "Advanced Settings", use the same font size, I used font size 36 for all the fonts.
               


Attached Files
.pro   FontTest1.pro (Size: 671 bytes / Downloads: 2)
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#3
Here's the missing FontTest2.pro, the forum allows not more than 5 attachment files per post


Attached Files
.pro   FontTest2.pro (Size: 443 bytes / Downloads: 5)
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#4
https://github.com/MarcSabatella/Campania
Is it required to install this font on windows devices? I understood that the fonts that can be selected in "Advanced Settings" are bundled with MobileSheets.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#5
I tried to do something similar with .ABC instead of ChordPro to investigate how the naming of the fonts works in ABC. I failed badly, maybe because of my lack of ABC knowledge.
Can anybody help?


Attached Files Thumbnail(s)
   

.abc   FontTest3.abc (Size: 1.31 KB / Downloads: 0)
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#6
Hi Itsme, 

The mention about fixed page size was very helpful. It gave me the clue. I'll detail my process in case it helps someone else.

Before making adjustments, I made sure all settings in the advanced settings for chordpro songs, were exactly alike on the two devices. (They were, because I had loaded a backup from the ipad, to the new device.) 

One other thing to note, is that I have the text for the device in "make bigger or smaller" scale up one notch. That probably impacts the other things that I changed. ( I also have the ipad set to display larger text, as well.)

For the record, 
The ipad air 13" is a 4:3 ratio (1.33) 2732×2048 with a pixel density of 264.
The ArtPad Pro 12.7 is a 7:5 ration (1.36) 2176x1600, density 213.

Searching the internet, I found the information about the aspect ratio, width and height in pixels, and the pixel density of each device. There's a website that does conversions: thisispix.com/dp-px-converter. 

The density is important to know when doing the conversion. It's easy to find out by googling. The artpad is 213, which I learned is called tvdpi, whereas the ipad is 264 which is between hdpi and xhdpi. You set that in the calculator first, then put in the inches, and it shows the number of pixels.

Starting with the approximate size of the screen area in inches, I got the pixels to input for height and width. I started with 7.5 x 9.5, and put in the corresponding pixel amounts. I tried on one chordpro file until I got a similar size that matched the ipad.

The text was way too small, so I worked my way down, bit by bit. I made sure to maintain the aspect ratio, by dividing the numbers each time to keep 1.36.

I ended up with 915 for the width and 1250 for the height. I set it as default on the artpad. Now all the chordpro files (and abc within a .cho) look similar in size to the ipad (which is set at -1 and -1 for full screen).

In addition to this, I had to adjust the top and bottom margins in the text file settings to larger amounts to look like the same amount of space as the ipad.

The other issue, the fonts: I tried your test files and it was educational. I also read the links and copied the info from Michael about which fonts are included in the app.

This not helping with the abc files showing a serif font for the lyrics (%%vocalfont). Based on the list of fonts and their full names, I renamed vocalfont to RobotoCondensed instead of just condensed. It didn't make a difference.

Not that it should matter, but this artpad has no settings system-wide for changing the default built-in font, except for size. There's no font style setting like my samsung phones have.

I really hope I don't have to edit each of my abc files. I've done around 400 now. If the android version can just read "condensed" and display a san serif font, I will be happy, since I got the size issues worked out.

One question, with the page and margin sizes set differently on each device, can I still sync btween them and not mess up those settings?
Reply
#7
I have set THE SAME fixed page size on all my devices. Doing that I can even copy databases from one device to the other and get very similarly displayed scores.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#8
This a follow-up for future readers searching for answers for similar issues. 

1) The aspect ratio and pixel density problem between two different devices:

After this discussion I came across this post with itsme and Mike with more details about page sizing and what goes on behind the scenes:
https://www.zubersoft.com/mobilesheets/f...12378.html

It was very helpful information. Based on that, I continued to play with the page settings. 

What I came up with that is working for me:
The Ipad air 13" is set to 1010 / 1252
Teclast Artpad Pro 12.7" is set to 1010 / 1262

The chordpro and especially the abc files are now showing the same amount of lines per page on each device.


2) Regarding the difference in font rendering:

(This is just for the abc leadsheet files I created, setting the various font directives at the top of each file.)

The only font that I could reliably set on both devices to render a sans serif font was, *surprise* sans-serif.

I had set all the text that I wanted to be a 'sans-serif' look on the ipad as Helvetica (for title and composer) and Condensed (for the lyrics), because those were producing a sans serif font on the ipad. 

(Interestingly, Condensed in the chordpro font settings produces an actual condensed font, so I surmised that the Condensed directive I used in the abc files must have been replaced with the "default" on the ipad and I just didn't realize it wasn't the actual font name of anything, until the android replaced it with something different.)

Since I couldn't get the same results on the android, in the end I had to change EVERY file. But good news!

I had bought the Mike's version of MS for Windows through his fastspring store awhile back, for extra editing possibilities on my computer.

I just have to say what a fantastic forum this is. Because through googling and getting results from here, I learned how to redo my Windows version to set my own storage location, so I'd have access to the files. (Only possible with the fastspring version, not the Microsoft Store version.)

After I got that set up, I opened the folder in VS Code (Visual Studio) and *lots more googling* used Global Find And Replace. 

I changed all instances of Helvetica, Condensed, and Arial to sans-serif. And pressed enter! (Well, one font at a time.) It changed all 471 files instantly! In a few minutes I was done! (I have about 3000 songs in my library, mostly ChordPro and pdfs, but translating as many of my most used songs to abc, as I can.)

I have to say that I am proud of myself for figuring that out. I'm not a programmer.

Then, I backed up and restored on the android and ipad.

Anyway, it might help someone else who is needing to make global changes on chordpro or abc files.
Reply
#9
... set my own storage location, so I'd have access to the files. (Only possible with the fastspring version, not the Microsoft Store version.)...
That's not correct. Setting your own storage location also is possible in the Microsoft Store version, I do that from the very beginning.
Settings - Storage - Set The Mobile Sheets Storage Location
Just the database file(s) and some settings files like e.g. stamplists.json or user_filters.xml stay in 
c:\Users\<your username>\AppData\Local\Packages\41730Zubersoft.MobileSheets_ys1c8ct2g6ypr\LocalState\
On Android you set "Let MobileSheets Manage My Files" = OFF and "Expose Database File" = ON for a similar file and folder structure, except that database file(s) are saved in the Mobile Sheets Storage Location. 
If you save your scores in the same relative folder structure within the Mobile Sheets Storage Location you can even, alternatively to backup & restore, just copy score files and databases between devices.
On iPad there's no such thing as "Let MobileSheets Manage My Files" = OFF as far as I know. I never tried that myself as I don't own any Apple devices.

Fonts are a different, complicated topic. Certain fonts are preinstalled on different devices and in case you specified a font that is not available, it is replaced by another one that the UI considers to be similar. So it's hard to detect what is really used. To make it even more complicated, in some cases you have to specify the font name, in other cases you need the font file name. This lead to the situation that some programs like MuseScore or MobileSheets integrate the fonts they need into their program files.
It's still an open discussion with Mike here https://www.zubersoft.com/mobilesheets/f...11444.html  and in my posts above from 2026-01-24 which fonts are "behind" the font names in Advanced Settings - knowing that would allow getting the exact same appearance on different devices.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#10
I should probably mention that the FastSpring version has access to a setting that is not possible from the Microsoft Store version - the ability to access files anywhere on the device. This has to be explicitly enabled in the OS under Add or remove programs -> MobileSheets -> click the three dots, then Advanced options, and enable "File system". This is important in some scenarios, like having smart buttons that can access files from anywhere on the device to load in other applications, or linking to files outside the storage location in ChordPro files, etc. 

Mike
Reply
#11
Good to know. Learned something new again. But that would mean leaving the relative paths. In case a file is referenced anywhere outside the MobileSheets storage location on Windows, what happens if
1. a backup from that Windows device is restored on an Android device
2. a database from the Windows device is copy/paste'd to an Android device
What happens to the referenced file? Where will MobileSheets expect to find it?

Nevertheless RoSong's scenario could be solved also with MobileSheets from Microsoft store.
Great that RoSong found a solution. IMHO VS Code is a bit of overkill. My favorite text editor for Windows, Notepad++ allows, besides many other great features also "global search & replace"

And I'm still interested in a list of fonts that are integrated in MobileSheets and how I have to specify them for using them in ABC files.
first language: German
Acer A1-830, Android 4.4.2 - HP x2 210 G2 Detachable, Win 10 22H2 - Huawei Media Pad T5, Android 8.0 - Boox Tab Ultra C, Android 11
www.moonlightcrisis.de - www.basdjo.de - www.frankenbaend.de


Reply
#12
MobileSheets will leave the invalid path in place, as it won't know what to do with the absolute path. It will not try to convert the Windows absolute path to an Android relative path when it comes to smart buttons linked to external files (it does convert paths for song files like PDFs though).

As far as fonts, it comes down to whatever the Android OS will support. If you try to specify a custom font in the advanced settings, there is a search icon - that will show all detected fonts on the system. You can reference either a filename, a path to a file, or the font name when referenced a custom font. I'll have to go grab a list of the standard fonts though.

Mike
Reply




Users browsing this thread:
1 Guest(s)


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