The abs

Reference Manual

 

FIRST DRAFT

 

copyright 2000 , André Bertin

Contents

Getting and Installing abs *

What is abs? *

Abs license and copyright? *

Abs design goal *

Working inside the abs environment *

Starting abs *

Some definitions *

Document *

Workbook *

Worksheet *

Cell *

The main window *

Adding data *

Writing formula *

Moving inside a worksheet *

Selection of cells *

Move, cut, copy and paste selection of cells *

Moving inside a workbook *

Working with workbook *

Definition of a workbook *

create a new workbook *

open a workbook *

save a workbook *

close a workbook *

activate a workbook *

print *

Quit abs *

Formatting cells and worksheets *

Formatting a cell *

Format use to display the cell values *

Horizontal Alignment *

Font selection *

Chose the border style *

Chose the foreground and background color *

Formatting a worksheet *

Cell size *

Worksheet name *

Working with charts *

creating a new chart *

selecting a chart *

change chart option *

Type of chart *

Range *

Labels *

Grid *

Axis range *

Deleting chart *

Redrawing chart *

Working with drawings *

Creating a new drawing or a macro button *

Editing drawings *

Stop editing drawings *

The ABVisual Language *

Compatibility with Microsoft Visual Basic for Application *

Types *

Declarations *

conditionnal statement *

Loops *

Jumps *

Input / Output *

Expressions *

Working with Macro *

recording a macro *

Playing macro *

Modifying a macro *

Programming inside abs *

The source code *

The object definition *

adding a new build-in function *

Definition of the new function: file myfct.h *

adding a new class to ABVisual *

Definition of the new class: file my_vb.h *

In the file init.c *

interfacing with other code *

Support *

Getting support for abs *

License and copyrights *

 

 

 

 

 

1

Getting and Installing abs

What is abs?

Abs is a free graphical spreadsheet designed for Unix operating systems.

Abs license and copyright?

Abs is distributed under General Public Licence. This means that everybody can download abs, copy the source file, modify the code and redistribute it.

Abs design goal

The main goal of abs is to remain simple. Simple in term of installation and functionnalities. The principles that governs the installation of abs are:

copy the abs file on the computer disk

make the abs file executable

make a path to the location where you have copied abs

At this moment, abs is fully installed and ready to be executed, you do not need any extra configuration file or library!

 

 

 

 

 

2

Working inside the abs environment

 

Starting abs

To start abs, you just need to enter ‘./abs’ on the command line and press enter. Note that the X11 graphic environment must be running. Abs starts with a blank document. The figure 1 presents the main window of the abs graphical interface.

Some definitions

Document

A document is the entity that can be stored to the disk as an ASCII file (human readable format). This file is in fact a program written in the ABVisual language. This program is made of different parts called "subroutine" and "function". One special subroutine called "absmain" is automatically generated when a document is saved. At the reopening of this document, the "absmain" routine is executed and it restores the data as they were when the document was saved. The program is also called herein "project" and the routines are also called "macro".

The ABVisual language is compatible with the Microsoft Visual Basic language. So a file created with the abs spreadsheet can be read inside the Visual Basic window of any version of Excel (at least Excel 5.0). Then, executing the "absmain" subroutine inside gives the same results as in abs.

Workbook

A workbook is a collection of worksheets. Different workbook can be opened simultaneously inside abs but only one workbook is active at a time, the ActiveWorkbook.

 

Worksheet

The worksheet is the data container. The data can be number, text, formula, drawing or chart. A workbook contains one or more worksheet but only one worksheet is active at a time, the ActiveWorksheet.

The ActiveWorksheet is represented inside the main window of abs as a grid made of rows and column

Cell

A cell is a reference defined by a row number and a column letter. A cell refers and displays data of type number, text or formula are . Only one cell is active at a time, the ActiveCell.

 

The main window

The figure 1 presents the some important parts of the main window.

Adding data

The entry of a new data inside a cell require 3 steps:

1. Activate the cell where you want to enter data

