System software:Changing directories
Changing directories
To tell the computer to change its attention to a subdirectory within the current directory, the DOS command is CHOIR (short for 'change directory') followed by the name of the directory. Other systems may have slight variations. Under DOS, you can abbreviate this command to just:
CD <followed by the directory name>
So if I want to change from the root directory to the QA directory in order to run the Q&A software, I type
CDQA
If I want to go down a further level to the TEXT subdirec tory of the QA directory (see Figure 5.1), I must enter the further command
CD TEXT
It's easier, though, to combine both of these in a single command. To do this in DOS, type CD followed by both QA and TEXT, separated by a backs lash:
CDQA\TEXT
This changes first to the QA directory, and then the TEXT subdirectory within QA.
Other systems may use symbols other than the backslash. Some, for instance, use the ordinary slash '/', while the Acorn Econet system uses a dot.
Changing to the root directory
The root directory is unique, for it is the start of the directory tree. Under DOS, it is designated by the single character ''\, and if you type
CD\
you will jump from wherever you are on the directory tree to the root directory.
By combining this ''\with other directory names, you can move directly from a subdirectory in one part of the directory tree to another subdirectory in a quite different part. For example, if I am in the BATCH directory on my hard disk, I can move straight to the TEXT subdirectory within the QA directory by typing
CD\QA\TEXT
Renaming, copying, and deleting files
The DOS command to rename a file is
RENAME <old filename> <new filename>
For example, if, on my hard disk, the \QA\TEXT directory is current, I can rename CHAP4.IT as CHAPTER4 by typing RENAME CHAP4.1T CHAPTER4 If I am in some other directory, I will have to enter what's called the pathname, which is the full directory route to the file plus the filename:
RENAME\QA \TEXT\CHAP4.1T CHAPTER4
A file called CHAP4.1T will no longer appear in the listing of this directory, being replaced by an identical file called CHAPTER4.
The DOS command to copy a file is COPY followed by the existing filename and the new filename. For example, if I am in the TEXT subdirectory of the QA directory,
COPY CHAP4.IT CHAPTER4
will create a duplicate of CHAP4.1T with the name CHAPTER4.
The copy command is often used to create duplicates of hard-disk files on a floppy disk, to be stored away in a safe place in case of fire or other disaster. For example, if I am
in the root directory of my hard disk, I can copy this chapter by issuing the command:
COPY\QA\TEXT\CHAP4.IT A:
This will create a copy of the same name on Drive A. If I want to use a different name for my copy, for example CHAPTER4, the command is
COPY\QA\TEXT\CHAP4.IT A:CHAPTER4
The DOS command to delete a file is DEL followed by the filename.
Similar commands are used to perform these tasks in other operating systems.
Wildcards
A wildcard, in computer jargon, is a symbol which, when used in a filename, can represent any character or group of characters at that position in the name. You use wildcards to select all files with the same extension, or with similar stems, so that you can copy or delete a whole group of files with a single command.
The most useful wildcard symbol is *. If you include this in a filename, you are telling the operating system that any character or group of characters can occupy that position or any of the remaining positions in the stem of the name or in the extension. For example:
*.GV
says to the operating system, 'all files with the extension GV', and
CHAP*.GV
says to the operating system, 'all files with the extension GV and with stems beginning with CHAP', and
*·*
says to the operating system, 'all files with any stem and any extension'.
So I can type the following command to delete all the files in the current directory on the floppy disk in Drive A:
DELA:*·*
To copy all the chapters of a book from my hard disk to this floppy, the command is:
COPY C:\QA\TEXT\CHAP* .IT A:
Making and removing directories
The DOS command to make a directory is MKDIR followed by the directory name. This can be shortened to MD:
MDMYDIR
creates the directory MYDIR within the current directory. Note that, like DOS filenames, a directory name cannot exceed 8 characters in length.
To remove a directory, the DOS command is RMDIR.
This can be shortened to RD:
RDMYDIR
will remove the directory MYDIR in the current directory. Note that to use this command, you must first delete all files (and subdirectories) in the directory you wish to remove.
These are just some of the operating system commands.
For others, such as commands to format a floppy disk or to backup a disk, see the operating system manual for your computer.
Operating environments
DOS and most other operating systems are not 'user friendly'. The commands that you read about in the last section are awkward to memorize and use, and if you are not familiar with the computer keyboard they are awkward to type. Also, the computer screen with its enigmatic C: is rather unfriendly and difficult to come to terms with, and most people appreciate something that resembles more closely the familiar world of the office with its drawers, folders, waste-paper basket, and so on.
Hence the need for operating environments, software which sits on top of the operating system and presents us with an easy-to-use and friendly way of performing the kinds of tasks described above. The two most popular operating environments on microcomputers are:
1 The Apple Macintosh operating environment and the almost identical GEM from Digital Research. GEM is short for 'Graphics Environment Manager', and it is available on the Atari ST, PC-compatibles, and some other micros.
2 Windows from Microsoft, available for all PC-compati bles, though best used on 80386 models and above. This is virtually identical to Presentation Manager (PM), used on the IBM PS/2 range of micros.
Both the Macintosh/GEM environment and Windows/PM have many similarities, for they are both based on the earlier operating environment developed by Xerox at the end of the 1970s. (As was explained on page 49, the Apple Mac popularized this environment.) In the future, this way of working is likely to become common across computers of every kind.
Xerox's original product - which was never released commercially - grew out of painstaking research into the way in which people interact with computers. Pressing the arrow keys on the keyboard to move around the screen, for instance, is not very efficient or natural, and so the mouse was developed. Pushing this across your desk produces corresponding movements of the cursor on the screen. Selecting files or software options by typing at the keyboard is also unnatural and inefficient, so a button is provided at the front of the mouse. Now, to make your selection, you merely push the mouse to move to the file or the option displayed on the screen, and click the button. In the case of a software program, you run it by 'double clicking', i.e. pressing the button twice in quick succession.
Xerox's research also showed that most people find the conventional text-based display unfriendly and difficult to use, preferring instead one that was graphics based. In this, pictures or icons represent the functions and tasks of the system, examples being a picture of a wastepaper basket to represent the delete function for getting rid of files, a filing drawer to represent a disk-drive, and so on. The cursor itself is represented by an icon, normally an arrow to point to files or functions.
Even files are represented by icons, namely minature sheets of paper containing the filenames, and directories are represented by pictures of folders. The contents of a directory appear in a box or 'window' on the screen. Several directories can be displayed at the same time in different windows, and files can be copied from one to another simply by selecting them with the mouse, keeping the button held down, and 'dragging' them to another window.
Other facilities include:
• Pull-down menus. The menus are listed across the top of the screen, and a menu's options appear as a list below it when you point to it with the mouse. To select an option, you point and click with the mouse.
• Dialogue boxes. These appear in situations where you need to turn a number of options on or off, or type in something like a filename. To set an option, you mouse click on a 'radio button' located alongside it (see Figure 5.2).
This kind of interface is called a graphical user interface, or GUI. The term WIMP is also used, meaning 'Window, Icon, Mouse, Pointer'.
In the future, it is likely that more advanced computer environments will appear. Work is currently being done on developing an animated icon - which might look like a human being but could be configured in any way the user chooses - that can converse with the user using speech synthesis and speech recognition. The icon will be linked to an expert system (see page 147) and so will seem 'intelli gent', able to guide the user through the system. Another example is the electronic stylus, being developed for anno tating documents on screen.
Comments
Post a Comment