def METHOD_NAME(target, attrlist, exclist, prefix):
    for item in attrlist:
        if is_list(item) and len(item) == 2 and item[0] not in exclist:
            name, value = item[0], item[1]
            ok = 1
            if value[0] in '-0123456789':
                value = eval(value)
            elif value[0] == '"':
                value = value[1:-1]
            elif value == 'move-then-resize':
                # Strange default set by Panel Editor...
                ok = 0
            else:
                print 'unknown value', value, 'for', name
                ok = 0
            if ok:
                lhs = 'target.' + prefix + name
                stmt = lhs + '=' + repr(value)
                if debug: print 'exec', stmt
                try:
                    exec stmt + '\n'
                except KeyboardInterrupt: # Don't catch this!
                    raise KeyboardInterrupt
                except:
                    print 'assign failed:', stmt