This is done by a single click inside a cell or by moving the cell cursor with the arrows keys (one cell move), the Page Up/Down keys (one visible page move up and down), the Home/End keys (top and bottom of sheet move) or the Tab/Shift Tab keys (one visible page move right and left)

2. Enter the data

The data is entered with the keyboard and the new entry is displayed in the cell and in the command line. The mouse selection/paste facilities can be used to edit the command line (button 1=select and copy, button 2=paste).

Three kind of data can be entered:

text field;

numeric value;

formula.

Abs considers that any data entry that start by a number or by the characters "equal", "plus" or "minus" is either a numeric value or a formula. To force abs to consider the entry as a text field, a ' have to be the first character (this character will not be displayed nor printed).

3. Validate the new data

There are three ways to validate the new data you entered:

press on the Enter or Return key;

activate another cell by using the arrow keys;

click on the Validate Button next to the command line.

To cancel the modification rather to validate the new data, you have to click on the Cancel Button next to the command line.

Writing formula

A formula is a mathematical expression that will be evaluated by abs. The formula is evaluated as soon as you have validated the new data.

A formula can be made of any combination of the following parts:

operation between numerical value: 5+10

operation between string: ="conca" & "tenate"

reference to the value of another cell: =A5

call to built-in function: =sin(3.14)

call to an ABVisual function: =myfunction(1,"text",3)

The evaluation of the formula returns either a value, a string or an error. The value returned is displayed in the cell where the formula was entered. Editing this cell will display again the formula.

The menu "Insert", sub-menu "Function" displays a panel that allows the selection of a function and its insertion inside the edited formula.

Moving inside a worksheet

There are three way to change the visible area of a worksheet:

1. With the mouse

The simplest way to move inside a worksheet with the mouse is to position the cursor inside the worksheet frame, to press on the middle button of the mouse and to move the mouse with the middle button pressed. The worksheet will follow the movement of the mouse till you release the middle button. This work as if you put your fingers on a sheet that lay on your desk.

Another way to move with the mouse is to use the scrollbars that borders the worksheet frame. A simple click on the arrow buttons that end the scrollbars will move the worksheet of one column or one row in the indicated direction. Keeping the button pressed will repeat the move till you release it.

Pressing on the thumb of the scrollbar and moving the mouse keeping the button pressed will move the worksheet up and down or right and left.

A single click between a scrollbar button and the scrollbar thumb will scroll the sheet of a number of rows or columns proportional to the distance between the cursor position and the thumb position.

2. With the keyboard arrows

Two situations are possible.

In the first situation you are not editing a cell formula, the fact of pressing an arrow key change the ActiveCell to the next one in the direction of the pressed arrow.

In the second situation, you are editing a cell formula. At this moment, pressing on the up or down arrow will validate the edition (like pressing on Enter key) and change the ActiveCell.

3. With the keyboard Page-Up, Page-Down, Home, End and TAB keys

Pressing on the Page/Up or Page/Down key will scroll up or down the worksheet of one times the number of visible rows.

Pressing on the Tab or Shift/Tab key will scroll left or right the worksheet of one times the number of visible columns.

Pressing on the Home key will move to row 1 column 1.

Pressing on the End key will move to the last row and column that holds a non void cell.

Selection of cells

Selection of cells are useful when you want to perform an operation on more than one cell, the active cell.

To select a range of cells:

1. press down the left button on a cell that create the first corner of the range, keep the button pressed.

2. extend the selection by moving the mouse keeping the left button pressed. A dashed rectangle is drawn around the selected cells.

3. Releasing the left button on the cell that will be the second corner of the selection will close the selection process.

Once a selection is done, you can still extend the selection by holding the "shitf" key and then pressing down the left button of the mouse.

The Active Cell is considered as selected at any time.

Move, cut, copy and paste selection of cells

