Thank you Abhinit for your reply.
I also searched for this, so I would like to place here the exact restrictions that you need to apply to align the texts to your liking.
This image from Wikipedia shows various sections of the font size.

, , , , x, .
, label "HELLO", viewAbove, viewBelow .
:
let font = label.font
let ascenderDelta = font.ascender - font.capHeight
LayoutHelper()
.addViews([
"label":label, "viewAbove":viewAbove, "viewBelow":viewBelow
])
.withMetrics(["ascenderDelta":ascenderDelta])
.addConstraints([
// -- Here the constraints to align to cap height --
"X:label.top == viewAbove.bottom - ascenderDelta",
"X:label.baseline == viewBelow.top",
...other constraints...
])
: LayoutHelper, , .
"-":
, "" , , , descenders, ascenders, caps ..
, drawTextInRect ( , , , insets = {-ascenderDelta, 0, font.descender, 0}). / , . .