home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 5 Edit / 05-Edit.zip / cca_110.zip / BOXER.TXT next >
Text File  |  1998-06-16  |  3KB  |  66 lines

  1. Using CCA with Boxer/OS2
  2.  
  3. Boxer/OS2 is a text mode application that does not provide
  4. direct access to the OS/2 clipboard.  However a combination of
  5. Boxer/OS2 macros and CCA will allow users to copy text
  6. to and from the OS/2 clipboard.
  7.  
  8.  
  9. The following macros were written by:
  10. Ryan Gray
  11. scorpion@thuntek.net
  12. http://www.thuntek.net/~scorpion
  13.  
  14.  
  15. <macro=26><name=Copy>
  16. <OS access>del<sp>c:\clip.txt<enter><enter>
  17. <save block>c:\clip.txt<enter>
  18. <OS access>toclip<left angle>c:\clip.txt<enter>
  19. <enter><copy>
  20.  
  21. <macro=27><name=Cut>
  22. <OS access>del<sp>c:\clip.txt<enter><enter>
  23. <save block>c:\clip.txt<enter>
  24. <OS access>toclip<left angle>c:\clip.txt<enter>
  25. <enter><cut>
  26.  
  27. <macro=28><name=Paste>
  28. <OS access>fclip2<right angle>c:\clip.txt<enter><enter>
  29. <insert file>c:\clip.txt<enter>
  30.  
  31. Notes from Ryan Gray: 
  32.  
  33. The user will probably not use the same macro numbers I have, and they
  34. could also give them different names.  Therefore, the macro is really
  35. everything after the first line.  The user uses a separate utility to
  36. bind the macros to keys, otherwise the user can execute macros by name
  37. or number.  The user should not use these to replace the standard
  38. copy/cut/paste functions for use within Boxer, due to limitations and
  39. the overhead of this procedure.  The OS calls to delete the clip file
  40. are to avoid the conditional "overwrite?" prompt for copy and cut if
  41. the file exists.
  42.  
  43.    
  44. Q: Is there a section in the Boxer documentation that tells the user
  45.  how to use macros?  
  46.  
  47. Yes.  Chapters 20 and 28.  The macros could be saved as-is in a file
  48. with a .M extension, then the user can edit that file, and select 
  49. Macro -> Compile.  This adds the macros to those in memory.  Then
  50. selecting Macro -> Save, and saving to the DEFAULT.MAC will then load
  51. the new macros along with the default ones.  Before executing the Macro
  52. -> Compile, the user should use Macro -> List to see what macro numbers
  53. are available and number the copy/cut/paste macros accordingly.  Then,
  54. the user can execute the macro from the list, via Macro -> Execute, or
  55. refer to chapter 27 to use the RECONFIG utility to bind them to
  56. keystrokes.
  57.  
  58. One thing about the macros I haven't solved yet is that the copy and
  59. cut macros use the Boxer <copy> and <cut> codes at the end to echo the
  60. operation in Boxer's clipboard (and to remove the text for the cut
  61. macro), but if the user has their editor configured to remove the
  62. marking after copy or cut, the cut macro doesn't cut the text since the
  63. save block funciton unmarks the block before the <cut> code and other
  64. text will likely get cut. 
  65.  
  66.