home *** CD-ROM | disk | FTP | other *** search
/ Club Amiga de Montreal - CAM / CAM_CD_1.iso / files / 545a.lha / PowerVisor_v1.0 / docs.LZH / docs / InstallingPowerVisor < prev    next >
Encoding:
Text File  |  1991-09-01  |  26.7 KB  |  760 lines

  1. *----------------------------------*
  2. * Tutorial : installing PowerVisor * Sun Sep  1 14:48:14 1991
  3. *----------------------------------*
  4.  
  5. ===================== Commands used in this tutorial =========================
  6.  
  7.    mode        Set PowerVisor preferences
  8.    prefs       Set preferences
  9.    screen      Set PowerVisor on another screen
  10.  
  11. ===================== Functions used in this tutorial ========================
  12.  
  13.  
  14. ============================== Introduction ==================================
  15.  
  16. At this moment (after you have read the 'GettingStarted', the 'Expressions'
  17. and the 'Screen' chapters) you are probably ready to ²customize PowerVisor.
  18. This is a complex business and you will probably have to change some
  19. parameters later when you use PowerVisor.
  20.  
  21.  
  22. =========================== The 'mode' command ===============================
  23.  
  24. With the 'mode' command you can set some parameters. The 'mode' command
  25. expects any number of keywords. These keywords need not be in any
  26. particular order.
  27. The following keywords are supported :
  28.  
  29.    pal         set ¹monitor to ¹pal (only AmigaDOS 2.0)
  30.                the ¹non-interlaced resolution is 640x256 and the
  31.                ¹interlaced resolution is 640x512. This resolution will be
  32.                bigger if you use ¹overscan.
  33.    ntsc        set monitor to ¹ntsc (only AmigaDOS 2.0)
  34.                non-interlaced : 640x200
  35.                interlaced : 640x400
  36.    vga         set monitor to ¹vga (only AmigaDOS 2.0 and new denise)
  37.                non-interlaced : 640x480
  38.                interlaced : 640x960
  39.    viking      set monitor to ¹a2024 (only AmigaDOS 2.0)
  40.                resolution : 1024x1008
  41.  
  42.    lace        use ¹interlace
  43.    nolace      no interlace (default)
  44.  
  45.    fancy       use ²two bitplanes for the PowerVisor screen (default)
  46.    nofancy     use only ²one bitplane
  47.  
  48.    sbottom     include the ²size gadget in the ²bottom border. This means that
  49.                you loose a line but you gain some columns (default)
  50.    nosbottom   include the size gadget in the ²right border of the window.
  51.                You loose some columns but you gain a line or so
  52.  
  53.    space       add a space after a ²snapped word (default)
  54.    nospace     don't add a space. Simply snap the word as it is
  55.  
  56.    lonespc     snap a space if you click on an empty place in a logical
  57.                window
  58.    nolonespc   don't snap a space (default)
  59.  
  60.    shex        ³show hex words when ²disassembling instructions. The
  61.                disadvantage is that these words could overwrite the right
  62.                side of the ¹symbolname if present (default)
  63.    noshex      don't show hex words. Symbols will be completely visible
  64.  
  65.    dec         display all printed ¹integers as ²decimal only
  66.    hex         display all printed integers as ²hexadecimal only
  67.    hexdec      first display hex, than display decimal (default)
  68.  
  69.    more        enable ²-MORE- check for the 'Main' ²logical window (default)
  70.    nomore      disable -MORE- check
  71.  
  72.    auto        perform an ²automatic list whenever the ²current list changes
  73.    noauto      don't do this (default)
  74.  
  75.    byte        ²list memory as ¹bytes (for the 'memory' command)
  76.    word        list memory as ¹words
  77.    long        list memory as ¹longs (default)
  78.    ascii       list memory as ¹ascii
  79.  
  80.    fb          ¹feedback each command as it is typed in by the user on
  81.                the current logical window (default)
  82.    nofb        don't do this
  83.  
  84.    patch       ¹patch the Exec AddTask function. When this function is
  85.                patched by PowerVisor ¹crashtrapping will work better
  86.                for all new tasks created after the patch is applied.
  87.                This is recommended if you use ²resident breakpoints
  88.                (see the 'Debug' file). Note that it is not safe to
  89.                run other debuggers (like ¹CodeProbe or ¹MonAm) when
  90.                the patch is applied. They will probably crash when
  91.                you try to trace with them. There will (probably) be
  92.                no problems if you start the other debugger and load
  93.                the debug program with this debugger BEFORE you
  94.                apply the patch (before you start PowerVisor or before
  95.                you type 'mode patch'). (default)
  96.    nopatch     Don't patch the ²Exec AddTask function. When the ¹AddTask
  97.                function is not patched, PowerVisor will trap a crash
  98.                a bit later (too late if you plan to use resident
  99.                breakpoints). With the patch applied PowerVisor traps
  100.                crashes just on the spot while if the patch is not
  101.                applied PowerVisor will only trap the crash just before
  102.                the ¹guru would normally arrive (you will even have to
  103.                press 'cancel' on the ²'task-held' requester before
  104.                PowerVisor notices the crash). But 'mode nopatch' is
  105.                the only safe way to run ²other debuggers concurrently
  106.                with PowerVisor.
  107.  
  108. Example, to set everything other than default you can use :
  109.  
  110. < mode lace fancy nospace lonespc noshex dec nomore auto byte nofb nopatch
  111. <      <enter>
  112.  
  113. All the parameters set with the 'mode' command will be saved with the
  114. 'saveconfig' command (see later).
  115.  
  116.  
  117. =========================== The 'prefs' command ==============================
  118.  
  119. Using the 'prefs' command you can install some additional parameters.
  120. All parameters installable with the 'prefs' command will be saved when
  121. you use 'saveconfig'.
  122.  
  123.  
  124. =============== The maximum number of lines in the history ===================
  125.  
  126. Using 'prefs history' you can get or set the maximum number of lines in the
  127. history. The default is 20.
  128.  
  129. < prefs history <enter>
  130. > 00000014 , 20
  131.  
  132. You can set another value with :
  133.  
  134. < prefs history 500 <enter>
  135.  
  136. Note that the ²history buffer is dynamic. If there are 10 lines in the history
  137. buffer you only loose memory for 10 lines even if the maximum number of lines
  138. is 500.
  139.  
  140. The command also clears the history buffer.
  141.  
  142.  
  143. =========================== Some standard keys ===============================
  144.  
  145. Using 'prefs key' you can get or set ¹keycodes for standard keys. The
  146. following keys are supported :
  147.  
  148.    nr name                 default key           code    qualifier
  149.    -------------------------------------------------------------------------
  150.    0  interrupt key        <esc>                 045     0
  151.    1  hot key              <r-shift>+<r-alt>+'/' 03A     022
  152.    2  pause key            <r-alt>+<help>        05F     020
  153.    3  cycle active logwin  <tab>                 042     0
  154.    4  history up           <arrow up>            04C     0
  155.    5  history down         <arrow down>          04D     0
  156.  
  157. You can get the default using :
  158.  
  159. < prefs key 2 <enter>
  160. > 0000005F 00000020
  161.  
  162. Or you can set it to other values with :
  163.  
  164. < prefs key 0 16 0 <enter>
  165.  
  166. This command will set the interrupt key to the 'q' key (or the 'a' key
  167. if you have an AZERTY keyboard). This is only an example. I recommend
  168. that you choose better keys :-)
  169.  
  170. Here are some codes that are often used :
  171.  
  172.    <esc>                      045
  173.    <tab>                      042
  174.    <F1>                       050
  175.    .                          .
  176.    .                          .
  177.    .                          .
  178.    <F10>                      059
  179.    <backspace>                041
  180.    <help>                     05F
  181.    <del>                      046
  182.    <up>                       04C
  183.    <down>                     04D
  184.    <left>                     04F
  185.    <right>                    04E
  186.    <return>                   044
  187.    <enter> (numeric keypad)   043
  188.  
  189. Here are the ¹qualifers. You must add two qualifiers if you want to use
  190. a combination :
  191.  
  192.    Left shift              0001
  193.    Right shift             0002
  194.    Capslock                0004  (this one is ignored by PowerVisor)
  195.    Control                 0008
  196.    Left alt                0010
  197.    Right alt               0020
  198.    Left Amiga              0040
  199.    Right Amiga             0080
  200.  
  201.  
  202. ======================== Setting some startup bits ===========================
  203.  
  204. With 'prefs startup' you can get or set some ²startup bits. The startup
  205. variable is a longword. Only two bits are supported at this time.
  206.  
  207. bit 0     if true we start PowerVisor on the ²workbench screen
  208.           if this bit is true we ignore bit 1
  209. bit 1     if true we open the 'Main' physical window on a ¹non-backdrop
  210.           window instead of a ²backdrop window. This is equivalent to
  211.           the 'screen' command with argument 0.
  212.  
  213. Default is 0.
  214.  
  215. < prefs startup <enter>
  216. > 00000000 , 0
  217.  
  218. To set another value use :
  219.  
  220. < prefs startup 1 <enter>
  221.  
  222. You need to quit PowerVisor and start it again to see the result of this
  223. command.
  224.  
  225.  
  226. ===================== Setting the startup window size ========================
  227.  
  228. With 'prefs window' you can define the size of the 'Main' physical window
  229. to be used when it is not a ²backdrop window (only just after startup).
  230. This value is thus only used if the ²'startup' variable (see the previous
  231. section) is either 1 or 2.
  232.  
  233. The default is (0,0,640,200). Which is x = 0, y = 0, width = 640 and
  234. height = 200.
  235. You must not worry if the size is too big. PowerVisor will check and
  236. make the window smaller if it would not fit on the screen.
  237.  
  238. < prefs window <enter>
  239. > 00000000 , 0
  240. > 00000000 , 0
  241. > 00000280 , 640
  242. > 000000C8 , 200
  243.  
  244. Set new values with :
  245.  
  246. < prefs window 0 200 640 200 <enter>
  247.  
  248. You need to quit PowerVisor and start it again to see the result of this
  249. command.
  250.  
  251.  
  252. ===================== Setting the startup screen size ========================
  253.  
  254. With 'prefs screen' you can define the width and height of the PowerVisor
  255. screen. If you have AmigaDOS 2.0 you can use any size for the screen. If
  256. this size is big you can scroll by moving the mouse out of the visible part
  257. of the screen.
  258.  
  259. The default is (65535,65535) (or (-1,-1) as words).Which means that
  260. PowerVisor will take the default width and height for the screen.
  261.  
  262. < prefs screen <enter>
  263. > 0000FFFF , 65535
  264. > 0000FFFF , 65535
  265.  
  266. For example, to make the screenheight equal to 1024 use the following
  267. command :
  268.  
  269. < prefs screen -1 1024 <enter>
  270.  
  271. You need to quit PowerVisor and start it again to see the result of this
  272. command.
  273.  
  274.  
  275. ====================== Setting the stack fail level ==========================
  276.  
  277. With 'prefs stack' you can set or get the amount of ¹stackspace left before
  278. PowerVisor will halt the task and give a warning (only if account is on
  279. with the 'account' command).
  280. The default value is 40.
  281.  
  282. < prefs stack <enter>
  283. > 00000028 , 40
  284.  
  285. Change it with :
  286.  
  287. < prefs stack 80 <enter>
  288.  
  289. Be careful not to make it too big, or else all tasks will be stopped even
  290. if nothing is wrong.
  291.  
  292.  
  293. ================ Setting default logical window parameters ===================
  294.  
  295. Using 'prefs logwin' you can set or get default parameters for the standard
  296. logical windows ('Main', 'Extra', 'Refresh', 'Debug', 'Rexx' and 'PPrint').
  297.  
  298. Four values are remembered for each ³standard logical window :
  299.  
  300.    - the ³number of columns
  301.        - if 0 we scale the number of columns to the visible size at the
  302.          moment the logical window is created. After that the number of
  303.          columns is fixed
  304.        - if -1 we use horizontal autoscale. The number of columns is adapted
  305.          to the visible size everytime the horizontal visible size changes.
  306.          The disadvantage of this is that the logical window is cleared
  307.        - every other value sets a fixed number of columns
  308.    - the ³number of rows
  309.        - (like the number of columns)
  310.    - the ²flag mask
  311.    - the flag values in this mask
  312.  
  313. The following flags are supported (also see the 'Screen' chapter) :
  314. (bit 0/bit 1)
  315.    -MORE- disable/enable      4
  316.    top-visible/real-top       32
  317.    statusline on/off          64
  318.    interrupt on/off           128
  319.    auto output snap           256
  320. All other bits are used or reserved and should not be used in the mask.
  321.  
  322. For example. To set the ²-MORE- check off, the statusline off and leave
  323. all other flags as default you can use :
  324.    mask  = 4+64
  325.    value = 64
  326.  
  327. Or with -MORE- check on :
  328.    mask  = 4+64
  329.    value = 4+64
  330.  
  331. The following default values are used when a logical window is opened :
  332.    -MORE- disabled
  333.    ¹Interrupt/Pause enabled
  334.    ²Home position is top-visible
  335.    ²Status line on
  336.    ³Auto Output Snap off
  337.  
  338. The standard logical windows have the following defaults (Note that the
  339. -MORE- setting of the 'Main' logical window is dependent on the
  340. 'mode' command) :
  341.  
  342.    - Main      (0,0,160,0)
  343.                number of columns and rows is set to a fixed value. This value
  344.                is the maximum number of columns and rows at the time the
  345.                logical window is created.
  346.  
  347.                Interrupt/Pause enabled
  348.                Home position is top-visible
  349.                Auto Output Snap is on
  350.  
  351.    - Extra     (0,0,160,0)
  352.                number of columns and rows is set to a fixed value. This value
  353.                is the maximum number of columns and rows at the time the
  354.                logical window is created.
  355.  
  356.                Interrupt/Pause enabled
  357.                Home position is top-visible
  358.                Auto Output Snap is on
  359.  
  360.    - Refresh   (0,50,160,160)
  361.                the number of columns is set to a fixed value. This value is
  362.                the maximum number of columns at the time the logical window
  363.                is created. The number of rows is fixed and always set to
  364.                50.
  365.  
  366.                Interrupt/Pause disabled
  367.                Home position is real-top
  368.                Auto Output Snap is off
  369.  
  370.    - Debug     (82,42,160,160)
  371.                the number of columns is fixed and set to 82. The number of
  372.                rows is fixed and set to 42.
  373.  
  374.                Interrupt/Pause disabled
  375.                Home position is real-top
  376.                Auto Output Snap is off
  377.  
  378.    - Rexx      (0,50,160,128)
  379.                the number of columns is set to a fixed value. This value is
  380.                the maximum number of columns at the time the logical window
  381.                is created. The number of rows is fixed and always set to
  382.                50.
  383.  
  384.                Interrupt/Pause disabled
  385.                Home position is top-visible
  386.                Auto Output Snap is off
  387.  
  388.    - PPrint    (0,50,160,128)
  389.                the number of columns is set to a fixed value. This value is
  390.                the maximum number of columns at the time the logical window
  391.                is created. The number of rows is fixed and always set to
  392.                50.
  393.  
  394.                Interrupt/Pause disabled
  395.                Home position is top-visible
  396.                Auto Output Snap is off
  397.  
  398. To get the defaults :
  399.  
  400. < prefs logwin debug <enter>
  401. > 00000052 , 82
  402. > 0000002A , 42
  403. > 000000A0 , 160
  404. > 000000A0 , 160
  405.  
  406. To set other defaults :
  407.  
  408. < prefs logwin debug 100 50 160 160 <enter>
  409.  
  410. You need to quit PowerVisor and start it again to see the result of this
  411. command when applied to the 'Main' logical window. For all other logical
  412. windows you can simple close/open them to see the changes. You can also
  413. use the 'setflags' command to set the flags for a logical window
  414. immediatelly (also for 'Main'), and the 'colrow' command to set the
  415. ³number of columns and rows immediatelly.
  416.  
  417.  
  418. ===================== The default commandline length =========================
  419.  
  420. With 'prefs linelen' you can set or get the maximum length of the
  421. ²stringgadget commandline. This is also the maximum number of columns that
  422. may be used in ¹scripts (not ²ARexx scripts). The default is 400. Note that
  423. you loose 800 bytes with a linelength of 400 (always double).
  424.  
  425. To get the default :
  426.  
  427. < prefs linelen <enter>
  428. > 00000190 , 400
  429.  
  430. To set another value :
  431.  
  432. < prefs linelen 1000 <enter>
  433.  
  434. You need to quit PowerVisor and start it again to see the result of this
  435. command.
  436.  
  437.  
  438. ========================= Some debug preferences =============================
  439.  
  440. With 'prefs debug' you can set or get some preferences for the ¹debugger.
  441. The first argument is the ³number of instructions to disassemble after
  442. each ¹trace and the second argument is 0 or 1 if you want the disassemble
  443. the ²previous instruction (no or yes resp.) after each trace. The values
  444. set with this command are also used by the ²fullscreen debugger.
  445. Default is 5,1. This means 5 instructions and yes, disassemble the previous
  446. executed instruction too.
  447.  
  448. < prefs debug <enter>
  449. > 00050001 , 327681
  450.  
  451. You can set other values using :
  452.  
  453. < prefs debug 15 0 <enter>
  454.  
  455. (15 instructions and no previous instruction)
  456.  
  457.  
  458. =============================== Debug mode ===================================
  459.  
  460. Using 'prefs dmode' you can set the information that should be displayed
  461. after a trace. This parameter is not used by the ²fullscreen debugger since
  462. the fullscreen debugger always shows all information.
  463.  
  464. You can set the following parameters :
  465.  
  466.    n        show no info at all. This is useful when you are using the
  467.             fullscreen debugger and you do not want to be disturbed
  468.             by output on the current logical window
  469.    r        show only ¹registers
  470.    c        show only code (using the format describe in the previous
  471.             section)
  472.    f        show registers and code (default)
  473.  
  474. For example :
  475.  
  476. < prefs dmode n <enter>
  477.  
  478.  
  479. ============================= Installing pens ================================
  480.  
  481. Every color you see on the PowerVisor screen or window can be changed.
  482. You can do this with the 'color' command. This command changes the
  483. RGB values for a color. The disadvantage is of course that this change
  484. affects all uses of that color. But don't worry, PowerVisor gives you
  485. the option to change virtually every color. This is because PowerVisor
  486. uses a pen array (the idea is stolen from AmigaDOS 2.0) to access each
  487. color. Using 'prefs pens' you can view or change this pen array.
  488.  
  489. There are 32 ¹pens. The first 16 are for ²fancy screens (2 or more
  490. bitplane screens) and the last 16 are for 1 bitplane screens. The 16th pens
  491. for both the fancy and no-fancy screens are reserved for future use
  492. and are not displayed by this command.
  493.  
  494. With no arguments this command lists all pens on two lines: the
  495. first line containing all pens for fancy screens and the second
  496. line for no-fancy screens.
  497.  
  498. Here follow the currently defined pen numbers and there default
  499. color values. Add 16 to the pen number to get the no-fancy screen
  500. pen number :
  501.  
  502.    nr    name                 default fancy     default no-fancy
  503.    -------------------------------------------------------------
  504.    0     BoxBackground        0                 0
  505.    1     LogWinBackground     0                 0
  506.    2     NormalText           1                 1
  507.    3     PrompText            1                 1
  508.    4     StatusTextInActive   1                 1
  509.    5     StatusTextActive     2                 0
  510.    6     InActiveBar          0                 0
  511.    7     ActiveBar            3                 1
  512.    8     TopLeft3D            2                 1
  513.    9     BottomRight3D        1                 1
  514.    10    BoxLine              1                 1
  515.    11    PositionBox          0                 0
  516.    12    TopLeftBox           1                 1
  517.    13    BottomRightBox       2                 1
  518.    14    PositionIndicator    3                 1
  519.  
  520. (To see the effect of pen changes you should open/close your windows first.
  521. For most pens the effect is immediatelly visible)
  522.  
  523. The 'BoxBackground' pen is used to draw the background of a box (see the
  524. 'Screen' tutor file for more information about boxes). This pen color is
  525. usually the same as the 'LogWinBackground' pen explained below. If you
  526. insist on using another value you will see a small border in each of your
  527. logical windows. This small border will grow if you make the number of
  528. columns and lines in the logical window smaller than the visible size.
  529.  
  530. The 'LogWinBackground' pen is the background pen used in a logical window.
  531. This pen is only used on places where characters CAN appear. This explains
  532. the small border that you see when you change the 'BoxBackground' pen. The
  533. small border is the region of the logical windows where no characters can
  534. appear.
  535.  
  536. The 'NormalText' pen is used to print all text in logical windows. This
  537. pen should be different from 'LogWinBackground', otherwise you will see
  538. nothing.
  539.  
  540. The 'PromptText' pen is used to print the prompt (the current list
  541. indicator). This pen should be different from 'BoxBackground', otherwise
  542. the prompt will be invisible.
  543.  
  544. The 'StatusTextInActive' pen is used to print the name of the logical
  545. window in the logical window bar when the logical window is inactive
  546. (the active logical window is the window where you can scroll).
  547.  
  548. The 'StatusTextActive' pen is used to print the name of the logical window
  549. in the logical window bar when the logical window is active.
  550.  
  551. The 'InActiveBar' pen is used as background for the logical window bar
  552. when the logical window is inactive. This pen should be different from
  553. 'StatusTextInActive'.
  554.  
  555. The 'ActiveBar' pen is used as background for the logical window bar
  556. when the logical window is active. This pen should be different from
  557. 'StatusTextActive'.
  558.  
  559. The 'TopLeft3D' and 'BottomRight3D' pens are used for all 3D borders
  560. (at this moment only the border round the logical window bar uses these
  561. pens). The 'TopLeft3D' pen should be a light color and 'BottomRight3D'
  562. should be dark. This is to ensure the raised 3D effect of the border.
  563.  
  564. The 'BoxLine' pen is used to draw the line between horizontally arranged
  565. logical windows. It should be different from 'BoxBackground'.
  566.  
  567. The 'PositionBox' pen is used to draw the background of the position
  568. indicator at the right of the logical window bar.
  569.  
  570. The 'TopLeftBox' and 'BottomRightBox' pens are used for the recessed
  571. 3D border round the position indicator. Note that this border is
  572. dithered when PowerVisor is in no-fancy mode.
  573.  
  574. The 'PositionIndicator' pen is used for the little knob in the
  575. position indicator. This pen should be different from the 'PositionBox'
  576. pen.
  577.  
  578.  
  579. Example :
  580.  
  581.  
  582. < prefs pens <enter>
  583. > 0 0 1 1 1 2 0 3 2 1 1 0 1 2 3
  584. > 0 0 1 1 1 0 0 1 1 1 1 0 1 1 1
  585.  
  586.  
  587. Change the color of normal text to blue (or the color installed on
  588. color 3) :
  589.  
  590. < prefs pens 2 3 <enter>
  591.  
  592.  
  593. ============================= The config file ================================
  594.  
  595. All parameters set with the 'mode' or 'prefs' command can be saved using
  596. the 'saveconfig' command. This command will create a file called
  597. ¹s:PowerVisor-config. If this file is not present when PowerVisor starts,
  598. the default values are used.
  599.  
  600. Example :
  601.  
  602. < saveconfig <enter>
  603.  
  604.  
  605. ======================= Other installation factors ===========================
  606.  
  607. There are still other things that you can install. But these things are not
  608. saved in the s:PowerVisor-config file. If you want to set them automatically
  609. you'll have to include the right commands in the ¹s:PowerVisor-startup file.
  610. See the 'Scripts' tutor file for more information about scripts in general.
  611.  
  612.  
  613. =========================== Setting the colours ==============================
  614.  
  615. With the 'color' command you can set the default ¹colours for the PowerVisor
  616. screen.
  617.  
  618. Example, to get the ²3D colours used by ²Workbench 2.0 when you have opened
  619. PowerVisor on a ²2 bitplane screen you can use :
  620.  
  621. < color 0 10 10 10 <enter>
  622. < color 1 0 0 0 <enter>
  623. < color 2 15 15 15 <enter>
  624. < color 3 6 7 9 <enter>
  625.  
  626. If you use these values the 3D design (the ¹statusline) will be very nice.
  627.  
  628. You can't use the 'color' command when PowerVisor is on another screen.
  629.  
  630.  
  631. ============================== Setting fonts =================================
  632.  
  633. Using the 'setfont' command you can use another ¹font for a ²logical window.
  634. See the 'Screen' chapter for more information.
  635.  
  636.  
  637. ========================= Setting alias commands =============================
  638.  
  639. Using the ¹¹'alias' command you can ³define other commands.
  640. See the 'CommandReference' file for more details.
  641.  
  642.  
  643. Some extra examples :
  644.  
  645.  
  646. < alias lfd 'loadfd [] fd:[]_lib.fd' <enter>
  647.  
  648. You have defined a command 'lfd'. When you type something like :
  649.  
  650. < lfd exec <enter>
  651.  
  652. The command will be expanded and the following command will be executed :
  653.  
  654. < loadfd exec fd:exec_lib.fd <enter>
  655. > ...
  656.  
  657. This command loads an ¹fd-file in memory.
  658.  
  659.  
  660. < alias opwin '{openpw [] 0 0 300 200;openlw [] [] 80 40}' <enter>
  661.  
  662. Defines an alias 'opwin' that opens a ²physical window and a ²logical window
  663. in this physical window.
  664.  
  665.  
  666. Another (stupid) example :
  667.  
  668.  
  669. If you use the group operator in the alias string, alias expansion will
  670. be done again. So you can use aliases in an alias allowing for recursive
  671. alias definitions. The following two commands define a new command 'fact'
  672. to compute the facultaty of its argument :
  673.  
  674. < alias _fact 'void if(([])==1,1,{_fact ([])-1}*([]))' <enter>
  675. < alias fact 'disp {_fact []}' <enter>
  676.  
  677. < fact 5 <enter>
  678. > 00000078 , 120
  679.  
  680. '_fact' is the ²recursive alias. 'fact' is only provided to give a more
  681. command like syntax. Note that this recursion is limited by both
  682. the available stack (PowerVisor will give an error when the end of
  683. the stack is getting close) and the maximum length of the commandline
  684. (you can increase this maximum length with the 'prefs' command).
  685.  
  686.  
  687. If you want to use [] in the string you can use quotes :
  688.  
  689. < alias test 'print \\[\\]' <enter>
  690.  
  691. The first ²string expansion leads to the definition of 'test' as the command
  692. 'print \[\]'. The expansion done by 'print' leads to the correct execution.
  693.  
  694.  
  695. ======================= Attaching commands to keys ===========================
  696.  
  697. Using the 'attach' command you can ³³attach a command to a key.
  698.  
  699.  
  700. Example :
  701.  
  702.  
  703. To add the 'list' command to the <F1> key you can use :
  704.  
  705. < attach 'list' 050 0 <enter>
  706.  
  707. If you press <F1> 'list' is put on the stringgadget and an enter is
  708. simulated (this means that 'list' is also put in the history buffer).
  709.  
  710. If you do not want the stringgadget to be disturbed you can use :
  711.  
  712. < attach 'list' 050 0 e <enter>
  713.  
  714. Some other examples :
  715.  
  716. < attach '{pv 26 #{pv 12};pv 4;pv 5}' 046 32 e <enter>
  717.  
  718. This command defines the <r-alt>+<del> key. When you press this key
  719. the command currently in the stringgadget will be deleted from the
  720. ²history buffer. The 'pv' command is a shorthand for 'pvcall' and this
  721. is a command normally only provided for ¹wizards (see the last section
  722. of this chapter).
  723.  
  724. With 'remattach' you can remove ²key attachements.
  725.  
  726.  
  727. ============================= Logical windows ================================
  728.  
  729. Although there are already a lot of logical window parameters you can set
  730. with the 'prefs' command, there can be times that you need more. See the
  731. 'Screen' chapter to see how you can open logical and physical windows.
  732.  
  733. Here is an example :
  734.  
  735. This sequence of commands opens two extra logical and physical windows
  736. and ¹tile them in a certain fashion :
  737.  
  738. Make the 'Main' physical window a ²non-backdrop window :
  739. < screen 0 <enter>
  740. Go to two bitplane mode and interlace :
  741. < mode fancy lace <enter>
  742. Open two physical windows and two logical windows :
  743. < openpw debug 0 0 500 200 <enter>
  744. < openpw rexx 500 0 140 200 <enter>
  745. < openlw debug debug 82 42 <enter>
  746. < openlw rexx rexx 80 40 <enter>
  747. Size the main physical window :
  748. < size main 640 200 <enter>
  749. < move main 0 200 <enter>
  750.  
  751.  
  752. ============================== And last ... ==================================
  753.  
  754. And last for the maximum flexibility... the 'PVCALL' command !
  755.  
  756. Note that this command is not for the casual user. It is also not for the
  757. experienced PowerVisor user. It is for the PowerVisor ¹wizard :-)  !!!
  758.  
  759. See the 'TheWizardCorner' file if you think you are a wizard.
  760.