From: kiki at pixar.com (kiki)
Date: Mon, 24 May 1999 21:27:35 -0700
Subject: [tkinter] Event from menu event?
References: <3749FE8A.9DD61AB4@pixar.com>
Message-ID: <374A26B6.82ECB6AE@pixar.com>
X-UID: 1800                                                

Here's some incentive :-)


for each_draw_class in draw_class_list:

        menu_func_lines = [ "def
%s_menu_call():\n"%eval(each_draw_class).__name__,
                               "\tglobal canvas_data\n",
                               "\tnew_draw_obj =
%s(canvas_data)\n"%each_draw_class,

"\tcanvas_data.list.append(new_draw_obj)\n\n"]
        menu_func_str = ""
        for each_line in menu_func_lines:
                menu_func_str = menu_func_str + each_line

        exec( compile( stitch_func_str,
eval(each_stitch_class).__name__,"exec" ))


My code aesthetic-sense is convulsing and has swallowed its tongue!  Help!
:-)

Kiki -- ow.