To move a selection of cell, position the cursor close to the top line of the dashed rectangle that surround the selection. When you are close enough (3 pixels up or down of the line) the cursor change to a hand, you are ready to do the move by pressing on the left button of the mouse. As you move the mouse keeping the left button pressed, the cursor change to four direction arrows and the dashed rectangle that define the selection move to show where the selected cell will be moved. The release of the left button terminate the move.

Cutting a selection of cells will save the contents of the cells inside the abs clipboard and will clear these cells (no more data is strored and so the value is set to 0).

To do the cut, press on the cut button or select the cut entry inside the Edit menu from the menu bar or select the cut entry inside the popup-menu (press on right button of the mouse when the cursor is over the worksheet to activate the popup-menu).

Copying a selection of cells will save the contents of the cells inside the abs clipboard.

To do the copy, press on the copy button or select the copy entry inside the Edit menu from the menu bar or select the copy entry inside the popup-menu.

Paste to a selection of cells will overwrite the cells with the contents of the abs clipboard. If the extend of the selection is smaller than the area stored in the clipboard and if there is a risk of overwriting non empty cells, a confirmation panel is appears.

To do the paste, press on the paste button or select the paste entry inside the Edit menu from the menu bar or select the paste entry inside the popup-menu

Moving inside a workbook

To change the active worksheet, click on the name of another worksheet inside the thumb that is located at the bottom of the worksheet frame. If the name of the worksheet you want to activate is not visible, use the buttons located at the left of the worksheets index. The first button will make visible the name of the first worksheet, the last button will make visible the name of the last worksheet. The two other buttons increment or decrement the first visible worksheet name.

 

 

 

 

 

 

3

Working with workbook

 

 

Definition of a workbook

A workbook is the single entity that you can save to the disk. A workbook is made of different worksheets and of a ABVisual Project.

create a new workbook

When you start abs, a new workbook is automatically created. The name of this workbook is Document1. To create an additional workbook, select New inside the File menu from the menubar or click on the New Button.

The name of the new workbook appear inside the Windows menu from the menubar.

open a workbook

As a workbook can be saved to the disk, you can open it by pressing on Open inside the File menu from the menubar or by a click on the Open Button. A file selector will appear, selecting a file name and clicking on OK (or press Enter) will open the workbook stored in the file.

The name of the opened workbook appear inside the Windows menu from the menubar.

save a workbook

To save a workbook to the disk, press on Save inside the File menu from the menubar or click on the Save Button. A file selector will appear, selecting a file name and clicking on OK (or press Enter) will save the workbook in the selected file.

close a workbook

To close a workbook means to make it disappear from abs memory. Be sure to have saved it if you want to edit it further.

To close a workbook, press on Close inside the File menu from the menubar or click on the Close Button.

The name of the closed workbook disappear from the Windows menu from the menubar.

activate a workbook

To change the Active Workbook, select the name of the workbook you want to activate inside the Windows menu from the menubar. The Active Sheet of the selected workbook is displayed.

print

To print the Active Workbook, the Active Sheet or a Selection of Cells, press on Print inside the File menu from the menubar or click on the Print Button. The print pannel appears.

Quit abs

To quit abs, press on Quit inside the File menu from the menubar, a confirmation prompt appear, select OK to quit. All the worksheets not saved are lost.

 

 

 

 

4

Formatting cells and worksheets

Formatting a cell

To change the presentation used for your data,

1. you must first select a range of cells. By default, the Active Cell is selected.

2 chose the item "cells" from the menu "Format" inside the menubar.

At this stage a popup window appears in the center of the main window. This popup window is made of different panels that you can select by click on the top thumb. These panels will allow you to change the number format, the alignment, the font, the border and the color of the cells you have selected.

3. select what you want to change in the format of the selected cells

The format bar gives some short cuts to change the format of the cells.

Format use to display the cell values

There are five basic format for displaying data.

1. Standard: no special type is specified

2. Number: the data is displayed as a number with as many decimal as specified in the Decimal entry

3. Scientific: the data is displayed as a number between 0 and 10 multiplied by a power of 10. The number is displayed with as many decimal as specified in the Decimal entry

