Wednesday, December 4, 2013

2.1TERMINALS

Many programs are interactive and need to access the user's terminal. Although the terminal is a file which can be connected with an OPEN statement, its name is system-dependent. Fortran solves the problem by providing two special files usually called the standard input file and the standard output file.

These files are pre-connected for example:no OPEN statement is needed (or permitted). They are both formatted sequential files and, on interactive systems, handle input and output to the terminal. You can READ and WRITE from these files simply by having an asterisk  ``*"  as the unit identifier.

These files make terminal I/O simple and portable; examples of their use can be found throughout this book.
When a program is run in batch mode most systems arrange for standard output to be diverted to a log file or to the system printer. There may be some similar arrangement for the standard input file.

The asterisk notation has one slight drawback:
-the unit numbers is often specified by an integer variable so that the source of input or destination of output can be switched from one file to another merely be altering the value of this integer. This cannot be done with the standard input or output files.



3.1MICE

Pointing Devices
The graphical user interfaces (GUIs) in use today require some kind of device for positioning the on-screen cursor.

Typical pointing devices are: mouse, trackball, touch pad, trackpoint, graphics tablet, joystick, and touch screen.
Pointing devices, such as a mouse, connected to the PC via a serial ports (old),PS/2  mouse port (newer), or USB port (newest). Older Macs used ADB to connect their mice, but all recent Macs use USB (usually to a USB port right on the USB keyboard).


1)Mouse




The mouse pointing device sits on your work surface and is moved with your hand. In older mice, a ball in the bottom of the mouse rolls on the surface as you move the mouse, and internal rollers sense the ball movement and transmit the information to the computer via the cord of the mouse.
The newer optical mouse does not use a rolling ball, but instead uses a light and a small optical sensor to detect the motion of the mouse by tracking a tiny image of the desk surface. Optical mice avoid the problem of a dirty mouse ball, which causes regular mice to roll unsmoothly if the mouse ball and internal rollers are not cleaned frequently.
A cordless or wireless mouse communicates with the computer via radio waves (often using BlueTooth hardware and protocol) so that a cord is not needed (but such mice need internal batteries).
A mouse also includes one or more buttons (and possibly a scroll wheel) to allow users to interact with the GUI. The traditional PC mouse has two buttons, while the traditional Macintosh mouse has one button. On either type of computer you can also use mice with three or more buttons and a small scroll wheel (which can also usually be clicked like a button).


Two-button mouse with scroll wheel



Wireless Macintosh Mouse



2)Touch pad





Most laptop computers today have a touch pad pointing device. You move the on-screen cursor by sliding your finger along the surface of the touch pad. The buttons are located below the pad, but most touch pads allow you to perform “mouse clicks” by tapping on the pad itself.
Touch pads have the advantage over mice that they take up much less room to use. They have the advantage over trackballs (which were used on early laptops) that there are no moving parts to get dirty and result in jumpy cursor control.






3)Trackpoint




Some sub-notebook computers (such as the IBM ThinkPad), which lack room for even a touch pad, incorporate a trackpoint, a small rubber projection embedded between the keys of the keyboard. The trackpoint acts like a little joystick that can be used to control the position of the on-screen cursor.







4)Trackball


The trackball is sort of like an upside-down mouse, with the ball located on top. You use your fingers to roll the trackball, and internal rollers (similar to what’s inside a mouse) sense the motion which is transmitted to the computer. 





Advantage
-the body of the trackball remains stationary on your desk, so you don’t need as much room to use the trackball.
 Early laptop computers often used trackballs (before superior touch pads came along).

Disadvantage
-dirty rollers can make their cursor control jumpy and unsmooth.

But there are modern optical trackballs that don’t have this problem because their designs eliminate the rollers.



5)Joysticks




Joysticks and other game controllers can also be connected to a computer as pointing devices. They are generally used for playing games, and not for controlling the on-screen cursor in productivity software.







6)Touch screen
Some computers, especially small hand-held PDAs, have touch sensitive display screens. The user can make choices and press button images on the screen. You often use a stylus, which you hold like a pen, to “write” on the surface of a small touch screen.









7)Graphics tablet




A graphics tablet consists of an electronic writing area and a special “pen” that works with it. Graphics tablets allows artists to create graphical images with motions and actions similar to using more traditional drawing tools. The pen of the graphics tablet is pressure sensitive, so pressing harder or softer can result in brush strokes of different width (in an appropriate graphics program).








NUR LIYANA BT ROSLAN
B031310295

No comments:

Post a Comment