Re: fgl_drawbox command?
Posted in 1994
porterg@nextnet.csus.edu (greg porter) writes: > I have heard that there is a command for drawing boxes on a 4gl screen >I believe they said it was fgl_drawbox. I have scoured my 4gl documentation >and can't find it anywhere. Is this an undocumented command? Does anyone >have information on it or where I can find it in the manuals? >Any help would be appreciated. fgl_drawbox() is undocumented, and therefore if you use it and a future release of 4GL makes it blow up, I don't want to hear about it. Quoting from the Developer's release that came with my 4GL/GX FOR MOTIF USER GUIDE (which is the only reference to fgl_drawbox() I would find): "Some customers have been making use of an undocumented, global 4GL function called fgl_drawbox(). In 4GL/GX, the drawn boxes are part of a form; each time you DISPLAY FORM you must also redaw the box. Since the COMMENT LINE, MENU LINE, HELP LINE, MESSAGE LINE, ERROR LINE, or FORM LINE are frequently redrawn, boxes can be partially erased where they overlap these lines. Once parts of the boxes have been erased, your application must refresh the boxes explicitly. You can work around this problem by moving your boxes so they do not overlap any of these lines." We also found that if a border of a box drawn with fgl_drawbox() goes through an input field, that field becomes NOENTRY in GX. The worst (best) thing about fgl_drawbox() is that someone used it in the demo code that ships with 4GL and is used in the class. So, if you insist you want to use it (DON'T! It's UNDOCUMENTED!! Well, I warned you), look at $INFORMIXDIR/demo/fgl/d4_cust.4gl, d4_orders.4gl, and d4_report.4gl. If you run r4gldemo or c4gldemo while in an empty directory, the sample code is copied over for you. The four parameters are the location of the upper right corner of the box, and the depth and width, but I don't recall off the top of my head (and I NEVER use this code in a real application; it's undocumented) the order in which they occur. I think there's a fifth (optional) parameter now, which is a number that corresponds to color for GX, but again, I have to direct experience. ============================================================ Dennis J. Pimple Senior Consulting Services Engineer Informix Software Inc Denver Colorado USA dennisp@informix.com Voice:303-850-0210 Fax:303-779-4025