def set(self, attr, value):
        def escape_new_syntax(value, double_quote_escape='"'):
            value = str(value)
            value = value.replace("'", "''")
            value = value.replace('"', '%s"' % double_quote_escape)
            if ' ' in value or '\t' in value:
                value = "'%s'" % value
            return value
        def escape_new_syntax_pre_post_script(value):
            return escape_new_syntax(value, '\\')
        def escape_remap(value):
            value = value.replace('=', '\=')
            value = value.replace(';', '\;')
            return value
        def join_function_template(join_string, escape_func):
            return lambda value: join_string.join([escape_func(i) for i in value])
        def quote_join_function_template(join_string, escape_func):
            return lambda value: join_function_template(join_string, escape_func)(value)
        join_functions = {'rempas': quote_join_function_template('; ', escape_remap),
                          'arguments': quote_join_function_template(' ', escape_new_syntax),
                          'Arguments': quote_join_function_template(' ', escape_new_syntax_pre_post_script)
                          }
        if value is False:
            value = 'false'
        elif value is True:
            value = 'true'
        elif isinstance(value, list) or isinstance(value, tuple):
            join_function = join_function_template(', ', str)
            for key in list(join_functions.keys()):
                if attr.endswith(key):
                    join_function = join_functions[key]
            value = join_function(value)
        self.attributes[attr] = value