4. Percentage: The data is multiplied by 100. and is displayed with a % sign at its right. The number is displayed with as many decimal as specified in the Decimal entry

5. Date: The data is converted to a date and is displayed as DD/MM/YYYY. DD is the day, MM the month and YYYY is the year.

Horizontal Alignment

The horizontal alignment can be selected among right border, left border or center of the cell.

Font selection

abs is limited to 5 type of fonts (Fixed, Courier, Helvetica, Times and Symbol). These fonts can be displayed as bold or italic in 7 sizes.

If one font does not exist on the computer where abs is running, the font used for display is the closest one available.

If different font are present in the selection, only the selected modification will take place. As example, if a 8 and a 12 font sizes are present in the selection and the font familly "Fixed" is selected, the sizes will remain unchanged, only the font family will change.

Chose the border style

The border panel give support for quick formatting. Select the Top, Bottom, Left or Right button to draw a border around the selected area. Use the Internals buttons to draw line between cells of the selected area.

Chose the foreground and background color

Select either Foreground or Background. A click on the color map at the right change the selected color. The number of the color can also be written directly in the text field next to the Foreground/Background button.

Formatting a worksheet

Cell size

To change the height of a row or the width of a column, click with the left button on the row index or the column index and move the cursor with the button pressed. The size of the row or column is adapted instantaneously. Release the left button when the desired size is reached.

Another way to change the size of the cells is to use the menu format and to select adjust-line, adjust column or adjust sheet. The cells of the Active Column, Row or Sheet are enlarged till the content is fully displayed.

 

Worksheet name

Click with the right button on the worksheet name at the bottom of the sheet. A popup window asks for the new worksheet name.

 

 

 

 

 

5

Working with charts

 

creating a new chart

Select create in the Chart menu. Click on the worksheet with the left button to indicate where the top-left corner of the chart will be located and move the mouse to the location of the bottom-right corner. Release the mouse button.

If cells where selected before the chart creation, they becomes the data of an XY plot. If no cells where selected, a blank rectangle is displayed.

selecting a chart

A single click with the left button on a chart will select it.

change chart option

The chart to modify have to be selected before activating option from the chart menu.

 

Type of chart

There are 3 type of chart available, XY, Pie or Bar.

Range

Select the serie to be modified, X, Y1, Y2, ... and enter the range as A1:A16 and the name of the serie as ‘serie1 or as a reference to a cell. The buttons located at the right of the text field give a direct aces to the worksheet for selection.

Labels

The title of the chart and the axis labels can be entered directly in the text field

Grid

A Vertical and an horizontal grid can be drawn on the XY or Bar chart.

Axis range

The range used to display XY or bar chart can be automatic, this means that abs will choose the better values to display the chart or can be specified.

 

Deleting chart

Use the Cut button. No Paste nor copy yet implemented.

Redrawing chart

If the data presented in a chart are modified an if the automatic update do not work, select redraw from the chart menu to update all the charts of the active worksheet. Selecting another worksheet will update the charts of the selected worksheet.

 

 

 

 

6

Working with drawings

 

Creating a new drawing or a macro button

Select what is to be drawn from the draw menu and click with the left button on the sheet to indicate the to left corner of the new drawing. Hold down the left button and move to the right button corner of the new drawing, then release the left button.

Editing drawings

Select Edit On from the draw menu. Use the mouse to move the corner of the drawings. Use the Cut, Copy and Paste button.

Stop editing drawings

To leave the edition mode, select Edit off from the draw menu.

 

 

 

 

 

 

 

7

The ABVisual Language

 

Compatibility with Microsoft Visual Basic for Application

The first specification of ABVisual is to be 100% compatible with Microsoft Visual Basic for Application. All the main component of the Visual Basic are implemented: variable, function and subroutine declaration with type and scope;

loop of different kind, condition like if and case, etc...

Types

ABV knows the following types of data:

OBJECT

BYTE

INTEGER

LONG

SINGLE

DOUBLE

CURRENCY

STRING

BOOLEAN

VARIANT

DATE

 

