def stripFormatting(text):
 formatted = parseFormattedText(text)
 return _textattributes.flatten(formatted, _textattributes.DefaultFormattingState())

def stripFormatting ( text ) : formatted = parseFormattedText ( text ) return _textattributes . flatten ( formatted , _textattributes . DefaultFormattingState ( ) )
remove all formatting codes from c{text} .