From: Maurice L. <mj...@ga...> - 2002-07-29 02:23:19
|
Maurice LeBrun writes: > One possibility that might satisfy everyone, if it could work, is to use > an escape function in the xwin driver for the missing commands. Then there > is separation without significant increase in work. Has anyone looked into > this approach? OK, I just did. The three functions needed by plframe.c: | jcard:~/tmp/plplot/tmp > for i in `nm -p libpltcl.so | fgrep " U "| awk | '{print $2}'`; do nm -p drivers/xwin_drv.so | fgrep $i | fgrep " T "; | done | 00004900 T plX_setBGFG | 00005550 T PLColor_from_XColor | 00001d40 T plD_open_xw can without too much trouble be called via the escape function approach, thus removing them from consideration as external functions. plX_setBGFG and plD_open_xw don't even need to pass any data, just the stream pointer and an operator index. For PLColor_from_XColor, a pointer to a temporary structure would have to be passed. In each case, we're talking about only one call from plframe.c, so the escape function approach seems reasonable to me. Then the whole issue with where to put these functions is avoided, and the xwin related logic remains in xwin.c, very simple and effective. So I'd like to go back to the way it was but with these functions turned into escape functions. Presumably this can be done with the tkwin_common.c stuff too. -- Maurice LeBrun mj...@ga... Research Organization for Information Science and Technology of Japan (RIST) |