backport from mozilla inventory: 3d669a37b9 refactored txt bind formatting