Copy_To|Paste_From the Win32 Clipboard
CLIPW32 for XyWrite III+ v3.55+  R.J.Holmgren  11/30/03

Installation of CLIPW32 in Xy3+
------------ -- ------- -- ----
Prerequisites:
External file CLIP.EXE (part of http://www.serve.com/xywwweb/CLIPW32.ZIP).
  AutoItX3.dll is no longer required.  This alters the 10/2003 procedure,
  which used a Windows Scripting Host CLIP.VBS file together with
  AutoItX3.dll. If you've already installed the VBS file, you may continue to
  use it, but you MDULmustMDNM make a manual change to CLIPWXY3.FRM: move
  AELBCAF to the beginning of the SUbroutine 06 line that says VBS. Presently,
  the VBS line is inactive; DeFine "AELBC>" in front of EXE, and MoVe it in
  front of VBS.
Xy3 ErrorHelp is (*always* should be!) OFF: "default eh=0"

Extract file CLIP.EXE from the root directory of the
  ZIPfile (CLIPW32.ZIP)
Locate CLIP.EXE in the same directory as EDITOR.EXE

Extract file CLIPWXY3.FRM from the \XY3 subdirectory of
  the ZIPfile (CLIPW32.ZIP)

ClipW for Xy3+ requires that you dedicate one Ordinary
  Save/Get in range 0-9, A-Z to the Clip function.
  The default is S/G "Q".  If you wish to use a different
  Save/Get, replace *all* instances of "Q" with another
  alphanumeric Save/Get 0-9, A-Z

ClipW for Xy3+ requires that one User Variable be
  *hard-coded* in the frame!  Set the "d:\path\" location
  of EDITOR.EXE (where CLIP.VBS is also located) in
  Save/Get 01, at the top of the frame.  Examples specs
  appear in the frame.  SAve the frame!

CAll your Xy3 Help file.  I use SHORT.HLP; I think there
  was a LONG.HLP but I don't have it anymore.  The Help
  file must be labeled ";HL;" at Top_Of_File.  I add my
  own routines ("frames") at the bottom of this file,
  after the factory XyQuest routines.  ;HL; is the only
  Xy3+ Help file, but it's got lots of potential power
  (underutilized -- this is one way).

Go to End_Of_File.  Just before the last routine (frame),
  which is "{{6*,end}}" in SHORT.HLP, insert (cut and
  paste) CLIPWXY3.FRM into the file.  SAve Help.  Command:
LOAD SHORT.HLP<cr>.

Helpkey (*not* optional)
-------
  Make *sure* you have a "<Helpkey>" KeyBoarD assignment
  to launch Help file frames specified by name on the
  CMline:
nn=HL
  To simultaneously Stack a command (ONLY if you use Stack):
nn=&S,HL
nn=&SHL  <==same thing, 1 byte less memory consumed

Reserved Filenames
-------- ---------
All reside in Editor's directory -- DO NOT USE these filenames!
  CLIP.EXE or CLIP.VBS
  CLIP.TXT
  CLIP1.TXT
  CLIP2.TXT
  Q.SAV

KeyBoarD File Methods (optional)
-------- ---- -------
  Assign one CLIP function to specific key
nn=SIGHEL,C,W,C, ,HL  <==Copy only
nn=SIGHEL,C,W,A, ,HL  <==Append only
nn=SIGHEL,C,W,B, ,HL  <==Prepend only
nn=SIGHEL,C,W,F, ,HL  <==Copy current File
nn=SIGHEL,C,W,P, ,HL  <==Paste only
nn=SIGHEL,C,W,R, ,HL  <==Replace only
  To Stack any of the above commands (if you use Stack):
nn=SI&SGHEL,C,W,C, ,HL
nn=SI&SGHEL,C,W,A, ,HL
etc.

Command Line Methods (optional)
------- ---- -------
  Issue Copy/Paste command on the CMline
CWC [text]<Helpkey> - Copy    (~Ctrl-C) 
CWA [text]<Helpkey> -   Append to existing Clip text
CWB [text]<Helpkey> -   Prepend to existing Clip text
CWF<Helpkey>        - Copy current File
CWP<Helpkey>        - Paste   (~Ctrl-V)
CWR<Helpkey>        - Replace (~Ctrl-X)
  N.B.: _CMline_ text size limit=73 chars

Examples
--------
  Copy a CoMmand line argument to the Clipboard:
CWC Dirt-weed, Chenopodium viride, grows on dunghills<Helpkey>
CWC http://holmgren.home.acedsl.com/charmant.wav<Helpkey>
  Append a CoMmand line argument to the existing Clipboard:
CWA The wholesome discipline of bull pizzle and strait jacket<Helpkey>
  Prepend a CoMmand line argument to the existing Clipboard:
CWB How shittle witted am I, for I had forgotten it<Helpkey>
  Copy currently-displayed File Text to Clipboard:
CWF
  With CWF, the text Copied is the text *currently displayed*
  -- not the last SAved version.  CWF may also be used
  with a CONsole (CAll CON) "untitled" window

  Copy DeFined text in current window to the Clipboard:
CWC<Helpkey>
  Append DeFined text in current window to the existing Clipboard:
CWA<Helpkey>
  Prepend DeFined text in current window to the existing Clipboard:
CWB<Helpkey>

  Paste anything from the Clipboard to current text location:
CWP<Helpkey>

  Replace DeFined text with content of the Clipboard:
CWR<Helpkey>

Differences with CLIPW for Xy4-DOS
----------- ---- ----- --- -------
Clip:   If an argument resides on CMline, it is clipped,
  ignoring DeFined text (CMline has priority; position
  of the cursor in CMline|Text is not decisive)
Paste:  Pastes only to Text
The Insert|Overstrike state of the cursor is not respected
  *if* CLIPW is launched from the KBD file (the routine
  always SetsInsert [func SI])
The CMline|Text location of the cursor is not respected
  (the routine always terminates in Text, if any [func GT])
Does not reposition corners of screen to original locations

Limitations
-----------
Maximum Clip Size (theoretic)=2Gb
Maximum Clip Size for DeFined text=~64Kb
 (the size of the Xy3+ DeFined text buffer)
Maximum Clip Size for Whole File=~500Kb
Ascii-0 is interpreted as End_Of_Data by the Clipboard
 and terminates a Clip (Ascii-0 [00h] occurs very rarely
 in XyWrite 3-byte charset)

Compatibility
-------------
Does CLIPW-Xy3 work in Xy4?  (Any chance you can avoid that
  ugly U2 thing?)  No.

Errors
------
If you start getting CSCRIPT.EXE errors, check Editor's
directory for copies of CLIP.TXT, CLIP1.TXT, and/or CLIP2.TXT.
Delete them all.
