add attribute check when pushing active formatting elements to stack