The UFO specification has glyph properties width and height. From the width, one can get the left and right sidebearings. One could get bottom and top sidebearings from the height.
If the bottom sidebearing behaves like the left sidebearing then it is actually the distance between the baseline and the lowest outline y-coordinate (yMin).
But in most cases a glyph should keep its baseline at y=0 for horizontal layout and have a different bottom sidebearing line for vertical layout.
Take 'g' for example.
In vertical layout:
1.a If it has a positive or zero bottom sidebearing, its outline won’t overlap with the next glyph’s advance height.
1.b If it has a negative bottom sidebearing, its outline will overlap with the next glyph’s advance height.
In horizontal layout:
2.a If it has a positive or zero bottom sidebearing, its outline sits on top of the baseline.
2.b If it has a negative bottom sidebearing, its outline extends below the baseline.
In this case one would want 1.a. in vertical layout and 2.b. in horizontal layout.
The current specification doesn’t support this as there is no baseline information.
If there was a glyph baseline property, then
bottom sidebearing = baseline + yMin
or the other way around
baseline = bottom sidebearing - yMin
Would it make sense to add a baseline property to glyphs in the UFO specification?
The glyph baseline property could be defined as:
attribute name: baseline
data type: integer or float
description: The vertical distance between the bottom of the vertical advance and the baseline. Optional, requires height to be defined.
default value: 0