Declarations

The syntax to declare a variable is:

DIM list of variable [As type of the variables]

STATIC list of variable [As type of the variables]

PUBLIC list of variable [As type of the variables]

PRIVATE list of variable [As type of the variables]

[constant scope] CONST list of variable [As type of the variables]

The syntax to declare a routine or a function is:

[PRIVATE | PUBLIC] SUB

routine identifier ( [argument list] )

list of statements

END SUB

[PRIVATE | PUBLIC] SUB

function identifier ( [argument list] )

list of statements

function identifier = value

END SUB

OPTION identifier

WITH identifier newline stat_list END WITH

 

conditionnal statement

IF expression THEN

statements

END IF

IF expression THEN

statements

ELSE

statements

END IF

IF expression THEN statement

SELECT CASE expression

CASE value1

statements

CASE value 2

statements

CASE ELSE

statements

END SELECT

 

Loops

DO WHILE expression

statements

LOOP

DO

statements

LOOP WHILE expression

DO UNTIL expression

statements

LOOP

DO

statements

LOOP UNTIL expression

FOR counter = start value TO end value [STEP step value]

statements

NEXT [counter]

FOR EACH element IN collection

statements

NEXT [element]

 

Jumps

CALL subroutine identifier ([argument list])

GOTO label

EXIT FOR

EXIT DO

EXIT FUNCTION

EXIT SUB

 

Input / Output

OPEN filemane FOR read|write|append AS filenumber

PRINT filenumber , [SPC(number)|TAB(number)] list of expression

WRITE filenumber , list of expression

INPUT filenumber , list of expression

CLOSE filenumber

 

Expressions

The following operators are implemented: +, -, *, /, \\, MOD, ^, <,<=,=,>=,>,<>, AND, EQV, IMP, NOT, OR, XOR, &.

The main difference with Microsoft Visual Basic is that you have access to the source code of ABVisual and that you can easily add your own classes, function or interface with all the code you developed before.

Working with Macro

recording a macro

To record a new macro, select Rec Macro from the Tools menu. A prompt window ask for the name of the new macro and the recording start. To stop the recording, select Stop Recording form the tools menu. At this time, only the modification of the cells data is recorded.

Playing macro

Select Play Macro from the Tools menu, a popup listing all the playable macro is displayed.

Select the macro to play and click either on Play and close (this popup) or on Play.

Modifying a macro

To modify a macro, select ABVisual from the Tools menu. A simple editor containing the macro code pops up.

To make macro change effective, choose the Update button. The number of syntax errors appears in the message window.

To close the editor choose the Close button.

To read a file from disk to the editor, type ht e file name in the text field at the right of the button Update and click on this Update button.

 

 

 

 

8

Programming inside abs

 

The source code

The source code of abs is available for two reasons:

quick fix of bugs.

adding of custom functionality's to ABVisual.

The object definition

Abs is written in C because the C++ is not always available as a standard on UNIX platform and because C ANSI is probably the easiest language to port across UNIX world. Abs is written with the object concept in mind and all the ABVisual data are stored in object like structures.

The object structure that store the data and functions is defined in the file object.h, directory ABV:

An object has tree parts. The first part is called ‘rec’ and is the part where the data is recorded. The data can be either an integer, a double, a pointer to a character array or a pointer to a void function. The second part of the object is its type which is stored into an integer. The last part is a pointer to a label that can be associated to the object (mainly for debug purpose).

The functions that are used to manipulate the objects are declared in the file object.h and defined in the file object.c. The first kind of function are the cast operators. The second kind are the memory management function. The third kind are object manipulation like de-reference to access the object members.

An object is member of another object if its type is MEMBER. In this case, the data of the member is a pointer to the parent object. The label tell which member the object is.

The parent at the top has, as an object data, a pointer to a structure that old all the data of the object.

adding a new build-in function

Definition of the new function: file myfct.h

Create a new function definition file called myfct.h in the ABV directory.

 

Write the function: myfct.c

 

Include the new function definition file into the file init.c

