The Document History protocol (DHST) serves to provide a global list of the last-used documents, similar to the Recall menu in Texel. Start-Me-Up makes use of this by enabling files to be retrieved from just one place.
Here is a short version of the structure in C-notation:
#define DHST_ADD 0xdadd #define DHST_ACK 0xdade typedef struct { int8_t *appname, *apppath, *docname, *docpath; } DHSTINFO;
Every time the user opens a file, it searches the application for the cookie 'DHST'. The AES ID of the DHST-Server informs other programs where they should send DHST messages using the DHST_ADD message. The application then sends the information down to the global DHSTINFO- structure and adds the corresponding information depending upon:
appname: Name of the application (e.g. "Texel") apppath: Absolute path of the application (e.g. "c:\program\texel.app") docname: Name of the document (e.g. "balmer.txl") docpath: Absolute path of the document (e.g. "d:\Data\balmer.txl")
Then the DHST-Server sends the following message:
msg[0] DHST_ADD (0xdadd) msg[1] ap_id msg[2] 0 msg[3] and msg[4] Pointer to DHSTINFO-structure (how DHST_ADD passed) msg[5] 0 msg[6] 0 msg[7] 0
When an answer is received, the application sends the following message:
msg[0] DHST_ACK (0xdade) msg[1] ap_id msg[2] 0 msg[3] and msg[4] Pointer to DHSTINFO structure (how passed with DHST_ADD) msg[5] 0 msg[6] 0 msg[7] 0=error(s), else: OK