labels.fmt function

Extract labels from a user-defined format