Object NetBeans
Object NetBeans
Object NetBeans
_______________
A Thesis
Presented to the
Faculty of
_______________
In Partial Fulfillment
Master of Science
in
Computer Science
_______________
by
Akhil Latta
Fall 2010
iii
Copyright 2010
by
Akhil Latta
DEDICATION
I dedicate this thesis to my family members who have helped me gain confidence and
motivated me to complete my work.
v
A user can plot polyline and polygon using Google APIs as well as using ArcGIS 9.
I chose MapObjects to display the data points. A polygon can represent a property or a lake
on a county map whereas a polyline could represent a border or a route.
The thesis explores polyline and polygon plotting on a map using Map Objects. It
enables users to plot polyline and polygon on a map. This thesis makes use of a recent
technology which enables users to plot data without buying expensive software. Moreover
using a computer simulation rather than referring to a paper map is much more engaging and
better aligned to the interests of modern users. User can save the plotted polygon and
polyline as a shape file or a text file. A user can easily load their data points from a text file
and the application will plot a polyline or polygon based on the co-ordinates provided in the
file. The application also computes the total distance of the polyline as well as the perimeter
of the polygon plotted by the user. A customized toolbar has been added to make the GUI of
the application more users friendly. Help System has been embedded into the application to
guide the user.
The application utilizes Map Objects Java Edition and Java programming language.
ESRI provides Map Objects Java Edition for free. Every attempt has been made to present
subject in depth using a user friendly interface.
vi
TABLE OF CONTENTS
PAGE
ABSTRACT ...............................................................................................................................v
LIST OF TABLES ................................................................................................................. viii
LIST OF FIGURES ................................................................................................................. ix
ACKNOWLEDGEMENTS ..................................................................................................... xi
CHAPTER
1 INTRODUCTION .........................................................................................................1
1.1 GIS .....................................................................................................................1
1.1.1 Components of a Geographic Information System ...................................1
1.1.2 How a GIS Works .....................................................................................2
1.2 Overview ............................................................................................................4
2 TECHNOLOGY ............................................................................................................6
2.1 JAVA .................................................................................................................6
2.2 Map Objects JAVA Edition ...............................................................................6
3 REQUIREMENTS.........................................................................................................8
3.1 Platform Requirements ......................................................................................8
3.2 Functional Requirements ...................................................................................8
3.3 Other Requirements ...........................................................................................8
4 WORKING WITH GEOMETRY..................................................................................9
4.1 About the Object Model for Geometry ..............................................................9
4.1.1 Geometry Collection Interface ................................................................10
4.1.2 ClementiniGeometry Interface................................................................10
4.1.3 FeatureGeometry Interface .....................................................................10
4.2 Accessing the Geometry ..................................................................................11
4.3 Polygons...........................................................................................................11
4.3.1 Convex Polygon ......................................................................................12
4.3.2 Concave Polygon ....................................................................................13
4.3.3 Identifying Polygon Geometry ...............................................................13
vii
4.4 Polylines...........................................................................................................14
5 SHAPEFILE ................................................................................................................17
5.1 Elementary Depiction ......................................................................................17
5.2 Crafting a Shapefile .........................................................................................17
5.3 Main File ..........................................................................................................17
6 NETBEANS IDE AND MAP OBJECTS ....................................................................22
6.1 Elementary Facts ..............................................................................................22
6.2 Step by Step Project Creation ..........................................................................22
7 UNDERSTANDING TOOLBARS .............................................................................29
7.1 ZoomPan ToolBar ............................................................................................29
7.2 Add Delete Layer .............................................................................................30
7.3 Selection Toolbar .............................................................................................31
7.4 MeasureGeocode Toolbar ................................................................................33
8 CUSTOM TOOLBAR .................................................................................................34
9 FUTURE ENHANCEMENTS ....................................................................................42
REFERENCES ........................................................................................................................43
APPENDIX
A LIST OF ACRONYMS ...............................................................................................44
B README .....................................................................................................................46
viii
LIST OF TABLES
PAGE
LIST OF FIGURES
PAGE
ACKNOWLEDGEMENTS
I would like to express my sincere appreciation for my advisor Dr. Carl Eckberg for
giving me the opportunity to work on this thesis project. His constant guidance, support and
motivation throughout this project have helped me achieving my goal.
I would like to thank Professor William A. Root and Professor Carmelo Interlando for
being my committee members and for their help and co-operation.
I would also like to thank my wife Richa, my parents Mr. Bhupesh Latta and Mrs.
Himani Latta, and my brother Karan for their constant support. This would not have been
achieved without their love and blessings.
I would take this opportunity to thank my friends Abhishek Sood, Sumit Paul, Kunal
Sood, Sachin Jain and Digvijay Singh for always encouraging and supporting me.
1
CHAPTER 1
INTRODUCTION
The tool has been developed using MapObjects [1] and java programming language
with Net Beans IDE (Integrated Development Environment) [2].What is MapObjects? Well it
is a suite of Java-based developer components for creating client or server side mapping and
GIS applications.
1.1 GIS
A geographic information system (GIS) integrates hardware, software, and data for
capturing, managing, analyzing, and displaying all forms of geographically referenced
information.
GIS allows us to view, understand, question, interpret, and visualize data in many
ways that reveal relationships, patterns, and trends in the form of maps, globes, reports, and
charts.
A GIS helps you answer questions and solve problems by looking at your data in a
way that is quickly understood and easily shared [3]. GIS technology can be integrated into
any enterprise information system framework [3].
Data: It is a vital part of any application, GIS integrates data such as spatial
data and data from other resources. Geographic data can be collected in-house
or produced by digitizing images from aerial photographs or published maps.
You can purchase data from any commercial vendor. Also, federal government
provides data at no cost [4].
People: GIS users can range from professionals to students at high school [4].
Method: How well a GIS will operate depends on few factors. These factors
can be, how well-designed the plan and its implementation is. Are business
rules ideal for GIS implementation? These factors can be unique to each
organization [4].
approach, first we create a database and then we digitize the paper map into a GIS
compatible format. The database will be continuous and scale free since it is GIS based
cartographic. We can then create map products highlighting any location irrespective of scale
[4]. Figure 1.1 depicts the different stages involved in map making.
Manipulation of Data: Most of the times, it will be required to manipulate in some way to
make it compatible with your system [4].
File Management: It is very important for all applications. Some GIS projects may store
projects as simple files while other might require a more sophisticated file management
system. Using a database management system (DBMS) is the solution. It will be easier to
store, organize and manage data when the data volumes are large and the numbers of users
are high. A DBMS is nothing more than computer software for managing a database--an
integrated collection of data [4]. An example of relational design is shown in Figure 1.2.
Query and Analysis: After the GIS is fully functional; you can begin to ask simple
questions such as [4]:
4
1.2 OVERVIEW
Why do we need such an application? It makes it easier for the users to understand
the co-ordinates by visualizing them. Why do I apt for this particular one? This application is
a freeware, comes in a JAR (See Appendix A) file which is easy to use. What exactly this
5
does? Application allows users to plot polyline and polygon on the map. A customized
toolbar which make this application easy to use has been integrated. A user can select tools
from the toolbar and plot anywhere on the map. Further when it comes to saving the plotted
data, user is given two options either save it as a shape file or as a text file. In chapter 2 we
discuss the technology that has been used and the reason for choosing it. Chapter 3 talks
about the requirements. Chapter 4 will give you a brief overview about the geometry
involved. Polygon and polyline in terms of both geometry and Map Objects has been
discussed. Chapter 5 takes you to shape files, which is the data GIS accepts. In this chapter
we discuss the various ways to create the shape files and how to deal with storing them. In
chapter 6, we discuss how to integrate Map objects with Net Beans IDE (Integrated
Development system). Chapter 7 discusses the standard toolbars while chapter 8 discusses
the customized toolbars. Chapter 9 lists some future enhancements that can be implemented
to make this application more robust. How to use this application? This question has been
answered in Appendix B. Listed there is a step by step procedure that enables user to get the
feel of the application and steps to use it.
6
CHAPTER 2
TECHNOLOGY
2.1 JAVA
Map Objects Java edition, the name justifies the use of java. Java has significant
advantages over other languages and environments that make it suitable for this application.
Some of advantages of Java are as follows:
Easy to learn: I was a novice user when it comes to java. I was good at C/C++;
hence Java was very easy to learn as the syntax is very similar. Moreover Java
was has been designed to be easy to use and is therefore easy to write, compile,
debug, and learn compared to other programming languages [5].
Object-oriented: I was able to make modular programs and reusable code.
Reusability and extensibility were in my mind while I was deciding on the
language to use in this project. Java enables you to do just that; the individual
classes can be extended and reused to add more features [5, 6].
Platform-independent: One of the requirements was that the tool should be
platform independent. A significant advantage of Java is its ability to be
portable. The ability to run the same program on many different systems is very
useful as users can operate from different systems.
Robustness: Reliability is something that no language can promise. A user can
come across errors while writing and compiling code. Java compiler is really
smart when it comes to error checking; also java does an early error checking
which warns the user about the possible errors and warnings [5].
Security: Java provides a secured environment for a user [5].
Key features as cited from the Map Objects Java Edition brochure which can be
found at [1] are following:
Linking of Various Distributed Data Sources: MOJO allows users to pool local
data with data available on internet to create customized data. This customized
data can be simply integrated with the existing application. Some of the data
formats supported are shapefiles, ArcSDE layers, ArcIMS image and feature
services, Image formats such as BMP, TIFF, PNG, JPG, GIF etc [6].
GIS Proficiencies: Applications made using MOJO have some abilities added
to their functionality such as Labeling map features, Thematic mapping,
Panning and zooming through multiple map layers, Specifying projections,
Querying spatial and attribute data, Performing geometric operations,
Measuring distances, Displaying real time geographic data, and creating layouts
[6].
Easy to Build a User Interface. Polyline and Polygon plotting in Map Objects
has a customized toolbar which was created by bringing in use swing
components with MOJO. A user can easily build applications that include
functional toolbars, dynamic symbol control, query dialogs, overview and insert
maps, and intelligent legends that make your custom applications easy to use
and even easier to develop [6].
8
CHAPTER 3
REQUIREMENTS
The application is a freeware that will enable users to plot on map. The requirement
was to make an interactive tool for users for plotting in Map Objects. The requirements
gathered have been classified into Platform requirements, Functional requirements, and other
requirements.
CHAPTER 4
What defines an objects shape? It is the geometric properties of an object that define
its shape. Gaining access to these properties is very important to perform the GIS operations.
MapObjects libraries can be used to perform various geometric operations such as [1]:
Creating new geometric shapes using Map component.
Returning the geometry of selected shapes.
Obtaining interior and exterior rings of a polygon.
Determining the distance between shapes.
Calculating perimeter, area, union of selected shapes.
Figure 4.1 shows the relation between different components of the object model.
Figure 4.1. Object model for geometry. Source: ESRI, MapObjects Java Edition manual,
Esri Press, Redlands, California, 2003.
if (layer.hasSelection()) {
ss= layer.getSelectionSet();
cursor= layer.getSelectedData(ss);
if (cursor!=null) {
while (cursor.hasMore()) {
feature= (Feature)cursor.next();
geometry= feature.getGeometry();
}}
4.3 POLYGONS
Polygons are collection of rings. A ring is defined as a closed path of line segments.
Polygons can have collection of one or more of such rings. The segments are edges which
meet in pairs at corners called vertices. The picture shows several regular polygons, which
12
have equal angles and equal edge lengths [7]. Figure 4.3 shows the different kind of polygons
we usually come across. Regular Polygons:
com.esri.mo2.cs.geom.Point p;
com.esri.mo2.cs.geom.PointCollection pnts;
com.esri.mo2.cs.geom.Polygon poly;
com.esri.mo2.cs.geom.Ring ring;
System.out.Println(Polygon);
Poly= (Polygon)geometry;
System.out.println(ring cnt : +
poly.size());
14
Pnts= ring.getPoints();
System.out.println(pnts cnt: +
pnts.size());
4.4 POLYLINES
Polyline is a collection of one or more paths. These paths allow you to access
underlying line segment that make up the geometry. com.esrimo2.cs.geom.Polyline interface
class represents such path [7]. A simple polyline plotted using the application is shown in the
Figure 4.6. Polyline Plotted using the tool depicting San Andreas fault line:
Figure 4.7. Polyline class interface. Source: MUNAF, Java advantages and disadvantages.
Web-Dot-Dev, http://www.webdotdev.com/nvd/content/view/1042/204/, accessed May
2010, 2007.
We use following example to identify polyline geometry. Assuming that the features
geometry has already been obtained, it displays the number of paths in the polyline [1].
com.esri.mo2.cs.geom.FeatureGeometry geometry;
com.esri.mo2.cs.geom.Path path;
com.esri.mo2.cs.geom.Point p;
com.esri.mo2.cs.geom.PointCollection pnts;
com.esri.mo2.cs.geom.Polyline pline;
System.out.Println(Polyline);
pline= (Polyline)geometry;
System.out.println(path cnt : +
pline.size());
Path= pline.getPath(0);
Pnts= Path.getPoints();
System.out.println(point cnt: +
pnts.size());
16
P= pnts.getPoint(0);
System.out.println(X[0]: + p.x +
, Y[0]: + p.y);
}
17
CHAPTER 5
SHAPEFILE
1. Organization of Main File: The header of the main file is of fixed length but the
records that follow can have variable length [9]. An example of a file header is
shown in Figure 5.2.
2. Main File Header: Since header is of fixed length i.e. 100 bytes. Position is
referenced from start of the main file. The value of file length is total length of file
in 16 bit words [9] Tables 5.1 and 5.2 show the different values a main file header
has and the shape types.
19
3. Main File Record Content: The length of the record content file varies with the
number of edges and vertices of the shape. The record content file consists of shape
type and geometric data of the shape [9]. An example of record content is shown in
Figure 5.3.
20
CHAPTER 6
CHAPTER 7
UNDERSTANDING TOOLBARS
Map Objects Java Edition provides toolbars which comprise of commonly used
functions such as zoom in, zoom out, add/delete etc. In this chapter we discuss how these
toolbars have been integrated into the tool. Code to add these toolbars is also listed below.
Some of the frequently used toolbars are discussed below. [6, 10].
Figure 7.1 shows the default toolbar that comes with Map Objects.
zoomPanToolBar1.setMap(map1);
getContentPane().add(zoomPanToolBar1,BorderLayout.NORTH);
layerToolBar1.setMap(map1);
getContentPane().add(layerToolBar1,BorderLayout.NORTH);
selectionToolBar1.setMap(map1);
getContentPane().add(selectionToolBar1,BorderLayout.NORTH);
33
Though the measure geocode toolbar is not frequently used but it contains important
set of tools. Table 7.4 defines the functions of this toolbar.
measureGeocodeToolBar1.setMap(map1);
getContentPane().add(measureGeocodeToolBar1, BorderLayout.
34
CHAPTER 8
CUSTOM TOOLBAR
Additional toolbar was created to assist user and make the working experience more
user friendly. The custom toolbar allows user to perform some vital functions without
navigating any further.
The Figure 8.1 shows the custom toolbar [6]:
a. Print: This tool assists the user to print the map. A user can plot the data and simply
hit this button to print out the map with user data on it.
addComponentListener(complistener);
map.setSelectedTool(drawLine);
} else if (source == drawPljb) {
map.setSelectedTool(drawPolygon);
} else {
try {
AddLyrDialog aldlg = new AddLyrDialog();
aldlg.setMap(map);
aldlg.setVisible(true);
} catch (IOException e) {
}
}
}
enableDisableButtons();
}
};
b. Add a Layer: If a user wants to add a new shape file, he can just click on this icon
and add it.
import java.awt.BorderLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import java.io.IOException;
import javax.swing.JButton;
import javax.swing.JDialog;
import javax.swing.JPanel;
import com.esri.mo2.ui.bean.Map;
}
});
PolylinesandPolygons.promoteitem.setEnabled(true);
} catch(IOException e){}
}
}
};
ok.addActionListener(lis);
cancel.addActionListener(lis);
getContentPane().add(cus,BorderLayout.CENTER);
panel1.add(ok);
panel1.add(cancel);
getContentPane().add(panel1,BorderLayout.SOUTH);
}
public void setMap(com.esri.mo2.ui.bean.Map map1){
map = map1;
}
}
c. Arrow: Clicking on this icon will give you back the mouse pointer. What it will do is
that, it will clear the selected tool and return mouse pointer. This tool is also used to
erase the data you plotted on the map.
d. Point Plotting: This tool allows the user to plot a point anywhere on the map. The
point would be a blue color circular point.
import java.awt.Color;
import java.awt.event.MouseEvent;
import com.esri.mo2.cs.geom.Point;
import com.esri.mo2.map.draw.SimpleMarkerSymbol;
37
import com.esri.mo2.ui.bean.AcetateLayer;
import com.esri.mo2.ui.bean.Map;
import com.esri.mo2.ui.bean.Tool;
@Override
public void paintComponent(java.awt.Graphics g) {
if (pt != null) {
java.awt.Graphics2D g2d = (java.awt.Graphics2D) g;
g2d.setTransform(
map.getWorldToPixelTransform().toAffine());
g2d.setClip(map.getExtent());
sms.draw(pt, g2d, );
}
}
};
public DrawPoint() {
sms.setType(SimpleMarkerSymbol.CIRCLE_MARKER);
sms.setWidth(6);
sms.setSymbolColor(Color.blue);
map.add(acetLayer);
}
@Override
public void mouseClicked(MouseEvent me) {
pt = map.transformPixelToWorld(me.getX(), me.getY());
acetLayer.repaint();
}
}
e. Polyline Plotting: Select this tool from the toolbar and start clicking on the map to
plot the points. As soon as you plot the second point line segments gets start drawing.
As you go on, you can see a polyline being plotted. The total distance of the polygon
is visible at the bottom of the application.
import com.esri.mo2.cs.geom.BasePath;
import com.esri.mo2.cs.geom.BasePointsArray;
import com.esri.mo2.cs.geom.BasePolyline;
import com.esri.mo2.cs.geom.FeatureGeometry;
38
import java.awt.Color;
import java.awt.event.MouseEvent;
import com.esri.mo2.cs.geom.Point;
import com.esri.mo2.cs.geom.PointCollection;
import com.esri.mo2.map.draw.SimpleLineSymbol;
import com.esri.mo2.map.draw.SimpleMarkerSymbol;
import com.esri.mo2.ui.bean.AcetateLayer;
import com.esri.mo2.ui.bean.Map;
import com.esri.mo2.ui.bean.Tool;
@Override
public void paintComponent(java.awt.Graphics g) {
java.awt.Graphics2D g2d = (java.awt.Graphics2D) g;
g2d.setTransform(
map.getWorldToPixelTransform().toAffine());
g2d.setClip(map.getExtent());
for (int i = 0; i < pc.size(); i++) {
sms.draw(pc.getPoint(i), g2d, "");
}
if (pc.size() >= 2) {
FeatureGeometry geom = new BasePolyline(new BasePath(pc));
sls.draw(geom, g2d, "");
}
}
};
public DrawLine() {
sms.setType(SimpleMarkerSymbol.STAR_MARKER);
sms.setWidth(6);
sms.setSymbolColor(Color.blue);
sls.setLineColor(Color.RED);
map.add(acetLayer);
}
setDistance(0);
}
@Override
public void mouseReleased(MouseEvent me) {
Point p = map.transformPixelToWorld(me.getX(), me.getY());
addDistance(p);
pc.addPoint(p);
acetLayer.repaint();
}
f. Polygon Plotting: Selecting this tool enables a user to plot a polygon. If a user starts
plotting point either in clockwise or anti-clockwise direction keeping all the angles
less than 180 degrees, he will end up with a convex polygon. The polygon will be
solid fill. Perimeter of the polygon is available at the bottom of the application.
import com.esri.mo2.cs.geom.BasePointsArray;
import com.esri.mo2.cs.geom.BasePolyline;
import com.esri.mo2.cs.geom.BaseRing;
import java.awt.Color;
import java.awt.event.MouseEvent;
import com.esri.mo2.cs.geom.Point;
import com.esri.mo2.cs.geom.PointCollection;
import com.esri.mo2.map.draw.SimpleMarkerSymbol;
import com.esri.mo2.map.draw.SimplePolygonSymbol;
import com.esri.mo2.ui.bean.AcetateLayer;
import com.esri.mo2.ui.bean.Map;
import com.esri.mo2.ui.bean.Tool;
@Override
public void paintComponent(java.awt.Graphics g) {
java.awt.Graphics2D g2d = (java.awt.Graphics2D) g;
g2d.setTransform(
map.getWorldToPixelTransform().toAffine());
g2d.setClip(map.getExtent());
for (int i = 0; i < pc.size(); i++) {
sms.draw(pc.getPoint(i), g2d, "");
}
if (pc.size() > 2) {
BasePolyline geom = new BasePolyline(new BaseRing(pc));
PolylinesandPolygons.distanceLabel.setText("Perimeter : "+
geom.getPerimeter());
sps.draw(geom, g2d, "");
}else{
PolylinesandPolygons.distanceLabel.setText("");
}
}
};
public DrawPolygon() {
sms.setType(SimpleMarkerSymbol.STAR_MARKER);
sms.setWidth(10);
sms.setSymbolColor(Color.blue);
sms.setOverlap(true);
sps.setLineColor(Color.RED);
sps.setPaint(Color.PINK);
sps.setFillTransparency(0.5d);
map.add(acetLayer);
}
@Override
public void mouseReleased(MouseEvent me) {
41
g. Help: This is an alternate help to the help present in the menu bar. Click on this help
icon and then on any of the custom toolbar icon to learn more about that tool.
42
CHAPTER 9
FUTURE ENHANCEMENTS
REFERENCES
WORKS CITED
[1] ESRI, MapObjects Java Edition manual, Esri Press, Redlands, California, 2003.
[2] NETBEANS, NetBeans IDE download. Netbeans, http://www.netbeans.org/downloads/,
accessed November 2009, 2007.
[3] ESRI, Gis.com. Gis, http://www.gis.com/, accessed November 2009, 2001.
[4] A. E. THROCKMORTON, Geographic Information Systems. Westminister University,
http://www.westminster.edu/staff/athrock/GIS/GIS.pdf, accessed April 2010, 2003.
[5] MUNAF, Java advantages and disadvantages. Web-Dot-Dev,
http://www.webdotdev.com/nvd/content/view/1042/204/, accessed May 2010, 2007.
[6] D. KUNDRA, Natural Disaster GIS Teaching Aid, Masters thesis, San Diego State
University, San Diego, CA, 2008.
[7] MATH.COM, Polygon Basics. Math, http://www.math.com/, accessed November 2009,
2001.
[8] C. ECKBERG, Course material for class CS 537, 2001.
[9] ESRI, White Papers. Esri, http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf
accessed May 2010, 2008.
[10] V. VERMA, Native American olympic participants and contributors, Masters thesis,
San Diego State University, San Diego, CA, 2009.
[11] ORACLE, Java JDK downloads. Java, http://java.sun.com/javase/downloads/index.jsp,
accessed June 2009, 2005.
WORKS CONSULTED
G. W. CHART, Polygons. George Hart, http://www.georgehart.com/virtual-
polyhedra/polygons.html, accessed December 2009, 2002.
ESRI, Forums. Esri, http://forums.esri.com/forums.asp?c=9, accessed May 2010,
2010.
ESRI, White Papers. Esri, http://resources.arcgis.com/content/white-papers, accessed
December 2009, 2008.
S. MENDIRATTA, Native American regions in United States of America, Masters
thesis, San Diego State University, San Diego, CA, 2009.
WIKIPEDIA, Shapefile. Wikipedia, http://en.wikipedia.org/wiki/Shapefile, accessed
January 2010, 2007.
44
APPENDIX A
LIST OF ACRONYMS
45
APPENDIX B
README
47
The only major system requirement is that the system should have a java version 1.4
or higher installed.
7. Select the polyline tool from the toolbar to plot a polyline. When you move your
mouse over the polyline icon in toolbar, a tooltip text saying draw a polyline on the
map will appear.
49
8. Start plotting points anywhere on the map. As soon as you plot the second point a
line segment will be drawn between the two points you have just plotted. Polyline
will get plotted as you move on. At the bottom next to the co-ordinates display you
can see the total distance of the polyline you plotted.
50
9. Select the polygon tool in the similar fashion you selected the polyline tool from the
toolbar.
51
10. Start plotting the points for the polygon in either clockwise or anti-clockwise
direction.
52
11. Once you are done plotting at least three points the polygon gets plotted. If you
continue plotting in clockwise or anti-clockwise direction keeping every angle less
than 180 degrees you will end up with a convex polygon. At the bottom next to the
co-ordinates display you can see the perimeter of the polygon you just plotted.
53
12. You can save the polygon/polyline you plotted either as a shape file or a text file.
Just click on the Save As in menu bar and select one of the two options.
54
Figure B.9. Select the location where you want to save the shape file.
13. Now since you have saved the polygon as shape file, you can add that as a layer.
Click on the add layer in the toolbar. Browse to the location you saved your shape
file and load it.
56
14. You can repeat step 8 for saving the file as a text file and loading it. The only
difference will be that when you load it, the polygon/polyline will not be visible as
a layer.
15. There is a help system embedded into the application which you can refer anytime
you come across some difficulty regarding the use of application. To invoke the
help system you can click on the help in menu bar and select help topics.