And tell ABVisual to learn the new functions:

 

adding a new class to ABVisual

Definition of the new class: file my_vb.h

Create a new class definition file called myfct.h in the Interface directory.

Write the class functions: my_vb.c

In the file init.c

Include the new class definition file into the file init.c

 

And tell ABVisual to learn the new class:

 

interfacing with other code

The easiest way to interface abs with another code is to define an interface class inside ABV and to link abs code with the other code. As this solution is not always easy to implement and to maintain, another solution is to use a plugin technology that consist of starting the other application from abs and to exchange message between abs and the other application.

The plugin system will be designed as and ABVisual class in further implementation of abs. The solution for now is to use the function defined in the file startplug.c, directory Kernel.

There are three function: startplug, send and receive.

The message protocol is rather simple: send 5 bytes to tell the lenght of the message, then send the message.

 

 

 

 

 

 

9

Support

 

Getting support for abs

There is no support for the unregistred copies of abs. In case of problem, send a mail to abs@ping.be or abs@pi.be and we will try to fix it as soon as possible.

The only way to get a fast and efficient support is to get a registred copy of abs. Send a mail to abs@ping.be or abs@pi.be with REGISTER as subject to receive more information.

 

 

 

 

 

 

10

License and copyrights

 

 

Copyright (C) 1998-2000 André Bertin (Andre.Bertin@ping.be)

This program, abs, is free software; you can redistribute it and/or modify

it under the terms of the GNU General Public License as published by

the Free Software Foundation; either version 2 of the License, or

(at your option) any later version if it respects the spirit of version 2.

This program, abs, is distributed in the hope that it will be useful,

but WITHOUT ANY WARRANTY; without even the implied warranty of

MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

See the GNU General Public License (follows hereafter) for more details.

 

GNU GENERAL PUBLIC LICENSE

Version 2, June 1991

Copyright (C) 1989, 1991 Free Software Foundation, Inc.

675 Mass Ave, Cambridge, MA 02139, USA

Everyone is permitted to copy and distribute verbatim copies

of this license document, but changing it is not allowed.

Preamble

The licenses for most software are designed to take away your

freedom to share and change it. By contrast, the GNU General Public

License is intended to guarantee your freedom to share and change free

software--to make sure the software is free for all its users. This

General Public License applies to most of the Free Software

Foundation's software and to any other program whose authors commit to

using it. (Some other Free Software Foundation software is covered by

the GNU Library General Public License instead.) You can apply it to

your programs, too.

When we speak of free software, we are referring to freedom, not

price. Our General Public Licenses are designed to make sure that you

have the freedom to distribute copies of free software (and charge for

this service if you wish), that you receive source code or can get it

if you want it, that you can change the software or use pieces of it

in new free programs; and that you know you can do these things.

To protect your rights, we need to make restrictions that forbid

anyone to deny you these rights or to ask you to surrender the rights.

These restrictions translate to certain responsibilities for you if you

distribute copies of the software, or if you modify it.

For example, if you distribute copies of such a program, whether

gratis or for a fee, you must give the recipients all the rights that

you have. You must make sure that they, too, receive or can get the

source code. And you must show them these terms so they know their

rights.

We protect your rights with two steps: (1) copyright the software, and

(2) offer you this license which gives you legal permission to copy,

distribute and/or modify the software.

Also, for each author's protection and ours, we want to make certain

that everyone understands that there is no warranty for this free

software. If the software is modified by someone else and passed on, we

want its recipients to know that what they have is not the original, so

that any problems introduced by others will not reflect on the original

authors' reputations.

Finally, any free program is threatened constantly by software

patents. We wish to avoid the danger that redistributors of a free

program will individually obtain patent licenses, in effect making the

program proprietary. To prevent this, we have made it clear that any

patent must be licensed for everyone's free use or not licensed at all.

The precise terms and conditions for copying, distribution and

modification follow.

 

GNU GENERAL PUBLIC LICENSE

TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION

0. This License applies to any program or other work which contains

