ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß ÄÄÄÄÄÄÄÍÍÍÍÍÍÍÍÍí PCB 15.1+ Lightbar kit PPE íÍÍÍÍÍÍÍÍÍÍÄÄÄÄÄÄÄÄÄ ÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜ Released on 16-05-94 (C) BlackCat, FREEWARE Version 1.10 ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ First of all credit where credits are due. I modeled this lightbar after that great lightbar ppe from pwa. Since I had used lightbars in many of my other utils I already had an idea about such a ppe, but pwa's scheme helped me prevent some headache in figuring out how to set things up. Still pwa's ppe had some options missing which I had in mind, such as multiple windowing, ability to spawn other ppe's, the ability to create pulldown menus and help options. In creating this ppe I just kept on adding options. It might seem a bit too much at the beginning for a new user of the lightbar :-). The best way to get started is probably to figure out what kind of menu you want, copy one of the examples of the kind you want and start changing it to suit your needs. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÍÍÍÍÍÍÍÍÍí INSTALLATION íÍÍÍÍÍÍÍÍÍÍÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ Make sure you have unzipped the file with the -d option. Setup the configuration files (see CONFIGURATION below) and call lb.ppe with the configuration file as a parameter. Note that a parameter file has to have '.cfg' as an extension. Several example configuration files are given (see EXAMPLES below). ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÍÍÍÍÍÍÍÍÍí CONFIGURATION íÍÍÍÍÍÍÍÍÍÍÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ What follows is a comprehensive descriptions of the lines in a configuration file : Line 1: Token 1: Number of lightbar entries. Token 2: Window size. If this is smaller than the number of lightbar entries the user can page through the windows with pgup/pgdn. Token 3: Highlight color for this menu. Token 4,5: (X,Y) coordinate where to start displaying the line/file defined in line 2. Use a 'C' as the Y coordinate to display the option at the current Y position. Token 6: 'YES' to redraw the menu when returning from a call command Otherwise it is assumed that the menu is still on the screen. A 'NO' here is handy for a menu of the type 'pulldownmain', as the pulldowns are probably designed in such a way as to not overwrite the main pulldown menu. Token 7: If 'YES' pgup on the first windows moves to the last window and pgdn on the last windows moves to the first window. Otherwise pgup/pgdn give a short beep when on the first/last window. Token 8: Menu type : PULLDOWNMENU : This is a pulldown menu. When left/right is pressed left/right is stuffed to the keyboard and the menu exits. Also for any 'STUFF text' command the keys to exit the calling main pulldown menu are stuffed to the keyboard followed by 'text'. Needless to say that this menu type must always be called by another lightbar menu. This type of menu can have multiple windows. PULLDOWNMAIN : This is a pulldown main menu. When this menu exits it saves it's current position, which is used to retrieve the last pulldown menu the user used when the menu starts again. When down is pressed that is interpreted as a return. Note that this type of menu cannot have multiple windows, if you do this anyway things will screw up. NORMAL : No special processing is done. token 9: Yes to clear the screen when the lightbar exits with 'ESC'. token 10: Yes to allow the user to exit the menu with 'ESC'. Note that pulldown menu's should always have this option set to 'YES', especially the main pulldown menu, otherwise the pulldowns won't be able to exit the main pulldown menu by stuffing 'ESC'. token 11: YES to clear the current line at lightbar exit. Use this for one line prompts (eg. the more prompt) where it looks better if the line is cleared. Token 12: YES to use hotkeys. The third token after the (X,Y) coordinates gives the hotkey character. Otherwise the character is used to move over to that option but no return is issued. token 13-17: These tokens are only used if the menu type is 'PULLDOWNMENU'. The first one (13) gives the menu level from the main pulldown menu for this menu (for example a pulldown called directly by the main menu has level 1, if a pulldown with level one calls another pulldown menu that one should have level 2 and so on). The level is necessary so that the pulldowns know how to exit the main pulldown menu when a 'STUFF' command is issued. The next tokens give the (X,Y) starting coordinate and the (X,Y) ending coordinate of the pulldown menu. This is used to clear the pulldown menu when it exits. Note that you cannot use 'C' with the Y coordinates. Clearing, by the way, is done by padding spaces (I could have restored what what under the pulldown but that prob. isn't worth the overhead). Line 2: Line shown before the options are displayed. (you can also use a file here with %path\filename). Line 3: First Lightbar option (X,Y) coordinate. Use a 'C' as the Y coordinate to display the option at the current Y position. If a third token is given this is assumed to be a help file which is displayed when '?' is pressed on this option. This file is searched in the following way: - First it it checked if the file itself exist. - Secondly it is checked if the file exist in the pcboard help directory (the file is searched by appending it to 'hlp', for example if the name is 'h' the file searched is '\hlph'. - As a last resort the ppe directory is searched. If the third token is not given or the file is not found as described above and the command defined in line 5 is a 'STUFF' command the first token after the 'STUFF' command is used to check if the helpfile for that token exist in the pcboard help directory (for example, if the command is 'STUFF h', the file searched is '\hlph'). You can also enter 'NOHLP' as the third token to prevent the display of unwanted help files (see more.cfg for an example of when this can happen). Line 4: Text for the first Lightbar option Line 5: Action to take when this option is selected with a return: CALL ppename - Calls this ppe and then returns to the lightbar. Using only calls you can create a selfcontained menu. STUFF text - The text 'text' is stuffed to the keyboard and the lightbar ppe exits. At the end of 'text' a RETURN is inserted. A 'CR' in 'text' is interpreted as a carriage return. STUFFSTR - *NEW* First let me explain that ppl has two keyboard stuff commands. 'kbdstuff' which supposedly stuffs the keys to the keyboard invisible to the user and 'kbdstring' where the keys are also shown on the screen. But while testing the lightbar I also noticed that when stuffing keys with 'kbdstuff' the commands in your 'cmd.lst' are bypassed while 'kbdstring' does not ( for example if you have replaced your 'V' key in cmd.lst with a better statistics viewer, 'kbdstuff' will bypass that and show the pcb default stats). Also sometimes some help keys ('H') are not recognized unless 'stuffstring' is used. I've still kept the normal 'kbdstuff' command as 'STUFF' because most of the time there are no problems and it does not show the keys, which sometimes can make the screen look ugly. (By the way I'm using pplc 2.0 release, so it's no beta bug:-)) STUFFSTR_NOCR - Normally a return is entered after the text is stuffed with either 'STUFF' or 'STUFFSTR', if you don't want this use this command. (by the way there's no 'STUFF_NOCR' because ppl automagically inserts a return if you do not explicitly do that yourself, this is probably because the text is invisible to the user, so not entering a return wouldn't make sense) PGUP - This command has the same effect as pressing pgup at the lightbar menu. PGDN - This command has the same effect as pressing pgdn at the lightbar menu. DISP filename - Displays the file 'filename'. If the name is not found on it's own the lightbar directory is also searched. This display command saves the screen before displaying the file and restores it again after viewing the file. COMMAND prompt - Asks the user input using prompt 'prompt', stuffs the input to the keyboard (using 'STUFF') and exits. Use this to allow the user to enter exotic commands you were not able to include in the menu. Line 6: etc etc for the rest op the entries (as much as defined in the first token of line 1) Tokens are separated by spaces or ';'. While in a lightbar menu you can use the following keys: CTRL PGUP CTRL PGDN < > : These are used to change windows. If no windows are defined they're not used. LEFT/RIGHT UP/DOWN : These keys are used to move between the lightbar options. When the menu type is 'PULLDOWNMENU' left/right have a different function (see above). The '<' and '>' keys can also be used. END/HOME : These move the current lightbar option to the last and first one on the current window respectively. ESC : Terminates the current lightbar menu. ENTER : Selects the current option. : Moves the current option to the next menu option with the first letter or executes the command immediately (Token 12, line 1). ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÍÍÍÍÍÍÍÍÍí EXAMPLES íÍÍÍÍÍÍÍÍÍÍÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ For an example of a pulldown menu take a look at the setup in directory PULL1. I've tried to make this setup somewhat like the well known 911 pulldown menu, so if you don't like the layout complain to them or better yet make one you like, you have the perfect tool for that now. This example, just like the 911 version, can be installed by replacing your BRDM file with '!\LB.PPE PULL1\PULL.CFG'. Also make sure that the paths in all the .CFG files are correct. Directory PULL2 contains the same pulldown menu example as above, but with other menus. Intall it replacing your brdm file with '!\LB.PPE PULL2\PULL.CFG'. The main menu 'DOORS' and 'BULLETINS' options trigger another pulldown menu. I've added these to illustrate the use of nested pulldown menus. If you don't want to use these replace the 'CALL' with a 'STUFFSTR' command (for the doors 'STUFFSTR open' and for the bulletins 'STUFFSTR b'). Again don't forget to correct the paths in the .CFG files. The following examples require you to replace one or more lines of your pcbtext file. To do this follow the following steps. 1 - Run 'MKPCBTXT ' where is your pcboard text file. 2 - Press F3 and enter the prompt number you have to replace. 3 - Replace the prompt and exit MKPCBTXT by pressing ESC. MSG.CFG is a replacement for the end of message prompt. You can install this by replacing pcbtext prompts #197 & #612 with something like '!\LB.PPE MSG.CFG'. MORE.CFG is a replacement for the more prompt. Install this by replacing pcbtext entry #196 with '!\LB.PPE MORE.CFG'. FSE.CFG is a replacement for the prompt shown after entering a msg. Replace prompts #163 and #222 with '!\LB.PPE FSE.CFG'. You might also want to make prompt #164 and #629 empty. MSGSEC.CFG can also be used to replace the security prompt when entering a message, replace prompt #194 with '!\LB.PPE MSGSEC.CFG' for this one. ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÍÍÍÍÍÍÍÍÍí AUTHOR íÍÍÍÍÍÍÍÍÍÍÄÄÄÄÄÄÄÄÄÄÄÄ ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ For any bug reports/comments/suggestions you can contact me at MaFIA Godfather HQ under handle El GaTO or mail me on internet at: an42144@anon.penet.fi You can also request the newest version of this or any of my other PPEs/pcboard utils at the same internet address. I'll send them to you uuencoded. Enjoy, BlackCat