41
301
265
后起之秀
(defun pf ()(setq pipematerialpreset '("MILD" "SS"));protection, if tiles are nil(if (= pipesize nil)(setq pipesize "2"))(cond ((= masstype "316 S.S.") (setq material "1"))((= masstype "MILD STEEL") (setq material "0")))(if (= flgod nil)(setq flgod " ")) (if (= flgid nil)(setq flgid " ")) (if (= flgthk nil)(setq flgthk " ")) (setq flgthktype 0) (setq toggle 0)(defun flgio ()(setq dialo (load_dialog "MainDCL"))(if (not (new_dialog "Flangebox" dialo)) (exit));set up for data;for pipe size(start_list "pipeSize") (mapcar 'add_list Pipesizes) (end_list);for pipe material(start_list "material") (mapcar 'add_list pipematerialpreset) (end_list);Pre-set tiles(set_tile "pipeSize" pipesize )(set_tile "material" material)(set_tile "flgod" flgod)(set_tile "flgid" flgid )(set_tile "flgthk" flgthk )(if (or (= flgtype "TABLED")(= flgtype nil))(set_tile "tabled" "1"))(if (= flgtype "TABLEE")(set_tile "tablee" "1"))(if (= flgtype "ANSI150")(set_tile "ansi150" "1"))(if (= flgtype "ANSI300")(set_tile "ansi300" "1")) ;what to do settings (if (= toggle 1)(progn (mode_tile "customflgdtls" 0) (mode_tile "flgtype" 1) (mode_tile "flgthktype" 1))(progn (mode_tile "customflgdtls" 1) (mode_tile "flgtype" 0) (mode_tile "flgthktype" 0)) ) (action_tile "stdthk" "(setq flgthktype 0)") (action_tile "outtk" "(setq flgthktype 1)") (action_tile "customflg" "(progn (if (= toggle 1) (progn (mode_tile "flgtype" 0) (mode_tile "flgthktype" 0) (mode_tile "customflgdtls" 1) (setq toggle 0) ) (progn (mode_tile "flgtype" 1) (mode_tile "flgthktype" 1) (mode_tile "customflgdtls" 0) (setq toggle 1) ) ) )" ) (action_tile "cancel" "(setq ok 0) (done_dialog)") (action_tile "accept" "(setq ok 1) (setq pipesize (strcase(get_tile "pipeSize"))) (setq material (strcase(get_tile "material"))) (setq flgod (strcase(get_tile "flgod"))) (setq flgid (strcase(get_tile "flgid"))) (setq flgthk (strcase(get_tile "flgthk"))) (setq flgtype (strcase(get_tile "flgtype"))) (done_dialog)") (action_tile "odget" "(setq ok 2) (setq pipesize (strcase(get_tile "pipeSize"))) (setq material (strcase(get_tile "material"))) (setq flgod (strcase(get_tile "flgod"))) (setq flgid (strcase(get_tile "flgid"))) (setq flgthk (strcase(get_tile "flgthk"))) (setq flgtype (strcase(get_tile "flgtype"))) (done_dialog)")(action_tile "idget" "(setq ok 3) (setq pipesize (strcase(get_tile "pipeSize"))) (setq material (strcase(get_tile "material"))) (setq flgod (strcase(get_tile "flgod"))) (setq flgid (strcase(get_tile "flgid"))) (setq flgthk (strcase(get_tile "flgthk"))) (setq flgtype (strcase(get_tile "flgtype"))) (done_dialog)")(action_tile "thkget" "(setq ok 4) (setq pipesize (strcase(get_tile "pipeSize"))) (setq material (strcase(get_tile "material"))) (setq flgod (strcase(get_tile "flgod"))) (setq flgid (strcase(get_tile "flgid"))) (setq flgthk (strcase(get_tile "flgthk"))) (setq flgtype (strcase(get_tile "flgtype"))) (done_dialog)") (start_dialog)(unload_dialog dialo) ) (flgio) (while (not (or (= ok 1) (= ok 0)))(if (= ok 2)