Changes between Version 3 and Version 4 of Documentation/ARexxAPI/WRITEEDITOR


Ignore:
Timestamp:
Feb 5, 2014, 4:07:16 PM (10 months ago)
Author:
damato
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Documentation/ARexxAPI/WRITEEDITOR

    v3 v4  
    1 [[TranslatedPages]]\\
    2 [[TOC(titleindex, heading=ARexx API, notitle, depth=2, Documentation/ARexx API/*)]]
    3 
     1[[TranslatedPages]]
     2[[TOC(sectionindex, heading=ARexx Function List, notitle, depth=1, Documentation/ARexxAPI/)]]
    43== WRITEEDITOR
    54
    6 '''NAME'''
     5 NAME::
    76     WriteEditor -- Pass an ARexx command to the internal editor. (V2.0)
    87
    9 '''TEMPLATE'''
     8 TEMPLATE::
    109     VAR/K,STEM/K,COMMAND/A
    1110
    12 '''FUNCTION'''
     11 FUNCTION::
    1312     Passes an ARexx command to the internal editor to act upon the
    1413     contents of a given Write window.
     
    1716     are currently supported:
    1817
    19       CLEAR\\
    20       CUT\\
    21       COPY\\
    22       PASTE\\
    23       ERASE\\
    24       GOTOLINE       Template: /N/A\\
    25       GOTOCOLUMN     Template: /N/A\\
    26       CURSOR         Template: Up/S,Down/S,Left/S,Right/S\\
    27       LINE           Template: /N/A\\
    28       COLUMN         Template: /N/A\\
    29       NEXT           Template: Word/S,Sentence/S,Paragraph/S,Page/S\\
    30       PREVIOUS       Template: Word/S,Sentence/S,Paragraph/S,Page/S\\
    31       POSITION       Template: SOF/S,EOF/S,SOL/S,EOL/S,SOW/S,EOW/S,SOV/S,EOV/S\\
    32       SETBOOKMARK    Template: /N/A\\
    33       GOTOBOOKMARK   Template: /N/A\\
    34       TEXT           Template: /F\\
    35       UNDO\\
    36       REDO\\
    37       GETLINE\\
    38       GETCURSOR      Template: Line/S,Column/S\\
    39       MARK           Template: On/S,Off/S\\
    40       DELETE\\
    41       BACKSPACE\\
    42       KILLLINE\\
    43       TOUPPER\\
    44       TOLOWER\\
     18     {{{
     19      CLEAR
     20      CUT
     21      COPY
     22      PASTE
     23      ERASE
     24      GOTOLINE       Template: /N/A
     25      GOTOCOLUMN     Template: /N/A
     26      CURSOR         Template: Up/S,Down/S,Left/S,Right/S
     27      LINE           Template: /N/A
     28      COLUMN         Template: /N/A
     29      NEXT           Template: Word/S,Sentence/S,Paragraph/S,Page/S
     30      PREVIOUS       Template: Word/S,Sentence/S,Paragraph/S,Page/S
     31      POSITION       Template: SOF/S,EOF/S,SOL/S,EOL/S,SOW/S,EOW/S,SOV/S,EOV/S
     32      SETBOOKMARK    Template: /N/A
     33      GOTOBOOKMARK   Template: /N/A
     34      TEXT           Template: /F
     35      UNDO
     36      REDO
     37      GETLINE
     38      GETCURSOR      Template: Line/S,Column/S
     39      MARK           Template: On/S,Off/S
     40      DELETE
     41      BACKSPACE
     42      KILLLINE
     43      TOUPPER
     44      TOLOWER
     45     }}}
    4546
    4647     Refer to the Amiga User Interface Style Guide for more info
     
    5051     the ARexx Host requires to escape certain special characters like a newline
    5152     (0x0a) or escape character (0x1b) if you want to pass it i.e. with an
    52      TEXT command to the texteditor.
     53     `TEXT` command to the texteditor.
    5354
    5455     This means that you have to use the following escape sequences in your
    5556     provided strings:
    5657
    57      *N substitutes to 0x0a\\
    58      *E substitutes to 0x1b\\
    59      !** substitutes to *\\
    60      *" substitutes to "\\
     58     {{{
     59     *N substitutes to 0x0a
     60     *E substitutes to 0x1b
     61     !** substitutes to *
     62     *" substitutes to "
     63     }}}
    6164
    6265     Please have a look at the examples below for a short example on how to use
    6366     these escape sequences properly.
    6467
    65 '''INPUTS'''
    66      VAR/K       - alternative variable to put the results into instead of RESULT\\
    67      STEM/K      - base name used for the stem where the result will be stored\\
    68      COMMAND/A   - the command string to be passed\\
     68 INPUTS::
     69     `VAR/K`       - alternative variable to put the results into instead of `RESULT`\\
     70     `STEM/K`      - base name used for the stem where the result will be stored\\
     71     `COMMAND/A`   - the command string to be passed\\
    6972
    70 '''RETURNS'''
    71      VAR          - info returned by the query\\
    72      <STEM>RESULT - results of the command, if any\\
     73 RETURNS::
     74     `VAR`          - info returned by the query\\
     75     `<STEM>RESULT` - results of the command, if any\\
    7376
    74      RC is set to 10 if no Write window was previously specified as
    75      "active" with [[ARexx API/MAILWRITE| MAILWRITE ]].
     77     `RC` is set to 10 if no Write window was previously specified as
     78     "active" with [[MAILWRITE]].
    7679
    77 '''NOTES'''
     80 NOTES::
    7881
    79 '''EXAMPLE'''
    80          /* Enable result codes */
     82 EXAMPLE::
     83     {{{#!urbiscript
     84     /* Enable result codes */
     85     OPTIONS RESULTS
    8186
    82          OPTIONS RESULTS
     87     /* Start a new mail */
     88     MAILWRITE STEM st.
     89     win = st.window
    8390
    84          /* Start a new mail */
     91     /* Edit the Write window */
     92     MAILWRITE WINDOW win
     93     WRITETO boss@example.com
     94     'WRITESUBJECT "I do not think I can go to work today"'
    8595
    86          MAILWRITE STEM st.\\
    87          win = st.window\\
     96     /* Clear the editor */
     97     WRITEEDITOR CLEAR
    8898
    89          /* Edit the Write window */
     99     /* Write some text into the editor */
     100     'WRITEEDITOR "TEXT Sorry, but I am sick today!"'
    90101
    91          MAILWRITE WINDOW win\\
    92          WRITETO boss@example.com\\
    93          'WRITESUBJECT "I don't think I can go to work today"'\\
     102     /* Write some text containing a newline (*N) */
     103     'WRITEEDITOR "TEXT Hello Joe,*N I would like to meet you."'
     104     }}}
    94105
    95          /* Clear the editor */
     106 BUGS::
    96107
    97          WRITEEDITOR CLEAR
    98 
    99          /* Write some text into the editor */
    100 
    101          'WRITEEDITOR "TEXT Sorry, but I am sick today!"'
    102 
    103          /* Write some text containing a newline (*N) */
    104 
    105          'WRITEEDITOR "TEXT Hello Joe,*N I would like to meet you."'
    106 
    107 '''BUGS'''
    108 
    109 '''SEE ALSO'''
    110      [[ARexx API/MAILWRITE| MAILWRITE ]]
     108 SEE ALSO::
     109     [[MAILWRITE]]