a notice placed by the copyright holder saying it may be distributed

under the terms of this General Public License. The "Program", below,

refers to any such program or work, and a "work based on the Program"

means either the Program or any derivative work under copyright law:

that is to say, a work containing the Program or a portion of it,

either verbatim or with modifications and/or translated into another

language. (Hereinafter, translation is included without limitation in

the term "modification".) Each licensee is addressed as "you".

Activities other than copying, distribution and modification are not

covered by this License; they are outside its scope. The act of

running the Program is not restricted, and the output from the Program

is covered only if its contents constitute a work based on the

Program (independent of having been made by running the Program).

Whether that is true depends on what the Program does.

1. You may copy and distribute verbatim copies of the Program's

source code as you receive it, in any medium, provided that you

conspicuously and appropriately publish on each copy an appropriate

copyright notice and disclaimer of warranty; keep intact all the

notices that refer to this License and to the absence of any warranty;

and give any other recipients of the Program a copy of this License

along with the Program.

You may charge a fee for the physical act of transferring a copy, and

you may at your option offer warranty protection in exchange for a fee.

2. You may modify your copy or copies of the Program or any portion

of it, thus forming a work based on the Program, and copy and

distribute such modifications or work under the terms of Section 1

above, provided that you also meet all of these conditions:

a) You must cause the modified files to carry prominent notices

stating that you changed the files and the date of any change.

b) You must cause any work that you distribute or publish, that in

whole or in part contains or is derived from the Program or any

part thereof, to be licensed as a whole at no charge to all third

parties under the terms of this License.

c) If the modified program normally reads commands interactively

when run, you must cause it, when started running for such

interactive use in the most ordinary way, to print or display an

announcement including an appropriate copyright notice and a

notice that there is no warranty (or else, saying that you provide

a warranty) and that users may redistribute the program under

these conditions, and telling the user how to view a copy of this

License. (Exception: if the Program itself is interactive but

does not normally print such an announcement, your work based on

the Program is not required to print an announcement.)

These requirements apply to the modified work as a whole. If

identifiable sections of that work are not derived from the Program,

and can be reasonably considered independent and separate works in

themselves, then this License, and its terms, do not apply to those

sections when you distribute them as separate works. But when you

distribute the same sections as part of a whole which is a work based

on the Program, the distribution of the whole must be on the terms of

this License, whose permissions for other licensees extend to the

entire whole, and thus to each and every part regardless of who wrote it.

Thus, it is not the intent of this section to claim rights or contest

your rights to work written entirely by you; rather, the intent is to

exercise the right to control the distribution of derivative or

collective works based on the Program.

In addition, mere aggregation of another work not based on the Program

with the Program (or with a work based on the Program) on a volume of

a storage or distribution medium does not bring the other work under

the scope of this License.

3. You may copy and distribute the Program (or a work based on it,

under Section 2) in object code or executable form under the terms of

Sections 1 and 2 above provided that you also do one of the following:

a) Accompany it with the complete corresponding machine-readable

source code, which must be distributed under the terms of Sections

1 and 2 above on a medium customarily used for software interchange; or,

b) Accompany it with a written offer, valid for at least three

years, to give any third party, for a charge no more than your

cost of physically performing source distribution, a complete

machine-readable copy of the corresponding source code, to be

distributed under the terms of Sections 1 and 2 above on a medium

customarily used for software interchange; or,

c) Accompany it with the information you received as to the offer

to distribute corresponding source code. (This alternative is

allowed only for noncommercial distribution and only if you

received the program in object code or executable form with such

an offer, in accord with Subsection b above.)

The source code for a work means the preferred form of the work for

making modifications to it. For an executable work, complete source

code means all the source code for all modules it contains, plus any

associated interface definition files, plus the scripts used to

control compilation and installation of the executable. However, as a

special exception, the source code distributed need not include

anything that is normally distributed (in either source or binary

form) with the major components (compiler, kernel, and so on) of the

operating system on which the executable runs, unless that component

