957.4.1 xcall XTREE
• | Further aesthetic cleanup of display issues related to editable cells with validation. |
• | Preservation of top index (vertical scroll position) now works with multilevel trees also. |
957.3.1 SUBMIT.LIT
(UNIX) SUBMIT.LIT 3.1(143) now supports a maximum time limit by adding an optional number of minutes to the /W switch, i.e.:
.SUBMIT MYTASK /W:5
This would wait up to 5 minutes, and if the process is still running at that time, it will be killed. Specifying /W without the optional minutes argument causes the submitter to wait indefinitely, as before. (The previous edit, 142, had incorrectly set the default wait value to 1 minute.)
957.3.2 APPEND.LIT
APPEND.LIT 2.1(114) now supports the case where the destination and one of the source files is the same file, and neither exists, provided the /I{gnore} switch is specified, e.g.:
.APPEND /I A.A=A.A,B.B
Previously this would have aborted with an error if A.A didn't exist. Now, the above command is logically equivalent to COPY A.A=B.B
957.3.3 Running A-Shell
Improve parsing of initial A-Shell command line as so to be smarter about when to interpret \n as a line break as when to interpret it as a literal character sequence. As background, 926.2 introduced the ability to pass multiple commands on the A-Shell startup command line by separating them with chr(10) or "\n". This applies whether launching A-Shell from an icon/shortcut or via HOSTEX.SBR. For example:
XCALL HOSTEX,"$ASHELL vue notes.txt\nsize notes.txt"
The above command line essentially creates and then executes a command file on the fly, equivalent to:
:R
vue notes.txt
size note.txt
The problem occurs when Windows or UNC paths are passed on such command lines, since in that case a \n might occur inside of such a path. Previously, A-Shell limited the confusion by only recognizing \n if it was the first \ in the command line.
Now, it attempts to analyze whether the \n occurs in something that looks like a filespec. If so, it treats the \n as literal; else it treats it as a line break. For example:
XCALL HOSTEX,"$ASHELL log ashtst:\nvue c:\notes \nsize c:\notes.txt"
The above command line contains 4 \n sequences. The first and third are considered not part of filespecs and thus are converted to line breaks. The second and fourth, which are contained in the token "c:\notes.txt", which is interpreted as a filespec because it starts with what could be a drive letter.
Note the following tricks and considerations when trying to get "\n" to be treated as a line break:
• | If you want to follow a filespec with "\n", precede it by a space, as we did in the example above for the "\n" following "vue c:\notes". A trailing or leading space does not usually interfere with the interpretation of a filespec, so that shouldn't cause a problem. Without the space, in the example above, "c:\notes\nsize" would have been considered a single filespec. |
• | Quoting the filespec doesn't help, since the quotes are generally removed by the shell or other command line parser before we get to the code that looks for "\n". |
• | A token is considered to be a filespec if it starts with \\ or with a letter followed by a colon. |
957.3.4 GUI
You can now specify an RGB value for the FGC and BGC (foreground and background color) parameters in AUI_CONTROL when creating STATIC controls, rather than being limited to the previously defined colors in the color palette.
In order for FGC or BGC to be recognized as an RGB value rather than a palette color number, it must not be -1 or -2, and one of the following must be true: R value not zero, G value not 0, or B value >= 128. Use hex notation to make this humanly readable, i.e. &hRRGGBB where RR, GG and BB are the two-digit hex values for red, green and blue. For example, magenta could be represented as &hFF00FF.
Note if either the FGC or BGC parameter (for a STATIC control) contains an RGB value, this overrides the XP Theme color (just as if you had added +64 to the palette color number).
957.3.5 xcall XTREE
Minor aesthetic improvements relating to editable cells and validation:
• | The column currently being edited now shows as selected. (Previously it tended to select the column of the last validated cell.) |
• | When moving from one validated cell to the next, there was previously a quick flash in the first column for that row, owing to the row being selected then inactivated, then cleared during each validation operation. |
957.2.1 XTREE
Miscellaneous minor fixes and improvements:
• | Fix problems with how row(s) are initially selected in XTREE. Now it should conform more closely to typical Windows standards i.e. if you click on a row while the tree is inactive, when it gets activated, that row will be selected. If it is a multi-select tree, such a click will clear previous selections unless you use the CTRL or SHIFT key at time of click. Clicking on a neutral part of the control should select the previously selected item(s). Note, however, that currently clicking on the scroll bars of an inactive XTREE does not actually activate it. This allows you to scroll the display without any need for your application to respond. |
• | Opcodes 1 (reload) and 4 (reselect) now attempt to preserve the current scroll position of the existing tree, provided that the first selected item is visible. Previously it was usually trying to reposition the scroll bar such that the first selected item was approximately 1/3 of the way down from the top visible position. |
957.2.2 ATE
Fix inadvertent tracing of "sending kbd response" messages to ashlog.log.
957.1.1 GUI
A-Shell now uses the same grid units when the main window is launched invisibly (with -z switch) as it does when launched normally. Previously, it used a default window size, which affected the sizing of dialogs opened by the invisible window (unless the MBF_ALTPOS or font-based dialog sizing method was used).
957.1.2 XTREE
Miscellaneous fixes:
• | Drag-and-drop now targets the positions between the existing rows, rather than the rows themselves, so you can now drop a row either before or after any existing row. (Previously the target was a row, which was interpreted as meaning that the dropped item would be inserted just before the target row, making it impossible to drop a row after the last existing row.) |
• | You can now initiate a drag-drop operation with a single click-drag. Previously, this only worked if the item to be dragged was already selected, which meant you would have had to click twice to start dragging an item that wasn't previously selected. |
• | The row dropped (via drag-and-drop) now remains selected. |
• | Drag-and-drop is now supported in multi-select trees, although only a single item may be dragged at a time. |
• | Some confusion over how the initially selected row(s) were determined has been partially cleared up. In general, the ANSWER data (whether a single value or an array) is used to pre-select the items. The main exception is that if you had clicked on the XTREE while it was inactive, then for single-select trees, the row clicked will override the ANSWER specification. For multi-select trees, the row clicked will add to the existing set of selected rows. |
• | Clicking on another cell during a cell editing operation was sometimes causing the control to appear to become stuck in an infinite loop. |
• | Fix a memory leak when re-entering an editable tree after validating and the tree contained combo boxes or popup menus. (After a few dozen validation cycles, you would start getting OUT OF MEMORY errors, although it probably didn't affect the operation of the program if the tree was deleted before trying to create another one. |
957.1.3 MIAMEX 117, Send MAPI Email
The MIAMEX email interface now supports attachments. The new syntax is:
xcall MIAMEX, MX_MAPI, status, fspec {,flags, subject, text, xdata, fspec2, fspec3, ...fspecn}
To send file(s) as attachments, add +2 to flags.
subject
will specify the subject line of the message.
text
will specify the body of the message.
xdata
a dummy placeholder argument intended to be implemented later for further refinements, such as specification of recipients. You can specify "" in its place for now.
fspec2...fspecn (string)
specifies additional attachments (if you have more than one).
Note that this call requires that the Windows "Simple MAPI" interface be installed. This will happen automatically in most cases, as it is included in Outlook Express. But it is not installed by default with the full server version of Exchange Server. In that case, you need to manually install the "simple MAPI" subsystem from your Windows media or www.microsoft.com.
957.1.4 ATE (server side only)
Fix a problem in which INFLD would not return the updated field contents when the originally preloaded field contained characters that had to be "escaped" (such as embedded quotes).
957.1.5 EFS
New EFS build 51000; some minor performance optimization for encrypted ISAM files.
957.0.1 NFIND
XCALL NFIND now works as documented. (Previously, it hardly worked at all.)
957.0.1a ATE
(ATE) Fix problem with: S status in a command file not being cleared immediately at end of command file.
957.0.2 EFS
For the Encrypted File System (EFS) you can now specify which extensions are to be encrypted via the following MIAME.INI command:
EFSEXT=ext1{,ext2,ext3,...ext10} ; (up to 10 extensions)
Whenever a file is created (either via OPEN for output or ALLOCATE), if the extension is in the EFSEXT list, and encryption is supported, and has not been disabled via XCALL ASFLAG,1024, then the file will be created as an encrypted file. (Note: EFS is not included in the standard release version of A-Shell but is supported as a custom option.)
EFS also now supports the INMEMO option whereby INMEMO opens the file itself.
957.0.3 XTREE
Clean up an XTREE display anomaly introduced in 955 in which the initial display of an XTREE control would sometimes involve multiple passes, with the first pass(es) involving fewer than the total number of columns.
957.0.4 ATE
Fix a problem in which the PAGE command was intermittently not working (i.e. not stopping at the end of each page).
957.0.5 ATE
ATE now looks for files related to control creation (icons, bitmaps, etc.) in the %ATEPERMCACHE% directory if not found in the initially specified directory.
957.0.6 UNIX
TRACE=INOUT now also lists the inodes of the jobtbl.sys and qflock.sys files in the ashlog.log entry. This is useful for confirming that the jobs are actually sharing the same sys files.
957.0.7 XTREE
XTREE now supports item drag-drop (within a single XTREE control) as a means of allowing the user to re-order the rows and to communicate the new order back to the application. For example, you may want to present a list of fields available for export and allow the user to determine the output order by rearranging the list using drag/drop. Or you may want to load up an XTREE with a list of all of your illegally downloaded MP3 tunes and use the drag/drop feature to create ordered play lists.
To enable the feature, specify the XTF_DRAGDROP (&h10000000) bit in the FLAGS parameter, and insert two fields at the start of the ANSWER array, along the lines of how you would set up the ANSWER array for editable cells. The first field is a 4 character string to return the original row number for the given display row, and the second field is an array of one-character item selection flags (just as you would have for multi-selection).
For example:
MAP1 ANSWERX
MAP2 ANSARY(MAX_ROWS)
MAP3 ORG'ROW,S,4 ! original row # of this display row
MAP3 SELECTION,S,1 ! selection flags
MAP3 CB,S,1 ! a checkbox column
MAP3 EDATA,S,8 ! a 8 character editable column
<etc>
Note that the ORG'ROW field must be first, followed by the SELECTION field, followed by any editable checkboxes, followed by any other editable cells. (In the example above the ORG'ROW and SELECTION fields would be mandatory while the CB and EDATA fields would only apply if you happened to have one editable checkbox column and one editable text column.)
The SELECTION field is treated just as it would be when multi-select is enabled (i.e. SELECTION(I)="1" if item I is selected, or "0" if not.) Note that the presence of a SELECTION array usually indicates that multiple selection is supported, but in this case it does not necessarily imply that. In fact, the drag-drop operation currently only works for one row at a time, although you can still allow multi-selection for reasons independent of drag-drop. In normal (single selection) case, all of the SELECTION() entries will be "0" except for the one selected item.)
The ORG'ROW field is formatted as a decimal number of up to 4 digits with leading spaces. (This imposes a maximum of 9999 rows when using drag-drop, which is a reasonable limit since drag-drop becomes somewhat impractical anyway when you have more than several dozen items.)
Since the array used to load items is not returned by XTREE, and all other related return data specifying row numbers is coded relative to the original order of the rows (as opposed to the last display order), the ORG'ROW() array provides the only way for the app to determine what the last display order was. (This might even motivate you to enable drag/drop just for the purpose of being able to easily process the array data according to the way the user sorted it.)
The ORG'ROW() array is ordered according to the display order of the rows, unlike all the other arrays within the ANSWER array, which are ordered according to the original array order. As an example of using ORG'ROW(0, the following code would print the original array data according to the display order (resulting from drag/drop and/or column sorting):
FOR I = 1 TO MAX_ROWS
J = VAL(ORG'ROW(I))
IF (J > 0) PRINT ARRAY(J)
NEXT I
957.0.8 COPY.LIT
COPY.LIT 3.1(122) now preserves the modification time and ownership of the source file. Also, it supports a new switch, /C{onfirm}, which is similar to the /Q{uery} switch except that it only prompts you to confirm whenever the destination already exists. (If you are prone to accidentally overwriting important files by loose-fingered copy commands, you may want to rename COPY.LIT to something else, then create a COPY.DO which forces the /C switch to be specified.)