
 ---------------------------------------------------------------------------

                         !DiscComp - Disc compactor
                    
                      Version 1.02 (4 September 1994)
                        
                             Written Andrew Berry
                           
                         >>>--- PUBLIC DOMAIN ---<<<
      
 ---------------------------------------------------------------------------                                 
                              --- PURPOSE ---  
                                                            
 DiscComp is a small utility designed to make compacting discs easier. At
 the moment the only way to compact a disc is to use the command line.
 DiscComp takes the hard work out of disc compacting by providing a user
 interface for the *Compact command. If 'compact' is added to the filer menu
 in a future version of RISC OS then this utility will not be needed.
 
 
                              --- LOADING ---
                              
 To load DiscComp double-click on its icon in a filer window. After a few
 seconds its icon should appear on the right-hand side of the icon bar.
 
 
                         --- SELECTING A DISC ---
                         
 Compacting a disc is done from the main window. To open the main window
 click on the DiscComp icon on the icon bar. The window is divided into two
 halves. The left-hand side of the window is used for selecting the disc to
 compact. I've tried to make DiscComp compatible with any discs, so there
 may be more than one way of selecting your disc. The upper six icons are
 numbered 0 to 5. Drives 0-3 are floppies and 4 and 5 are hard discs. To
 select a drive click on its corresponding radio icon. If your drive has a
 number other than those in the window you can enter it into the 'Other
 number:" icon. For instance, to compact a disc in drive 6 you would enter
 '6' into the writeable icon to the right of 'Other number:'. The final
 option can be used to name specific discs to compact. For instance,
 entering 'MyDisc' would cause the disc 'MyDisc' to be compacted. You are
 prompted to insert the disc if it is not present. This option can also be
 used if you prefer to call your hard disc by name. For instance, 'IDEDisc4'
 can be entered here instead of selecting drive 4.
 
 
                     --- COMPACTING THE SELECTED DISC ---
                     
 Compacting a disc can be done in a number of different ways, depending on
 the disc selected on the left-hand side of the window.
 
      1) Clicking on 'Compact' in the bottom right of the window will compact
         the disc selected on the left.
         
      2) If the caret is in the 'Other number' or 'Disc name' writeable icons
         then pressing return will do one of two things:
             a) If the icon is selected then pressing return will compact
                the disc, the same as clicking Compact.
             b) If the icon is not selected then pressing return will select
                it.
         Therefore, if drive 4 is selected (for example) then to compact a
         disc called 'MyDisc' enter 'MyDisc' into the 'Disc name' writeable
         icon and press return twice. If these instructions don't make much
         sense then try it out - it's actually a lot simpler than I make it
         sound!
         
      3) Pressing return in the 'Repeat' writeable icon will compact the
         disc, the same as clicking 'compact'.
 
 
                             --- OPTIONS ---
                             
 The right-hand side of the window contains various options. Click on an
 option button to alter its state.
 
      1) Confirm compaction: This asks you to confirm every compaction, so
         that you can't compact a disc by mistake. This is not included as a
         safety measure because no harm can be done by compacting most discs,
         but because it is annoying having to wait for a disc to compact that
         you didn't want compacting!
 
      2) Repeat: Sometimes a disc doesn't compact fully on the first attempt,         so I have included a repeat option. When it is switched on it will
         compact the disc the number of times shown in the white box next to
         'Repeat'. To alter the number, click on the box and enter the new
         number.
         
      3) Display hourglass: When repeat is turned off then this option will
         display the standard hourglass to tell you that the disc is being
         compacted. When repeat is turned on it will show you the number of
         times the disc has been compacted, as a percentage of the total. The         reason I've included this option is that when a disc is compacted
         with the repeat option on, the last few repeats don't actually
         compact anything and the hourglass slows down the repeat
         considerably.
         
      4) Show free space on disc: This option is used to display disc
         information when compaction is complete. When selected, it brings
         up a new window. This is described later.
 
 To close the main window, either use the close icon or click on 'Cancel'.
 All options are remembered when the window is closed but are not saved.
 
 
                         --- DISC INFORMATION ---
                         
 If 'Show free space on disc' is selected then a disc information window
 will open once compaction is complete. This shows the size of the disc, the
 amount of free and used space and how full the disc is (as a percentage).
 
 
                          --- OTHER BUTTONS ---
                          
 Along the bottom of the window are four buttons. They are:
 
      1) Help... : Clicking on this *Filer_Run's this file. This will
                   normally cause it to be displayed on the screen in some
                   way, depending on your OS version and setup.
                   
      2) Cancel  : Closes the main window without compacting a disc. All
                   options are remembered until the program is quit.
                   
      3) Free... : Analyses the currently selected disc and displays the
                   Disc Information window which is described above. This
                   is included so that the exact space on a disc can be
                   worked out.
                   
      4) Compact : Compacts the currently selected disc as described above.
      
      
                              --- MENUS ---
                              
 All selections for compacting are made from the main window, so the menus
 are just the standard Info and Quit. The menu can be selected from both the
 icon bar and the main window. Info displays the standard info box and Quit
 finishes the program.
 
 
                             --- HISTORY ---  
                              
 1.00 (10 Aug 1994) :  First version - fully working.
 
 1.01 (02 Sep 1994) :  Bug fix - Compact button now deselects after an
                        error. Was staying selected if named disc wasn't
                        inserted.
 
 1.02 (04 Sep 1994) :  Bug fix - Now works with RISC OS 2.
                        FileCore_FreeSpace and FileCore_DescribeDisc were
                        causing program to crash on RISC OS 2. Changed
                        FileCore_ to ADFS_.
                       Changed 'Filer_Run' to 'Type' for RO2 compatability.
                        Does Filer_Run on RISC OS 3.10 or more and Type on
                        others. Type isn't ideal, but if Run is used, then
                        an extra copy of !Edit etc. is loaded each time!
                       Now gives error if disc name is less than two
                        characters.
 
 
                           --- THINGS TO DO ---
                           
  Save options to disc, including drive selection and disc name
  Make top box in 'Disc Information' window show disc name whether disc
   was selected by name or drive.
  Intelligent repeat - stops repeating compact when it isn't doing any good.
  More intelligent error handling. Will recognize certain errors which are
   not program errors (i.e. Bad Drive) and will give error box without
   "Click OK to continue or Cancel to quit" and without Cancel button. These
   are just confusing for new users and Cancel is only needed if the error is
   unknown (i.e. a program bug) and an infinite loop could occur.

 The templates look terrible on RISC OS 2 because they use the new RISC OS 3
 borders. Because it's such a small program I had decided not to include
 RISC OS 2 templates, but I might include them in the next version, either
 2D or using the Interface module.
 
   
                            --- LEGAL BIT ---

 DISCLAIMER:- Although this program has been thoroughly tested I (the author)
 cannot be held responsible for any damages which may arise from the
 use or misuse of this program. 

 COPYRIGHT:- This program is public domain. This means that you are free to
 copy it as many times as you like as long as you do NOT make a profit. A
 small charge for postage, discs, etc. is acceptable. If you like this
 program then please give a copy to everyone you know!


                             --- TESTING ---
                             
 Special thanks to Ben Jacobs for helping to test this program.


                             --- CONTACT ---
                             
 Please write to me with any bug reports, comments, suggestions or donations:
 
     Andrew Berry
     39 Lancaster Avenue
     Sandiacre
     Nottingham
     NG10 5GW
     
 If this program does cause any serious problems then PLEASE let me know so
 that I can try and put it right. If you make a good suggestion or point out
 a good bug (!) then I'll send you the fixed version along with any other PD
 stuff I might get round to writing!
 
 This program has only been tested with a floppy drive :0 and an IDE hard
 disc :4 as I don't haveaccess to a computer with any additional drives. If
 you use this program with other drives then please let me know if it works,
 or (more importantly) if it doesn't! If it doesn't work and you know more
 than I probably do about possible reasons then send me a fixed version of
 the program or point me in the right direction so I can try and fix it
 myself. Any help with programming will be acknowledged in the next release.
 
 
 ---------------------------------------------------------------------------