itself accompanies the executable.

If distribution of executable or object code is made by offering

access to copy from a designated place, then offering equivalent

access to copy the source code from the same place counts as

distribution of the source code, even though third parties are not

compelled to copy the source along with the object code.

4. You may not copy, modify, sublicense, or distribute the Program

except as expressly provided under this License. Any attempt

otherwise to copy, modify, sublicense or distribute the Program is

void, and will automatically terminate your rights under this License.

However, parties who have received copies, or rights, from you under

this License will not have their licenses terminated so long as such

parties remain in full compliance.

5. You are not required to accept this License, since you have not

signed it. However, nothing else grants you permission to modify or

distribute the Program or its derivative works. These actions are

prohibited by law if you do not accept this License. Therefore, by

modifying or distributing the Program (or any work based on the

Program), you indicate your acceptance of this License to do so, and

all its terms and conditions for copying, distributing or modifying

the Program or works based on it.

6. Each time you redistribute the Program (or any work based on the

Program), the recipient automatically receives a license from the

original licensor to copy, distribute or modify the Program subject to

these terms and conditions. You may not impose any further

restrictions on the recipients' exercise of the rights granted herein.

You are not responsible for enforcing compliance by third parties to

this License.

7. If, as a consequence of a court judgment or allegation of patent

infringement or for any other reason (not limited to patent issues),

conditions are imposed on you (whether by court order, agreement or

otherwise) that contradict the conditions of this License, they do not

excuse you from the conditions of this License. If you cannot

distribute so as to satisfy simultaneously your obligations under this

License and any other pertinent obligations, then as a consequence you

may not distribute the Program at all. For example, if a patent

license would not permit royalty-free redistribution of the Program by

all those who receive copies directly or indirectly through you, then

the only way you could satisfy both it and this License would be to

refrain entirely from distribution of the Program.

If any portion of this section is held invalid or unenforceable under

any particular circumstance, the balance of the section is intended to

apply and the section as a whole is intended to apply in other

circumstances.

It is not the purpose of this section to induce you to infringe any

patents or other property right claims or to contest validity of any

such claims; this section has the sole purpose of protecting the

integrity of the free software distribution system, which is

implemented by public license practices. Many people have made

generous contributions to the wide range of software distributed

through that system in reliance on consistent application of that

system; it is up to the author/donor to decide if he or she is willing

to distribute software through any other system and a licensee cannot

impose that choice.

This section is intended to make thoroughly clear what is believed to

be a consequence of the rest of this License.

8. If the distribution and/or use of the Program is restricted in

certain countries either by patents or by copyrighted interfaces, the

original copyright holder who places the Program under this License

may add an explicit geographical distribution limitation excluding

those countries, so that distribution is permitted only in or among

countries not thus excluded. In such case, this License incorporates

the limitation as if written in the body of this License.

9. The Free Software Foundation may publish revised and/or new versions

of the General Public License from time to time. Such new versions will

be similar in spirit to the present version, but may differ in detail to

address new problems or concerns.

Each version is given a distinguishing version number. If the Program

specifies a version number of this License which applies to it and "any

later version", you have the option of following the terms and conditions

either of that version or of any later version published by the Free

Software Foundation. If the Program does not specify a version number of

this License, you may choose any version ever published by the Free Software

Foundation.

10. If you wish to incorporate parts of the Program into other free

programs whose distribution conditions are different, write to the author

to ask for permission. For software which is copyrighted by the Free

Software Foundation, write to the Free Software Foundation; we sometimes

make exceptions for this. Our decision will be guided by the two goals

of preserving the free status of all derivatives of our free software and

of promoting the sharing and reuse of software generally.

NO WARRANTY

11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY

FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN

OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES

PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED

OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF

MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS

TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE

PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,

REPAIR OR CORRECTION.

12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING

WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR

REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,

INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING

OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED

TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY

YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER

PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE

POSSIBILITY OF SUCH DAMAGES.

END OF TERMS AND CONDITIONS