/********************************************************************
                           CLOSE

  Description: Closes active document (for QEDIT keyboard emulation)
  Syntax:      CLOSE

  To map CloseFile command to shortcut key other than Ctrl+F4:

  1. Save this script in the GwdTextEditor\script directory.
  2. From the Macro menu, choose Macro command.
  3. Choose the New button.
  4. In the New Macro Name input box, type a name for the macro. For
     example Script_Close. In this dialog you can also define a
     shortcut key for macro.
  5. Choose the OK button.
  6. In the Edit Macro dialog box edit box enter the following two
     lines:
        Param1 "close.c"
        ExecScript
  7. Choose the Close button.
  8. You can now define shortcut key for Script_Close macro in the
     Key Mapping dialog box.

  Author: Vedran Gaco
********************************************************************/

#include <stdio.h>
#include <editor/doc.h>

int main(void)
{
   HDOC hdoc = Gte_GetActiveDocument();
   if(hdoc != NULL)
      Gte_CloseDocument(hdoc);
   return 0;
}

