Use the resolution QRegExp cap() instead of converting ints back and forth