code: def set_attributes(self, attrs):
          
          if self.true_color() and not self.ansi_colors_only():
              self.write_raw(self._escape_code_cache_true_color[attrs])
          else:
              self.write_raw(self._escape_code_cache[attrs])
docs: Create new style and output.
  
          :param attrs: `Attrs` instance.