home *** CD-ROM | disk | FTP | other *** search
/ 5 Star Games: Animations / 5_STAR_GAMES.ISO / author / textscrn / sd.doc < prev    next >
Text File  |  1993-11-01  |  45KB  |  1,442 lines

  1.  
  2.  
  3.  
  4.  
  5.  
  6.  
  7.                        ┌────────────────────────────┐
  8.                        │                            │
  9.                        │   S C R E E N              │
  10.                        │                            │
  11.                        │         D E S I G N E R    │
  12.                        │                            │
  13.                        ├────────────────────────────┤
  14.                        │                            │
  15.                        │                            │
  16.                        │                            │
  17.                        │                            │
  18.                        │ User's Guide and Reference │
  19.                        │                            │
  20.                        │                            │
  21.                        │                            │
  22.                        │                            │
  23.                        │        Version 1.0         │
  24.                        │                            │
  25.                        │       November, 1993       │
  26.                        │                            │
  27.                        └────────────────────────────┘
  28.  
  29.  
  30.  
  31.  
  32.  
  33.  
  34.  
  35.  
  36.  
  37.  
  38.  
  39.  
  40.                           Direct correspondence to:
  41.  
  42.                                  Gary Ivany
  43.                                197 Jubilee Rd.
  44.                                  Bridgewater
  45.                              Nova Scotia, Canada
  46.                                    B4V-3G5
  47.  
  48.  
  49.  
  50.  
  51.                        Copyright 1993  by  Gary Ivany
  52.  
  53.  
  54.  
  55.         Screen Designer's User's Guide
  56.       ─────────────────────────────────────────────────────────────────────
  57.  
  58.  
  59.         Table of Contents
  60.  
  61.  
  62.              What is Screen Designer           2
  63.  
  64.              System Requirements               2
  65.  
  66.              Features                          2
  67.  
  68.              Getting started                   3
  69.  
  70.              User Interface                    3
  71.  
  72.              Menu Functions Overview           5
  73.  
  74.              Menu Functions Details            7
  75.  
  76.              Programming examples             13
  77.  
  78.              Registration                     17
  79.  
  80.              Brief Guided Tour                18
  81.  
  82.              Disclaimer                       21
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.                    
  110.  
  111.  
  112.  
  113.  
  114.  
  115.                                                                    Page - 1
  116.  
  117.  
  118.         Screen Designer's User's Guide
  119.       ─────────────────────────────────────────────────────────────────────
  120.  
  121.  
  122.         What is Screen Designer
  123.  
  124.  
  125.              Screen Designer is a MOUSE DRIVEN utility for creating
  126.         text screens.  It can be used for developing any type of
  127.         text display your programs require. (I.e., user-input
  128.         screens, menus, Title screens, etc.)
  129.  
  130.              This utility gives you an environment to prototype text
  131.         screens quickly and easily.  You can compile your screens
  132.         into object modules for linking directly into your
  133.         application.  I find that I am using this tool more and more
  134.         in the early development stages of a project to quickly
  135.         generate output and data entry screens.  This allows me to
  136.         obtain customer input in the early stages of the development
  137.         process.
  138.  
  139.         * See pages 18 - 20 for a brief guided tour *
  140.  
  141.         Features:
  142.  
  143.  
  144.                     **  Creates self displaying  screens  in .COM
  145.                         and .OBJ  format
  146.  
  147.                     **  Save and load screen images in  different
  148.                         formats
  149.  
  150.                     **  Friendly User Interface with on-line help
  151.  
  152.  
  153.  
  154.  
  155.  
  156.         System Requirements:
  157.  
  158.                    IBM Compatible computer
  159.  
  160.                    DOS v2.x or newer
  161.  
  162.                    Mouse
  163.  
  164.                    CGA video card (or better)
  165.  
  166.  
  167.  
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.                    
  178.                                                                    Page - 2
  179.  
  180.  
  181.         Screen Designer's User's Guide
  182.       ─────────────────────────────────────────────────────────────────────
  183.  
  184.  
  185.       Getting Started:
  186.  
  187.         Start the "Screen Designer" by changing to the directory
  188.         where SD is located, typing SD and pressing <ENTER>.  You
  189.         can specify the file you wish to work on from the command
  190.         line as follows:    SD [filename]
  191.                   Where filename can be a "SCN, MEM,
  192.                   or BIN" file or a file in ASCII format.
  193.  
  194.         The first screen you are presented with contains a menu bar
  195.         across the top and a status bar across the bottom.
  196.         Menu selections are be made by moving the mouse cursor over
  197.         the desired choice and clicking the left button.  This opens
  198.         a drop-down menu and presents you with a sub-menu.  Clicking
  199.         on your choice from the sub-menu selects the item.  You can
  200.         also click and hold the left mouse button on the main menu
  201.         then move the mouse vertically to highlight the desired sub
  202.         menu selection.  Releasing the button selects the
  203.         highlighted item.
  204.  
  205.         (Once any menu or hot-key function is selected then the
  206.         title screen will clear to bright white on blue.)
  207.  
  208.       User-Interface:
  209.  
  210.         Using the keyboard, press <[ALT]> to light up the "File"
  211.         selection on the main menu bar.  Pressing the first letter
  212.         of a main menu item opens its associated pull-down menu.
  213.         Selections within the pull down menu can be made by pressing
  214.         the highlighted letter or using the cursor keys to highlight
  215.         your choice and pressing <Enter>.  Most sub-menu selections
  216.         have a shortcut KEY that allows that selection without
  217.         moving through the menus.  NOTE: These shortcut keys are
  218.         only available when in MENU MODE (see status bar) and the
  219.         menu bar is not highlighted.
  220.  
  221.              Shortcut Keys:
  222.                     B    Single line box drawing mode
  223.                     X    Double line box drawing mode
  224.                     T    Normal text mode
  225.                     L    Large text mode
  226.                     F    Fill selection area with current char and
  227.                          attribute pair
  228.                     E    Erase selection area to current background
  229.                     M    Move
  230.                     C    Copy
  231.                     P    Paste
  232.                     U    Undo
  233.                     R    Re-color
  234.                     V    Re-color (selective)
  235.                     W    Search and replace
  236.                     S    Swap screen
  237.  
  238.  
  239.  
  240.  
  241.                                                                    Page - 3
  242.  
  243.  
  244.         Screen Designer's User's Guide
  245.       ─────────────────────────────────────────────────────────────────────
  246.  
  247.  
  248.  
  249.       User-Interface Cont...
  250.  
  251.         There are also several hot keys available at all times
  252.         except when the menu bar is activated.
  253.  
  254.              Hot Keys:
  255.                     [F1] On-line help, sensitive to the current mode.
  256.                     [F2] Pops up the control bar
  257.                     [F3] Undo last edit
  258.                     [F4] Toggle Smart lines
  259.                     [F5] Toggle box shadows
  260.                     [F6] Toggle box & text fill
  261.                     [F7] Set current colors to those under cursor
  262.                     [F8] Set FILL character to character under cursor
  263.  
  264.         General Mouse Control
  265.  
  266.         The mouse is used to select starting and end positions for
  267.         regions when in editing modes. Hold the left-button and
  268.         'rubber band' the highlights to define a working area. In
  269.         all cases the right button is used to either abort the
  270.         current process and/or to exit the current mode. (The <ESC>
  271.         key will also abort processes)
  272.  
  273.              IMPORTANT NOTE: For some modes the only way back to the
  274.              menu bar is by pressing the right mouse button or <ESC>.
  275.  
  276.  
  277.  
  278.  
  279.  
  280.  
  281.  
  282.  
  283.  
  284.  
  285.  
  286.  
  287.  
  288.  
  289.  
  290.  
  291.  
  292.  
  293.  
  294.  
  295.  
  296.  
  297.  
  298.  
  299.  
  300.  
  301.  
  302.  
  303.  
  304.                                                                    Page - 4
  305.  
  306.  
  307.         Screen Designer's User's Guide
  308.       ─────────────────────────────────────────────────────────────────────
  309.  
  310.  
  311.  
  312.         MAIN MENU OVERVIEW
  313.  
  314.         FILE MENU
  315.                LOAD      Loads a screen file into memory.
  316.                SAVE      Saves current screen to file using current
  317.                          file type.
  318.                SAVE AS        Saves current screen to file using
  319.                               selected file type.
  320.                CREATE COM     Creates a self-displaying screen
  321.                               "COM" file.
  322.                CREATE OBJ     Creates a linkable self-displaying screen.
  323.                DOS       Enters DOS shell. (type EXIT to return to
  324.                          program)
  325.                EXIT      Normal exit from program.
  326.  
  327.         OPTIONS MENU
  328.                VIEW SCREEN         Removes menu, status bar and
  329.                                    mouse cursor from screen.
  330.                CONTROL WINDOW      This option calls up the control
  331.                                    window.
  332.                LOAD FONT           Allows loading of large fonts
  333.                                    to replace default.
  334.                SHADOWS             Toggle BOX shadows
  335.                SMART LINES         Toggle SMART LINES
  336.                FREEZE MENU COLOR   Allow menus to change color to
  337.                                    currently selected colors.
  338.                STATUS BAR          Toggle STATUS BAR  ON/OFF (on by
  339.                                    default)
  340.  
  341.         DRAW SUB-MENU
  342.                SINGLE BOX        Draws boxes or lines using single line
  343.                                  box characters from extended
  344.                                  ASCII character set.
  345.                DOUBLE BOX        Draws boxes or lines using double
  346.                                  line box characters from
  347.                                  extended ASCII character set.
  348.                TEXT              Rudimentary text editing (normal size).
  349.                LARGE TEXT        Same as above but uses large characters .
  350.                FILL              Overwrites portions of the screen with the
  351.                                  currently selected FILL character in the
  352.                                  current color.
  353.                ERASE             Overwrites screen area with spaces in
  354.                                  (uses the current background color).
  355.  
  356.  
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.                                                                    Page - 5
  368.  
  369.  
  370.         Screen Designer's User's Guide
  371.       ─────────────────────────────────────────────────────────────────────
  372.  
  373.  
  374.         MAIN MENU OVERVIEW CONT...
  375.  
  376.         EDIT MENU
  377.                MOVE             Moves selected region of screen to
  378.                                 new position
  379.                COPY             Copies selected region of screen to
  380.                                 a buffer
  381.                PASTE            Paste COPY buffer to screen.
  382.                UNDO             Removes the latest changes to the
  383.                                 screen.
  384.                RECOLOR          Recolors screen region to the
  385.                                 current color.
  386.                RECOLOR SELECTIVE     Replace specific colors in a
  387.                                      selected region.
  388.                REPLACE CHARACTER     Replace specific characters in a
  389.                                      region.
  390.                CLEAR SCREEN     Clears the screen.
  391.                SWAP SCREEN      Swaps current screen with
  392.                                 alternate screen.
  393.  
  394.         HELP MENU
  395.                ABOUT          Displays the author and revision
  396.                               number of program.
  397.                GENERAL        Outlines brief help on menu navigation and
  398.                               hot keys.
  399.  
  400.  
  401.  
  402.  
  403.  
  404.  
  405.  
  406.  
  407.  
  408.  
  409.  
  410.  
  411.  
  412.  
  413.  
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.                                                                    Page - 6
  431.  
  432.  
  433.         Screen Designer's User's Guide
  434.       ─────────────────────────────────────────────────────────────────────
  435.  
  436.  
  437.         MAIN MENU DETAILS
  438.  
  439.  
  440.         FILE MENU
  441.                LOAD - The program displays a dialog box that is
  442.                used to display a selection of files.  Files with a
  443.                "SCN, BIN, MEM and TXT" extensions are displayed by
  444.                default although the FILENAME input box may be used
  445.                to change the display mask.  NOTE: Deleting the
  446.                contents of the FILENAME input box and pressing the
  447.                OK button will re-display the files matching the
  448.                default extensions.
  449.  
  450.                SAVE - The currently displayed screen is saved to
  451.                disk in the current format using the CURRENT
  452.                FILENAME.  If 'UNTITLED' appears in the filename
  453.                section of the status bar, you are placed in the
  454.                SAVE AS dialog box described below.
  455.  
  456.                SAVE AS - The SAVE-AS dialog box is similar to the
  457.                LOAD dialog box.  There is a filename input box
  458.                (containing the default file extension mask *.SCN),
  459.                a file display box (displaying all the files within
  460.                the current directory matching the mask), a box
  461.                describing the directories and drives available, a
  462.                selection of file formats to use (Normal - .SCN,
  463.                Basic - .BIN, Clipper - .MEM, ASCII Text - .TXT) and
  464.                buttons to accept (OK), cancel (CANCEL) or request
  465.                help on this dialog box (HELP).
  466.  
  467.                CREATE COM - Creates a self-displaying screen file
  468.                that can be used in a batch file or simply run from
  469.                DOS. (see batch file examples on page 15)
  470.  
  471.                CREATE OBJ - Creates a Microsoft format, Object module
  472.                that contains a compressed screen image. These modules
  473.                are self-displaying and can be used from several languages.
  474.                See the programming examples listed on pages 13 to 16.
  475.  
  476.                DOS - Enters DOS shell. (type EXIT to return to
  477.                program)
  478.  
  479.                EXIT - Normal exit from program.
  480.         OPTIONS MENU
  481.                VIEW SCREEN - Removes menu, status bar and mouse
  482.                cursor from screen, allowing you an unobstructed
  483.                view of your screen design. Press any key or mouse
  484.                button to return to the main menu.
  485.  
  486.  
  487.  
  488.  
  489.  
  490.  
  491.  
  492.  
  493.                                                                    Page - 7
  494.  
  495.  
  496.         Screen Designer's User's Guide
  497.       ─────────────────────────────────────────────────────────────────────
  498.  
  499.  
  500.  
  501.         OPTIONS MENU CONT...
  502.  
  503.                CONTROL WINDOW - This option calls up the control
  504.                window.  The control window consists of 2 main
  505.                sections.  The top portion of the window is labeled
  506.                SELECT FILL.  It is used to select the fill
  507.                character for the FILL command in the EDIT menu.
  508.                The lower section of the control window is labeled
  509.                SELECT COLOR.  It is used to select the foreground
  510.                and background colors.  The space character is the
  511.                default FILL character and is set on program
  512.                startup.  To select the fill character, simply click
  513.                the left button of the mouse on the character
  514.                desired.  Immediately below this section is a line
  515.                displaying an example of the current fill character
  516.                in the current color.
  517.  
  518.                The top multicolor bar in the SELECT COLOR area
  519.                selects the foreground color; the lower bar selects
  520.                background color.   To the right of the background
  521.                bar is the label 'BLINKING'.   The gray section here
  522.                is a toggle to control the blinking attribute.  A
  523.                small sample window on the right shows the current
  524.                colors.
  525.  
  526.                The STATUS bar automatically becomes visible when
  527.                the control window is opened.  The "SMART", "SHADOW"
  528.                and "FILL"  text now become toggle buttons to adjust
  529.                those features of the BOX modes.  All selections are
  530.                made the same way, by left-clicking the mouse.
  531.  
  532.                Once you are satisfied with your choices then you
  533.                exit the window by right-clicking the mouse or by
  534.                pressing <ESC>.
  535.  
  536.                SHADOWS -      When enabled, boxes will be drawn
  537.                with a shadow that extends two characters to the
  538.                right and one character below them.
  539.  
  540.                SMART LINES - When enabled, line characters  will be
  541.                replaced with characters that allow the lines to
  542.                join, if such a character exists.
  543.  
  544.                FREEZE MENU COLOR - This command allows you to
  545.                determine whether or not the menu colors indicate
  546.                current color selection. Useful if you would like to
  547.                change the menu colors. i.e. change colors then
  548.                freeze menu color again
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.                                                                    Page - 8
  557.  
  558.  
  559.         Screen Designer's User's Guide
  560.       ─────────────────────────────────────────────────────────────────────
  561.  
  562.  
  563.  
  564.         OPTIONS MENU CONT...
  565.  
  566.                STATUS BAR -   Toggle display of STATUS BAR (on by
  567.                default).  The following items are indicated on the
  568.                status bar:
  569.  
  570.                  FILL      Displays the current fill character and
  571.                            color.
  572.  
  573.                  MODE      Indicates the current mode of operation
  574.                   (i.e. Menu, Controls, Load Font, Single Box,
  575.                   Double Box, Text, Fill, Erase, Move, Copy, Paste,
  576.                   Recolor, Swap Color, Swap Character, About, and
  577.                   Help).  It also indicates when the program is
  578.                   loading, saving and creating Com or Object files.
  579.  
  580.                  SMART     Indicator of SMART LINES status, bright
  581.                            is on.
  582.  
  583.                  SHADE     Indicator of box SHADOWS status, bright
  584.                            is on.
  585.  
  586.                  FILL      Indicator of FILL status (for text/boxes)
  587.  
  588.                  R   C     Are the mouse's current screen row & column.
  589.  
  590.  
  591.  
  592.  
  593.  
  594.  
  595.  
  596.  
  597.  
  598.  
  599.  
  600.  
  601.  
  602.  
  603.  
  604.  
  605.  
  606.  
  607.  
  608.  
  609.  
  610.  
  611.  
  612.  
  613.  
  614.  
  615.  
  616.  
  617.  
  618.  
  619.                                                                    Page - 9
  620.  
  621.  
  622.         Screen Designer's User's Guide
  623.       ─────────────────────────────────────────────────────────────────────
  624.  
  625.  
  626.  
  627.         DRAW MENU
  628.  
  629.                SINGLE BOX - Draws boxes using single line
  630.                characters.  Click and hold the left mouse button at
  631.                the beginning of the box.  Drag the mouse cursor,
  632.                which has changed to dotted lines, to where you wish
  633.                to end the box and let go of the left mouse button.
  634.                Pressing the right mouse button, or the [Escape] key
  635.                during this process aborts it. The box /line drawing
  636.                modes are affected by the three toggles Smart,
  637.                Shade, Fill. (see the options menu descriptions)
  638.  
  639.                DOUBLE BOX - Draws boxes using double line
  640.                characters.
  641.  
  642.                TEXT  MODES - A very basic TEXT placement function.
  643.                Position the mouse cursor on the screen where you
  644.                wish to begin typing.  Click the left mouse button,
  645.                or begin to type your text.  Text will wrap around
  646.                to the next line down if you arrive at the end of
  647.                the line.  Word wrapping is not supported at this
  648.                time.  The following is a brief description of  the
  649.                effect of various keys:
  650.                  Enter -        Moves the cursor to the beginning
  651.                                 of the next line down.
  652.                  Arrows -       Moves the cursor left, right, up
  653.                                 or down one character.
  654.                  Tab -          Moves the cursor 8 characters to
  655.                                 the right (or the end of the line,
  656.                                 whichever is less).
  657.                  Shift tab -    Moves the cursor 8 characters to
  658.                                 the left (or the beginning of the line,
  659.                                 whichever is less).
  660.                  PgUp -         Moves the cursor to the top line,
  661.                                 same column.
  662.                  PgDn -         Moves the cursor to the bottom
  663.                                 line, same column.
  664.                  Home -         Moves the cursor to the beginning of the
  665.                                 current line.
  666.                  End -          Moves the cursor to the end of the
  667.                                 current line.
  668.                  Ctrl Home -    Moves the cursor to the upper left
  669.                                 corner of the screen.
  670.                  Ctrl End -     Moves the cursor to the lower right
  671.                                 corner of the screen.
  672.                  Delete -       Deletes the character under the cursor.
  673.                  Backspace -    Moves the cursor left and erases
  674.                                 the character in that position.
  675.                  Escape -       Exits the text editing mode (the right
  676.                                 mouse button is the same as the Escape key).
  677.  
  678.  
  679.  
  680.  
  681.  
  682.                                                                    Page - 10
  683.  
  684.  
  685.         Screen Designer's User's Guide
  686.       ─────────────────────────────────────────────────────────────────────
  687.  
  688.  
  689.  
  690.              TEXT MODES CONT...
  691.  
  692.                Text writing to the screen is affected by the status
  693.                of the FILL flag.
  694.                When fill is enabled then text is displayed
  695.                normally.
  696.                When it is disabled then small text is displayed
  697.                using the current foreground color on the existing
  698.                screen background color. Large font text
  699.                is displayed using the current foreground color and
  700.                the existing background colors , as well any space
  701.                characters in the font are not displayed, giving you
  702.                an overlaid effect.
  703.              FILL - Select the area of the screen you wish to work
  704.                with by clicking and holding the left mouse button on one
  705.                corner and dragging the mouse to the other corner.
  706.                Releasing the left mouse button will FILL the enclosed area
  707.                with the current FILL character in the current foreground
  708.                and background colors.  Pressing the right mouse button
  709.                while in the process of selecting a screen area will abort
  710.                the operation.
  711.  
  712.         EDIT MENU
  713.                MOVE - Select the area of the screen you wish to
  714.                MOVE by clicking and holding the left mouse button
  715.                on one corner and dragging the mouse to the other
  716.                corner.  Releasing the left button cuts the selected
  717.                portion from the screen.  The cut portion now
  718.                follows the mouse cursor.  Pressing the left button
  719.                again will PASTE the cutting in the current mouse
  720.                position.  The area left behind by the cutting is
  721.                filled with spaces using the current background
  722.                color.
  723.  
  724.                COPY - Select the area of the screen you wish to
  725.                COPY by clicking and holding the left mouse button
  726.                on one corner and dragging the mouse to the other
  727.                corner.  Releasing the left button copies the
  728.                selected portion of the screen to a buffer.  The
  729.                copied portion now follows the mouse cursor.
  730.                Pressing the left button again will PASTE the copy
  731.                buffer in the current mouse position and return you
  732.                to copy mode.  You must push the right mouse button
  733.                or the escape key to return to menu mode.  Pushing
  734.                the right mouse button while selecting a screen area
  735.                will abort the operation and return to menu mode.
  736.  
  737.                PASTE - This command is not available until the COPY
  738.                buffer has been filled by the COPY command.
  739.                Pressing the left button will PASTE the contents of
  740.                the copy buffer on the screen at the current mouse
  741.                position.  You must push the right mouse button or
  742.                the escape key to exit the PASTE mode and return to
  743.                MENU mode.
  744.  
  745.                                                                    Page - 11
  746.  
  747.  
  748.         Screen Designer's User's Guide
  749.       ─────────────────────────────────────────────────────────────────────
  750.  
  751.  
  752.  
  753.                UNDO - The UNDO command cycles backwards through a
  754.                circular buffer.  This circular buffer holds up to 9
  755.                of the latest screen changes.  The UNDO command is
  756.                accessed in one of three ways:
  757.                     1.By navigating through the Menus - [ALT]-
  758.                        (activate menu bar), [E]-(open Edit drop down
  759.                        menu), and [U] - (undo last edit)
  760.                     2.By using the Menu shortcut key 'U'
  761.                     3.By using the [F3] hot key.
  762.                (I find the [F3] hot key to be the method of choice
  763.                since it is available in all the editing modes and
  764.                does not require you to exit the current mode to
  765.                activate it).
  766.  
  767.                RECOLOR - Select the target area in the usual
  768.                manner.  Upon releasing the left mouse button the
  769.                target area will be recolored to the current color
  770.                selections (indicated by the FILL character example
  771.                on the status bar).
  772.  
  773.                RECOLOR SELECTIVE - This command works the same as
  774.                the RECOLOR command except  It requires you to
  775.                select a color to be replaced by the current colors.
  776.  
  777.                REPLACE CHARACTER - This command works similar to
  778.                the RECOLOR SELECTIVE command.  A character is
  779.                chosen from within the target area.  All occurrences
  780.                of this character are replaced with the current FILL
  781.                character in their existing colors.
  782.  
  783.                CLEAR SCREEN - Clears the screen to the current
  784.                colors.
  785.  
  786.                SWAP SCREEN - This command swaps your current screen
  787.                with the one stored in the alternate screen storage
  788.                area.  The status bar has a colored triangle
  789.                adjacent to the MODE: section to indicate which
  790.                screen is currently displayed.  The RED or BLUE
  791.                triangle on the status bar changes state whenever a
  792.                swap is made.  The primary purpose for this feature
  793.                is to provide an additional screen area to allow
  794.                cutting and pasting between two screens.
  795.  
  796.                Interestingly enough, because I have used a
  797.                different page of the video buffer to store the
  798.                alternate screen, it is possible to rerun the
  799.                program and find the alternate screen still contains
  800.                an image from a previous session.
  801.  
  802.  
  803.  
  804.  
  805.  
  806.  
  807.  
  808.                                                                    Page - 12
  809.  
  810.  
  811.         Screen Designer's User's Guide
  812.       ─────────────────────────────────────────────────────────────────────
  813.  
  814.  
  815.         Programming Examples:
  816.  
  817.         I've included some programming examples for various
  818.         languages, this is not to say that the object modules
  819.         created by this application can not be used by other
  820.         languages. Most certainly the SCN files can be used by any
  821.         language capable of loading in binary data and moving it to
  822.         screen memory.
  823.         Because the screen image files are not compressed  it leaves
  824.         you full flexibility to go at these files with whatever
  825.         tools you have at your disposal.
  826.  
  827.         Borland C:
  828.         /* EXAMPLE #1
  829.         This program will display a compressed screen image linked
  830.         in as an object module.
  831.         */
  832.         void pascal far ObjName (void);
  833.  
  834.         void main (void)
  835.         {
  836.              /* this is the only line required to display the screen
  837.              */
  838.              ObjName();
  839.         }
  840.  
  841.  
  842.         /* EXAMPLE #2
  843.         This example program will load in a 4k screen image file and
  844.         put it to video memory.
  845.         */
  846.  
  847.         #include <stdio.h>
  848.         #include <mem.h>
  849.         #include <dos.h>
  850.  
  851.         void main()
  852.         {
  853.            size_t bytes_read;
  854.            char buffer[4000];
  855.            char far * ptr;
  856.            FILE *filestream;
  857.  
  858.  
  859.            filestream = fopen("title.scn","r");
  860.            if(filestream ){
  861.               bytes_read = fread(buffer,1,4000,filestream);
  862.               if(bytes_read == 4000)
  863.                 ptr= _fmemcpy((void far*) MK_FP(0xB800,0),(char far *)
  864.                 buffer,4000);
  865.               fclose(filestream);
  866.            }
  867.         }
  868.  
  869.  
  870.  
  871.                                                                    Page - 13
  872.  
  873.  
  874.         Screen Designer's User's Guide
  875.       ─────────────────────────────────────────────────────────────────────
  876.  
  877.         Programming Examples: (continued)
  878.  
  879.         Microsoft C:
  880.  
  881.         /* EXAMPLE #1
  882.         This program will display a compressed screen image linked
  883.         in as an object module.
  884.         */
  885.         void pascal far ObjName (void);
  886.  
  887.         void main (void)
  888.         {
  889.              /* this is the only line required to display the screen
  890.              */
  891.              ObjName();
  892.         }
  893.  
  894.  
  895.         /*EXAMPLE #2
  896.         This example program will load in a 4k screen image file and
  897.         put it to video memory.
  898.         */
  899.  
  900.         #include <stdio.h>
  901.         #include <memory.h>
  902.         void main()
  903.         {
  904.            size_t bytes_read;
  905.            char buffer[4000];
  906.            char far * ptr;
  907.            FILE *filestream;
  908.  
  909.  
  910.            filestream = fopen("title.scn","r");
  911.            if(filestream ){
  912.               bytes_read = fread(buffer,1,4000,filestream);
  913.               if(bytes_read == 4000)
  914.                   ptr= _fmemcpy((void far*) 0xB8000000,(char far *)
  915.                   buffer,4000);
  916.               fclose(filestream);
  917.            }
  918.         }
  919.  
  920.  
  921.  
  922.  
  923.  
  924.  
  925.  
  926.  
  927.  
  928.  
  929.  
  930.  
  931.  
  932.  
  933.  
  934.                                                                    Page - 13
  935.  
  936.  
  937.         Screen Designer's User's Guide
  938.       ─────────────────────────────────────────────────────────────────────
  939.  
  940.         Programming Examples: (continued)
  941.  
  942.         QuickBASIC, Qbasic:
  943.  
  944.                  In your QuickBasic / QBasic program...
  945.  
  946.                     BLOAD "filename.bin"
  947.  
  948.                  This will load the file directly to video memory.
  949.  
  950.         Due to the inability of QBasic to use libraries / quick
  951.         libraries, the following applies to QuickBasic only...
  952.              Declare Sub ObjName()
  953.              ...
  954.              ...
  955.              ObjName: REM this will display the screen stored in the
  956.         Object file
  957.  
  958.         Note:
  959.              When building your EXE file from the command line,
  960.         remember to link in the screen's object  file.
  961.              If working from within the environment, the screen's
  962.         object file must be stored in a Library then linked into a
  963.         Quick library.
  964.  
  965.  
  966.         CLIPPER (summer87 & 5.x):
  967.  
  968.              To display screens stored in object format from within
  969.         a Clipper program you simply call them like you would any
  970.         other function.  Since there are no parameters to pass to
  971.         the function, the Extend system is not needed.  Remember to
  972.         include the screen object file in the link list.
  973.  
  974.         example #1:
  975.              call entryfrm
  976.              // this program displays the file saved as ENTRYFRM.OBJ
  977.  
  978.              The screens generated for Clipper are actually stored
  979.         in a memory file.  In this memory file is a PUBLIC VARIABLE
  980.         called M_RESTORE.  The contents of  M_RESTORE would be
  981.         identical to the return value of  SAVESCREEN(0,0,24,79)
  982.         so therefore it would be easy to
  983.         RESTSCREEN(0,0,24,79,M_RESTORE) to display the screen.
  984.  
  985.         example #2:
  986.              restore from "title.mem" additive
  987.              //  if more than one screen is to be loaded then copy
  988.              //  M_restore to another string variable first.
  989.              restscreen(0,0,24,79,M_RESTORE)
  990.              // an alternate syntax would be
  991.              // RESTORE SCREEN FROM M_RESTORE
  992.              M_RESTORE = ""
  993.              // optionally release the 4k of memory
  994.              //  this program will display the screen file, Title.mem
  995.  
  996.  
  997.                                                                    Page - 14
  998.  
  999.  
  1000.         Screen Designer's User's Guide
  1001.       ─────────────────────────────────────────────────────────────────────
  1002.  
  1003.  
  1004.         Programming Examples: (continued)
  1005.  
  1006.         BATCH FILES:
  1007.  
  1008.         Perhaps you could create a colorful menuing system by use of
  1009.         one or more screens.  Another use could be to pre-load title
  1010.         screens for display, while an application is initializing.
  1011.  
  1012.           Example #1:
  1013.               To display a screen and wait for a keypress.
  1014.                         @ ECHO OFF
  1015.                         NOCURS.COM
  1016.                         MENU.COM
  1017.                         GETKEY.COM
  1018.                         NORMCURS.COM
  1019.                         CLS
  1020.  
  1021.          Example #2:
  1022.              To interpret keypress from user,  DOS 6 REQUIRED.
  1023.  
  1024.                      @ECHO OFF
  1025.                      NOCURS.COM
  1026.                      CHOICE /C:ABCD /N
  1027.                      IF ERRORLEVEL 4 GOTO CHOICE4
  1028.                      IF ERRORLEVEL 3 GOTO CHOICE3
  1029.                      IF ERRORLEVEL 2 GOTO CHOICE2
  1030.                      IF ERRORLEVEL 1 GOTO CHOICE1
  1031.                      REM NO CHOICE MADE
  1032.                      GOTO EXIT
  1033.                      :CHOICE1
  1034.                      REM USER PUSHED 'A' KEY
  1035.                      GOTO EXIT
  1036.                      :CHOICE2
  1037.                      REM USER PUSHED 'B' KEY
  1038.                      GOTO EXIT
  1039.                      :CHOICE3
  1040.                      REM USER PUSHED 'C' KEY
  1041.                      GOTO EXIT
  1042.                      :CHOICE4
  1043.                      REM USER PUSHED 'D' KEY
  1044.                      :EXIT
  1045.                      NORMCURS.COM
  1046.  
  1047.  
  1048.  
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054.  
  1055.  
  1056.  
  1057.  
  1058.  
  1059.  
  1060.                                                                    Page - 15
  1061.  
  1062.  
  1063.         Screen Designer's User's Guide
  1064.       ─────────────────────────────────────────────────────────────────────
  1065.  
  1066.         LARGE TEXT FONTS:
  1067.  
  1068.         The large text fonts are simply just matrices of ASCII
  1069.         characters.  Each font can have it's own height and width
  1070.         (all fonts are non-proportional).  I've opted to have only
  1071.         one font loaded at runtime, DEFAULT.FNT.  Other fonts are
  1072.         available to be loaded through the options menu.  Of course
  1073.         if you prefer to have a different font as the default then
  1074.         simply rename the files.  This first release of the program
  1075.         does not include a font editor, I think I'll wait and see
  1076.         what response I get before investing more time down this
  1077.         avenue.  For anyone who would like to create their own fonts
  1078.         the following breakdown of the font file structure should
  1079.         assist you.
  1080.  
  1081.              Font file structure...
  1082.  
  1083.                 ┌───┬───┬───┬───┬─────────────────────────────┐
  1084.                 │ 1 │ 2 │ 3 │ 4 │     ASCII characters        │
  1085.                 └───┴───┴───┴───┴─────────────────────────────┘
  1086.  
  1087.                   byte #1  = height of font
  1088.                   byte #2  = width of font
  1089.                   byte #3  = ASCII value of first character
  1090.                   byte #4  = ASCII value of last character
  1091.  
  1092.                   The remainder of the file consists of all the
  1093.                   ASCII codes of the defined character set, in
  1094.                   order.
  1095.  
  1096.                   The program checks the integrity of the font file
  1097.                   when attempting to load it, so therefore it is
  1098.                   imperative that the file be exactly the correct
  1099.                   length as defined by the first four bytes.  All
  1100.                   characters from ASCII start to ASCII end inclusive
  1101.                   must be defined in the file.
  1102.  
  1103.                   Another point of note is that when the SD.EXE program
  1104.                   displays the fonts it will add a space to the
  1105.                   end of each row of the large character, so don't include
  1106.                   them into the definition of the font.
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.                                                
  1120.  
  1121.  
  1122.  
  1123.                                                                    Page - 16
  1124.  
  1125.  
  1126.         Screen Designer's User's Guide
  1127.       ─────────────────────────────────────────────────────────────────────
  1128.  
  1129.  
  1130.  
  1131.  
  1132.  
  1133.  
  1134.  
  1135.  
  1136.         SHAREWARE:
  1137.         ==========
  1138.  
  1139.  
  1140.         Hopefully this software will generate enough interest to
  1141.         encourage me to continue expanding it.
  1142.  
  1143.         Any comments, suggestions or criticisms would be
  1144.         appreciated.
  1145.  
  1146.         If you find this software useful I would request that you
  1147.         register it, by sending me a nominal fee of $25.00.
  1148.  
  1149.         Print out the order.frm  file included on the distribution
  1150.         disk.
  1151.  
  1152.         Make CHEQUE or MONEY-ORDER payable to:
  1153.  
  1154.                                  Gary Ivany
  1155.                                  197 Jubilee Rd.
  1156.                                  Bridgewater, Nova Scotia
  1157.                                  CANADA
  1158.                                  B4V-3G5
  1159.  
  1160.  
  1161.  
  1162.  
  1163.  
  1164.  
  1165.  
  1166.  
  1167.  
  1168.  
  1169.  
  1170.  
  1171.  
  1172.  
  1173.  
  1174.  
  1175.  
  1176.  
  1177.  
  1178.  
  1179.  
  1180.  
  1181.  
  1182.  
  1183.  
  1184.  
  1185.  
  1186.                                                                    Page - 17
  1187.  
  1188.  
  1189.         Screen Designer's User's Guide
  1190.       ─────────────────────────────────────────────────────────────────────
  1191.  
  1192.         BRIEF GUIDED TOUR:
  1193.               The real ease of use of the program is achieved when you
  1194.         utilize both the MOUSE and HOT KEYS, therefore for this
  1195.         demonstration I avoid the MENUS when it makes sense to do so.
  1196.  
  1197.  
  1198.         * If at any time you make a mistake in following these instructions
  1199.           you can simply press the <F3> key to undo it.
  1200.  
  1201.         To begin let's create a background pattern.
  1202.  
  1203.            Press <F2> to call up the CONTROL WINDOW
  1204.  
  1205.            Locate the mouse cursor at R14 C43 (see status bar for positions)
  1206.            Select this FILL character by pressing the left-button.
  1207.  
  1208.            Select "Green" foreground color and "BLUE" background color
  1209.            (positions R21 C13 and R23 C11)
  1210.  
  1211.            Exit the control window by pressing the right mouse button.
  1212.  
  1213.            Press 'F' to change to FILL MODE.
  1214.  
  1215.            Select a screen area from  R2 C1 to R24 C80 then release to
  1216.            FILL this region with our fill character.
  1217.  
  1218.            Press the right mouse button to return to menu mode.
  1219.  
  1220.        Now let's recolor the top and bottom lines of the screen.
  1221.  
  1222.            Call up the CONTROL window again using <F2>.
  1223.            Select a background color of CYAN located at 23,16.
  1224.  
  1225.            Exit the control window (<ESC> key or right button).
  1226.  
  1227.            Press 'R' to enter into RECOLOR MODE.
  1228.  
  1229.            Select an area from 1,1 to 1,80 then release to recolor it.
  1230.            Next, recolor 25,1 to 25,80.
  1231.  
  1232.            Press the right mouse button to return to menu mode.
  1233.  
  1234.       Draw a shadowed box ...
  1235.  
  1236.            Using the CONTROL window select colors BRIGHT WHITE on BLACK.
  1237.            When back in menu mode press "B" to enter SINGLE LINE BOX mode.
  1238.  
  1239.            Check the status bar, it should have SMART on,
  1240.            SHADE off and FILL off.
  1241.  
  1242.            Press <F5> to enable SHADE, press <F6> to enable FILL.
  1243.  
  1244.            Select an area from 7,16 to 17,67 to draw our box.
  1245.  
  1246.            Upon releasing you will notice that the shadow is created
  1247.            outside of our selected area.
  1248.  
  1249.                                                                    Page - 18
  1250.  
  1251.  
  1252.         Screen Designer's User's Guide
  1253.       ─────────────────────────────────────────────────────────────────────
  1254.         GUIDED TOUR CONT...
  1255.  
  1256.  
  1257.       Add a few lines ...
  1258.  
  1259.            While still in single box mode, let's draw a line from
  1260.            15,16 to 15,67. Notice the line ends that were substituted
  1261.            on the ends of the line, this is the result of having
  1262.            SMART enabled.
  1263.  
  1264.            Exit single box mode and enter Double box mode, by pressing
  1265.            <ESC> then 'X'.
  1266.  
  1267.            Now draw a double line from 9,16 to 9,67 then another line
  1268.            from 7,55 to 17,55.
  1269.  
  1270.            Press the right mouse button to return to menu mode.
  1271.  
  1272.       Add some text ...
  1273.  
  1274.            Press 'T' for text mode then position the mouse cursor at 8,19.
  1275.            When you press the left button the mouse cursor will turn into
  1276.            a text cursor.
  1277.  
  1278.            Type in the following: "Screen Designer Tutorial".
  1279.            Cursor to 12,27 then type text "Sample Text".
  1280.  
  1281.            Press <ESC> to exit text mode.
  1282.  
  1283.       Draw another box and copy it...
  1284.  
  1285.            On your own, draw a YELLOW on RED box, filled and NO shadow at
  1286.            location 19,32 to 23,47.
  1287.  
  1288.            When back in menu mode Press 'C' to enter copy mode.
  1289.            Select the area of the newly created box then drag the copy to
  1290.            location 2,65. Click the left button to release the copy.
  1291.  
  1292.            Exit back to MENU mode by pressing right button.
  1293.  
  1294.       Rubber stamp some copies...
  1295.  
  1296.            Since in the last step you have made a copy, The PASTE option
  1297.            is now enabled. Press 'P' to activate this mode.
  1298.            Move the cursor around the screen and left-click to PASTE
  1299.            a few copies at random locations.
  1300.  
  1301.            When you are finished use the <F3> key to erase the copies.
  1302.            Exit back to the MENU.
  1303.  
  1304.       Create a COM file...
  1305.  
  1306.            Press <ALT> F C to activate the 'create COM file dialog'
  1307.  
  1308.            Create  a .COM file by entering in a name.
  1309.  
  1310.  
  1311.                                                                    
  1312.                                                                    Page - 19
  1313.  
  1314.  
  1315.         Screen Designer's User's Guide
  1316.       ─────────────────────────────────────────────────────────────────────
  1317.         GUIDED TOUR CONT...
  1318.  
  1319.       Shell and run COM file...
  1320.  
  1321.            Press <ALT> F D to enter a DOS shell, then run the .COM
  1322.            file you just created.
  1323.  
  1324.            Type EXIT to return to the program.
  1325.  
  1326.       
  1327.         I hope that this little tour enlightened you to the easiest way to
  1328.         use this program. I find this mix of the Mouse and Hot / Shortcut
  1329.         keys enables me to concentrate on the design of the screen and not
  1330.         the tool's interface. All the editing and drawing tools are
  1331.         available through the menu with exception of two special hot keys,
  1332.         <F7> and <F8>. (see Hot Keys at top)
  1333.         Of course the menus come in very handy when you just can't
  1334.         remember the shortcuts.
  1335.  
  1336.         There are quite a few features I didn't touch on here, but explore
  1337.         around on your own. It can be quite fun and challenging to create
  1338.         appealing screens in text mode.
  1339.  
  1340.  
  1341.  
  1342.  
  1343.  
  1344.  
  1345.  
  1346.  
  1347.  
  1348.  
  1349.  
  1350.  
  1351.  
  1352.  
  1353.  
  1354.  
  1355.  
  1356.  
  1357.  
  1358.  
  1359.  
  1360.  
  1361.  
  1362.  
  1363.  
  1364.  
  1365.  
  1366.  
  1367.  
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.                                                                    
  1374.  
  1375.                                                                    Page - 20
  1376.  
  1377.  
  1378.         Screen Designer's User's Guide
  1379.       ─────────────────────────────────────────────────────────────────────
  1380.  
  1381.  
  1382.  
  1383.  
  1384.  
  1385.  
  1386.  
  1387.  
  1388.  
  1389.  
  1390.  
  1391.         Warranty Disclaimer
  1392.  
  1393.         This program is provided "AS IS" without warranty of any
  1394.         kind.  In addition, Gary Ivany specifically disclaims all
  1395.         warranties, expressed or implied, including but not limited
  1396.         to
  1397.         implied warranties of merchantability and/or fitness for a
  1398.         particular purpose.  In no event shall Gary Ivany be liable
  1399.         for any claims for lost profits, lost savings or any other
  1400.         damage, including but not limited to special, incidental,
  1401.         consequential or other damage even if Gary Ivany has been
  1402.         advised of the possibility of such damages.
  1403.  
  1404.  
  1405.  
  1406.  
  1407.  
  1408.  
  1409.  
  1410.  
  1411.  
  1412.  
  1413.  
  1414.  
  1415.  
  1416.  
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.  
  1427.  
  1428.  
  1429.  
  1430.  
  1431.  
  1432.  
  1433.  
  1434.  
  1435.  
  1436.  
  1437.  
  1438.                                                                    Page - 21
  1439.  
  1440.  
  1441.  
  1442.