/[thuban]/branches/WIP-pyshapelib-bramz/Doc/manual/thuban-manual-de.xml
ViewVC logotype

Annotation of /branches/WIP-pyshapelib-bramz/Doc/manual/thuban-manual-de.xml

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2313 - (hide annotations)
Sun Aug 1 21:28:16 2004 UTC (20 years, 7 months ago) by jan
Original Path: trunk/thuban/Doc/manual/thuban-manual-de.xml
File MIME type: text/xml
File size: 86085 byte(s)
(Chapter Session Management): translation completed.

1 jan 2309 <?xml version="1.0" encoding="ISO-8859-1"?>
2     <!DOCTYPE book
3     PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
4     "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd"
5     [<!ENTITY imgscale "60">]>
6     <!-- $Revision$ -->
7     <book>
8     <bookinfo>
9     <title>Benutzerhandbuch für Thuban 1.0</title>
10     <authorgroup>
11     <author>
12     <firstname>Jonathan</firstname><surname>Coles</surname>
13     </author>
14     <author>
15     <firstname>Jan-Oliver</firstname><surname>Wagner</surname>
16     </author>
17     <author>
18     <firstname>Frank</firstname><surname>Koormann</surname>
19     </author>
20     </authorgroup>
21     <copyright>
22     <year>2004</year>
23     <holder>Intevation GmbH</holder>
24     </copyright>
25     <revhistory>
26     <!-- comment this first revision out when releasing a real version -->
27     <revision>
28     <revnumber>CVS version $Id$</revnumber>
29     <date></date>
30     <revremark>Under development.</revremark>
31     </revision>
32     <!--
33     <revision>
34     <revnumber>1.0.0</revnumber>
35     <date>nn-Mmm-2004</date>
36     <revremark>
37     Corresponds to Thuban 1.0.0.
38     </revremark>
39     </revision>
40     -->
41     </revhistory>
42    
43     </bookinfo>
44    
45     <chapter><title>Einführung</title>
46     <para>
47     Thuban ist ein interaktiver Geodaten-Betrachter.
48     Die Entwicklung wurde seinerzeit gestartet, da es zu dieser Zeit
49     keinen einfachen interkativen Betrachter für Geo-Daten als Freie
50     Software gab.
51     Thuban ist im wesentlichen in der Programmiersprache Python implementiert und
52     nutzt die wxWidgets (ehemals: wxWindows) Bibliothek die es erlaubt
53     Thuban auf verschiedenen Plattformen laufen zu lassen, darunter GNU/Linux
54     und Windows.
55     </para>
56     <para>
57     Geodatenbetrachter sind wichtige Werkzeuge die es gestatten, einen visuelle
58     Eindruck des räumlichen (gegenseiten) Bezuges von Informationen zu bekommen
59     die ansonsten anhand der reinen Daten nicht leicht ersichtlich sind.
60     Thuban erlaubt dem Benutzer, Sitzungen zu erzeugen, die geografische
61     Daten darstellen. Diese können dann erforscht werden indem er durch sie
62     sie navigieren und die Art der Darstellung ändern kann.
63     Die Ergebnisse können gespeichert oder gedruckt werden.
64     </para>
65     <para>
66     Thuban strukturiert eine Sitzung hierarchisch.
67     Eine Sitzung besteht aus Ebenen. Jede Ebene rerpäsentiert
68     einen bestimmten Datensatz.
69     Beispielsweise eine Ebene für Strassen und eine weitere für Gebäude.
70     Die Ebenen können sowohl Vektor-Daten beschreiben als auch Raster-Daten.
71     </para>
72    
73     <section><title>Installation</title>
74     <para>
75     Thuban is actively supported under Debian Testing (sarge), RedHat 7.2,
76     and Windows 2000. Thuban depends on the following packages. These
77     packages can also be found on the
78     <ulink url="http://thuban.intevation.org/download.html">
79     Thuban Download site
80     </ulink>.
81     </para>
82     <para>
83     Required:
84     <itemizedlist>
85     <listitem><para>Python 2.2.1
86     (<literal>http://www.python.org</literal>)
87     </para></listitem>
88     <listitem><para>wxWindows 2.4
89     (<literal>http://www.wxwindows.org</literal>)
90     </para></listitem>
91     <listitem><para>wxPython 2.4
92     (<literal>http://www.wxpython.org</literal>)
93     </para></listitem>
94     <listitem><para>proj 4.4.5 Projection Library
95     (<literal>http://www.remotesensing.org/proj/</literal>)
96     </para></listitem>
97     <listitem><para>SQLite 2.8.3
98     <literal>http://www.hwaci.com/sw/sqlite/</literal>)
99     </para></listitem>
100     <listitem><para>PySQLite 0.4.3
101     (<literal>http://pysqlite.sourceforge.net</literal>)
102     </para></listitem>
103     </itemizedlist>
104     </para>
105     <para>
106     Optional:
107     <itemizedlist>
108     <listitem><para>GDAL 1.1.8
109     (<literal>http://www.remotesensing.org/gdal/</literal>)
110     </para></listitem>
111     <listitem><para>psycopg 1.0.8
112     (<literal>http://initd.org/software/psycopg</literal>)
113     </para></listitem>
114     </itemizedlist>
115     </para>
116     <para>
117     Along with the source codes, the download page also offers full
118     installation packages for Debian, Windows and RPM-based systems
119     (Mandrake, RedHat, SuSE, etc).
120     </para>
121     <section><title>RPM-based GNU/Linux Systems</title>
122     <section><title>Installing Binary Packages</title>
123     <para>
124     The most wide-spread RPM-based GNU/Linux
125     Systems are RedHat, Mandrake and SuSE.
126     The documentation of these distributions
127     should contain information about how to
128     install third-party RPM packages.
129     Nonetheless, a short summary is provided here.
130     </para>
131     <para>
132     RPM packages can be installed applying several
133     tools. The most basic one is the command line
134     program "rpm". The hardware architecture is
135     identified in the name of RPM packages, eg.
136     'i386' for most Intel/AMD architectures.
137     If you have a different hardware architecture,
138     where no binary RPM packages are provided,
139     you must rebuild binary packages from the
140     RPM source packages first (see below).
141     Typical rpm commands look like:
142    
143     <programlisting>
144     rpm --install Thuban-0.9.0-1.i386.rpm
145     </programlisting>
146    
147     Depending on what you already have installed
148     on your system, you are informed that some
149     packages are required, but not installed.
150     You need to install them first. Either they
151     are provided by your GNU/Linux distributor
152     or available somewhere on the Internet.
153     The more essential and special ones are
154     provided together with the Thuban package.
155     </para>
156    
157     <para>
158     For rpm exist some graphical user interfaces, notably
159     kpackage, GnoRPM and xrpm.
160     </para>
161    
162     <para>
163     Make yourself familiar with one of the tools and apply it
164     to install the packages.
165     Note, that you need to be administrator (root) for the system
166     to do that.
167     </para>
168     </section>
169     <section><title>Build Binaries from Source Packages</title>
170     <para>
171     This section describes howto build RPM install-packages
172     from RPM source-packages.
173     This adapts and optimizes an install-package specifically
174     to your system.
175     This is especially helpful to resolve version conflicts of
176     dependent packages. Furthermore, install-packages for other
177     platforms (e.g. PowerPC) can be created.
178     </para>
179    
180     <para>
181     Note: rpm must be at least version 4. Execute
182     <literal>rpm --version</literal> to find out about the version.
183     </para>
184    
185     <para>
186     You need to do the following preparations to be able to
187     build the packages as a regular user. You should now
188     perform the package buling as root since this
189     might cause damage to your system.
190     <itemizedlist>
191     <listitem>
192     <para>
193     Create RPM directory structure:
194     Choose a directory (e.g. $HOME/myrpm) and create the
195     subdirectories BUILD, RPM, SOURCES, SPECS and SRPMS.
196     A possible command sequence for this is:
197     <programlisting>
198     mkdir $HOME/freegisrpm
199     cd $HOME/freegisrpm
200     mkdir BUILD RPMS SOURCES SPECS SRPMS
201     </programlisting>
202     </para>
203     </listitem>
204     <listitem>
205     <para>
206     Set environment variable RPM_DIR:
207     <programlisting>
208     export RPM_DIR=$HOME/freegisrpm
209     </programlisting>
210     </para>
211     </listitem>
212     <listitem>
213     <para>
214     Create $HOME/.rpmmacros:
215     This file sets general preferences and some
216     specific settings for signing packages.
217     If you don't have a GnuPG-key, you can skip
218     the signature settings i.e. drop the last 4 lines.
219     A signature becomes important when you want to
220     give away packages to third parties.
221     <programlisting>
222     <![CDATA[
223     %packager Name Lastname <[email protected]>
224    
225     %_topdir /home/mylogin/myrpm
226    
227     %_signature gpg
228     %_gpg_name Name Lastname
229     %_pgp_path ~/.gnupg
230     %_pgpbin /usr/bin/gpg
231     ]]>
232     </programlisting>
233     </para>
234     </listitem>
235     </itemizedlist>
236    
237     Now you can install any RPM source-package.
238     It's components are installed into the corresponding
239     subdirectories of your rpm-directory.
240     Essentially these are the sources (into directory SOURCES)
241     and the so-called spec-file which contains all build
242     instructions. The spec-file will go into the SPEC directory.
243     Example:
244     <literal>rpm --install Thuban-0.9.0-1.src.rpm</literal>
245     </para>
246    
247     <para>
248     Create install-package:
249     Go to the directory with the spec-files and rebuild the
250     package:
251     <programlisting>
252     cd $HOME/mypm/SPECS
253     rpm -bb thuban.spec
254     </programlisting>
255     Next, you will find the newly created package in
256     $HOME/myrpm/RPMS/i386.
257     If you build the package for another architecture than
258     i386, then the name of the directory has a corresponding name.
259     </para>
260     <para>
261     For documentation of RPM, either type
262     <literal>man rpm</literal> or <literal>rpm --help</literal>.
263     This will provide you with information on the various command
264     line options of RPM.
265     For more information see the
266     <ulink url="http://www.rpm.org/">homepage of RPM</ulink>.
267     </para>
268     </section>
269     </section> <!-- Intro - Installation - RPM-->
270    
271     <section><title>Win32 Systems</title>
272     <para>
273     A common installation package of Thuban for Win32
274     systems is available from the Thuban website download
275     section. This installation package is configured for
276     displaying file based vector data (Shapefiles). For the
277     display of raster data or the connection to spatial
278     databases additional steps are needed.
279     </para>
280     <para>
281     The required Python packages are listed and linked on
282     the download page as well. If you don't have Python
283     installed already, download the packages for Python,
284     wxPython for Python and the SQLite Python Libraries as
285     well as the Thuban package. Install all four packages
286     in the order: Python, wxPython, SQLite, Thuban. Follow
287     the installation instructions provided by the seperate
288     setups. The Thuban installation package will add an
289     entry in the menu folder you configured.
290     </para>
291     <section><title>Raster Data: Installation of GDAL</title>
292     <para>
293     Enabling the raster data features of Thuban is
294     straight forward. For the examples we assume that
295     Thuban has been installed under
296     <literal>C:\Thuban</literal>:
297     <itemizedlist>
298     <listitem>
299     <para>
300     Download the zip-archive <ulink
301     url="ftp://intevation.de/thuban/win2k/gdal-win2k.zip"
302     >gdal-win2k</ulink>.
303     </para></listitem>
304     <listitem><para>Extract the archive (e.g. with
305     <ulink
306     url="http://www.info-zip.org/pub/infozip/WiZ.html"
307     >WiZ (InfoZip)</ulink>) into the
308     <literal>C:\Thuban\Lib</literal>
309     directory of your Thuban installation.
310     </para>
311     </listitem>
312     <listitem>
313     <para>
314     Extent the <varname>PYTHONPATH</varname>
315     environment variable (in your Windows Control Panel)
316     to make the new libraries available for Thuban.
317     <programlisting>
318     %PYTHONPATH%;C:\Thuban\Lib\gdal;C:\Thuban\Lib\gdal\pymod
319     </programlisting>
320     </para>
321     </listitem>
322     <listitem>
323     <para>
324     Extent also the <varname>PATH</varname>
325     environment variable accordingly:
326     <programlisting>
327     %PATH%;C:\Thuban\Lib\gdal
328     </programlisting>
329     </para>
330     </listitem>
331     </itemizedlist>
332     After this installation steps Thuban is ready to
333     display raster data (e.g. the
334     <literal>island.tif</literal> from the Iceland Demo
335     data set.
336     </para>
337     </section> <!-- Win32: GDAL-->
338    
339     <section><title>Working with PostGIS: Installation of PsycoPG</title>
340     <para>
341     To access PostgreSQL/PostGIS spatial databases with
342     Thuban you have to install the PsycoPG package for
343     Windows:
344     <itemizedlist>
345     <listitem>
346     <para>
347     Download the zip-archive
348     <ulink
349     url="http://stickpeople.com/projects/python/win-psycopg/win-psycopg22.zip"
350     >win-psycopg22.zip</ulink>.
351     </para>
352     </listitem>
353     <listitem>
354     <para>
355     Extract the zip-archive into a directory either already
356     in your <varname>PYTHONPATH</varname> or extent your
357     <varname>PYTHONPATH</varname> variable to the directory
358     you have extracted the archive to.
359     </para>
360     </listitem>
361     </itemizedlist>
362     For installation and maintenance of spatial databases
363     we refer to the <ulink
364     url="http://postgis.refractions.net"
365     >PostGIS Homepage</ulink>.
366     </para>
367     </section> <!-- Win32: PsycoPG-->
368    
369     </section> <!-- Intro - Installation - Win32 -->
370     </section>
371    
372     <section><title>Internationalisierung</title>
373     <para>
374     Thuban ist mit Unterstützung für Internaionalisierung realisiert.
375     Bisher wurde Thuban in folgende Sprachen (neben der Basis Englisch) übersetzt:
376     <itemizedlist>
377     <listitem><para>Französisch</para></listitem>
378     <listitem><para>Deutsch</para></listitem>
379     <listitem><para>Italienisch</para></listitem>
380     <listitem><para>Portugiesisch (Brasilien)</para></listitem>
381     <listitem><para>Russisch</para></listitem>
382     <listitem><para>Spanisch</para></listitem>
383     </itemizedlist>
384     </para>
385    
386     <para>
387     Um die Internationalisierung auf POSIX Systemen (wie etwa GNU/Linux)
388     zu verwenden, muss die Umgebungsvariable LC_ALL entsprechend
389     gesetzt werden (z.B. LC_ALL=de_DE für Deutsch).
390     Prüfen Sie die Dokumentation zu Ihrem System für Details
391     und die unterstützten Einstellungen.
392     Normalweise haben Sie Ihre Sprache bereits mit der Installation
393     oder beim einloggen bereits vorausgewählt.
394     Trotzdem kann auch dann noch durch Setzen von LC_ALL auf
395     der Kommandozeile beim Aufruf von Thuban eine andere Sprache
396     gesetzt werden:
397     </para>
398     <programlisting>
399     LC_ALL=fr_FR thuban.py
400     </programlisting>
401    
402     <para>
403     MS Windows Benutzer müssen die Sprache über die Kontroll-Leiste einstellen
404     welche grundsätzlich alle Anwendungen beeinflusst.
405     </para>
406     </section>
407    
408     <section><title>Das Hauptfenster</title>
409     <para>
410     <figure><title>Das Hauptfenster</title>
411     <mediaobject>
412     <imageobject> <imagedata fileref="../images/1_2_mainwindow.png" format="PNG" scale="&imgscale;"/> </imageobject>
413     <imageobject> <imagedata fileref="./images/1_2_mainwindow.ps" format="EPS" scale="&imgscale;"/> </imageobject>
414     </mediaobject>
415     </figure>
416     </para>
417    
418     <para>
419     Das Hauptfenster stellt die aktuelle Karte dar. Hier kann der
420     Benutzer mit der Karte interagieren indem er die verschiednen
421     Werkzeuge anwendet.
422     </para>
423    
424     <para>
425     Die Legende auf der linken Seite zeigt eine Liste der aktuellen
426     Ebenen und alle dargestellten Klassifikations-Gruppen.
427     Bei diesem Beispiel haben alle Geo-Objekte Ebenen eine voreingestellte
428     Klassifizierung wie die jeweiligen Geo-Objekte in den einzelnen
429     Ebenen gezeichnet werden sollen.
430     Die Ebenen die weiter oben in der Liste dargestellt werden über
431     die darunter aufgelisteten gezeichnet.
432     Die Legende kann durch Anwahl des X in der oberen rechten Ecke
433     geschlossen werden.
434     Um die Legenden-Ansicht wieder zu öffnen, wählen Sie
435 jan 2313 <menuchoice>
436     <guimenu>Karte</guimenu>
437     <guimenuitem>Legende</guimenuitem>
438     </menuchoice>.
439     Das Legenden-Fenster ist lösbar. Das bedeutet, dass sie vom Hauptfenster
440     abgelöst und dann als eigenständiges Fenster
441     positioniert werden kann. Dies wird durch den kleinen Schalter
442     neben dem X gemacht. Erneutes Anwählen des Schalters läßt das
443     Legenden-Fenster wieder in das Hauptfenster integrieren.
444     </para>
445     <para>
446     Die Status-Leiste zeigt verschiedene Informationen jeweils
447     abhängig vom Kontext. Wählt der Benutzer einen Menüpunkt
448     dann wird in der Status-Leiste ein Hilfetext zu dem jeweiligen
449     Menüpunkt angezeigt.
450     Ist eines der Werkzeuge aktiviert, so wird in der Status-Leiste
451     die Position angegeben über der der Maus-Cursor auf der Karte
452     steht.
453     </para>
454     <para>
455     Die Werkzeugleiste erlaubt direkten Zugriff auf häufig
456     benötigte Werkzeuge.
457     Schwebt der Maus-Zeiger über einem Knopf wird eine Kurz-Info
458     über das jeweilige Werkzeug gegeben.
459     Folgende Werzeuge stehen zur Verfügung: Hineinzoomen,
460     Herauszoomen, Verschieben, Zur vollen Kartenausdehnung zoomen,
461     Zur vollen Ebenenausdehnung zoomen, Zur vollen Auswahlausdehnung zoomen,
462     Identifizieren, Labels hinzufügen/entfernen.
463     Alle Werkzeuge werden in diesem Handbuch noch detaillierter beschrieben.
464     </para>
465     </section>
466 jan 2309
467     </chapter>
468    
469     <chapter><title>Session Management</title>
470    
471 jan 2313 <section><title>Eine neue Session beginnen</title>
472     <para>
473     Eine neue Session wird gestartet über
474     <menuchoice>
475     <guimenu>Datei</guimenu>
476     <guimenuitem>Neue Session</guimenuitem>
477     </menuchoice>.
478     Falls bereits eine Session geladen ist und seit der letzten
479     Speicherung verändert wurde, so wird nun nachgefragt, ob
480     diese Session zunächst gespeichert werden soll.
481     Eine neue Session besteht aus einer leeren Karte
482     ohne Ebenen, Tabellen und Projektion.
483     </para>
484     </section>
485 jan 2309
486 jan 2313 <section><title>Eine Session öffnen</title>
487     <para>
488     Eine Session kann geöffnet werden über
489     <menuchoice>
490     <guimenu>Datei</guimenu>
491     <guimenuitem>Öffne Session</guimenuitem>
492     </menuchoice>.
493     Es wird ein Dateiauswahl-Dialog geöffnet um eine
494     Thuban Session Datei auszuwählen. Diese Dateien enden
495     auf <varname>.thuban</varname>. Wird eine Datei ausgewählt und mit
496     <guibutton>OK</guibutton> bestätigt, so wird die entsprechende
497     Session in Thuban geladen.
498 jan 2309
499 jan 2313 Ist bereits eine Session geladen und seit dem letzten Speichern modifiziert
500     worden, so wird nachgefragt, ob zunächst die alte Session gespeichert werden
501     soll.
502     </para>
503     </section>
504 jan 2309
505 jan 2313 <section><title>Eine Session speichern</title>
506     <para>
507     Eine Session kann gepsiechert werden über
508     <menuchoice>
509     <guimenu>Datei</guimenu>
510     <guimenuitem>Session Speichern</guimenuitem>
511     </menuchoice>.
512     Handelt es sich bei der aktuellen Session nicht um eine
513     neue und ungespeicherte, so wird die entsprechende Datei
514     mit den Daten der aktuellen Session überschrieben.
515     Im Falle einer neuen und noch nicht gespeicherten Session
516     wird ein Dateiauswahl-Dialog geöffnet um einen Namen
517     für die zu speicherende Session auszuwählen.
518     Thuban Session Dateien sollten mit der Endung
519     <varname>.thuban</varname> versehen werden.
520     Existiert bereits eine Datei mit dem gleichen Namen
521     wird der Benutzer gefragt ob diese überschrieben
522     oder ein neuer Name gewählt werden soll.
523     </para>
524     </section>
525 jan 2309
526 jan 2313 <section><title>Der Session Info-Baum</title>
527     <para>
528     <figure>
529     <title>Session Info-Baum</title>
530     <mediaobject>
531     <imageobject><imagedata fileref="../images/2_4_session_tree.png" format="PNG" scale="&imgscale;"/></imageobject>
532     <imageobject><imagedata fileref="./images/2_4_session_tree.eps" format="EPS" scale="&imgscale;"/></imageobject>
533     </mediaobject>
534     </figure>
535     </para>
536     <para>
537     Der Session Info-Baum ist hauptsächlich für Software-Entwickler gedacht
538     die an Thuban arbeiten.
539     Er stellt eine Reihe von internen Daten zur Session, der Karte, den
540     Ebenen usw. dar. Er wird geöffnet über
541     <menuchoice>
542     <guimenu>Datei</guimenu>
543     <guimenuitem>Session Baum</guimenuitem>
544     </menuchoice>.
545     </para>
546     </section>
547 jan 2309 </chapter>
548    
549     <chapter><title>Map Management</title>
550     <para>
551     The map consists of a number of layers where each layer represents a
552     different type of data set. By interacting with the map the user can
553     visually explore the data.
554     </para>
555     <para>
556     The map can have a name that will appear in the Thuban title bar.
557     The map name can be changed using
558     <menuchoice>
559     <guimenu>Map</guimenu>
560     <guimenuitem>Rename</guimenuitem>
561     </menuchoice>.
562     </para>
563     <para>
564     <inlinemediaobject>
565     <imageobject>
566     <imagedata fileref="../images/3_rename_map.png" format="PNG" scale="&imgscale;"/>
567     </imageobject>
568     <imageobject>
569     <imagedata fileref="./images/3_rename_map.eps" format="EPS" scale="&imgscale;"/>
570     </imageobject>
571     <textobject> <phrase>Rename Map</phrase> </textobject>
572     </inlinemediaobject>
573     </para>
574    
575     <section><title>Adding and Removing Layers</title>
576     <para>
577     There are three types of layers that can be added to a map:
578     Shape layers, database layers
579     and image layers. Shape layers are stored in Shapefile format, a
580     widely used file format for storing geographic objects. These
581     files have the extension ``.shp''. Associated with
582     the shape file is a database file which stores attributes for
583     each shape in the Shape file. This file, in dBase format,
584     has the extension ``.dbf''. Both files must have the same base name.
585     For example, if there is a shape file named roads.shp there must
586     also be a file roads.dbf.
587     </para>
588     <itemizedlist>
589     <listitem>
590     <para>
591     Shape layers can be added to the map with
592     <menuchoice>
593     <guimenu>Map</guimenu>
594     <guimenuitem>Add Layer</guimenuitem>
595     </menuchoice>.
596     Initially, only the ``.shp'' files are shown which is enough for the
597     selection. However, if you switch to display all files and select one
598     of the associated files (e.g. ``.dbf''), Thuban will recognize the base
599     name and load the corresponding Shape file.
600     </para>
601     <para>
602     The file dialog for Shape files allows to select multiple files.
603     Use the shift-button together with the left mouse button to extend
604     the selection.
605     </para>
606     </listitem>
607    
608     <listitem>
609     <para>Database layers can be added to the map with
610     <menuchoice>
611     <guimenu>Map</guimenu>
612     <guimenuitem>Add Database Layer</guimenuitem>
613     </menuchoice>.
614     A dialog with two is list is opened. The left list displays all
615     database connections currently open for the session. You can retrieve
616     a list of available layers from the selected database which is
617     displayed on the right hand. From this list one layer can be selected,
618     the dialog is closed afterwards.
619     </para>
620     <para>
621     See appendix ``Working with PostGIS'' for details.
622     </para>
623     </listitem>
624    
625     <listitem>
626     <para>
627     Image layers can be added to the map with
628     <menuchoice>
629     <guimenu>Map</guimenu>
630     <guimenuitem>Add Image Layer</guimenuitem>
631     </menuchoice>.
632     It is important to select a valid image file that has geographic
633     data associated with it. The data can be embedded in the file itself,
634     or in another file. If geographic information cannot be found, Thuban
635     will report an error.
636     </para>
637     </listitem>
638     </itemizedlist>
639     </section>
640    
641     <section><title>Navigation</title>
642     <para>
643     The map can be explored by using the navigation tools available on
644     the tool bar or from the
645     <menuchoice><guimenu>Map</guimenu></menuchoice> menu.
646     </para>
647     <itemizedlist>
648     <listitem>
649     <para>
650     The ZoomIn tool
651     <inlinemediaobject>
652     <imageobject>
653     <imagedata fileref="../images/3_2_zoomin.png" format="PNG" scale="&imgscale;"/>
654     </imageobject>
655     <imageobject>
656     <imagedata fileref="./images/3_2_zoomin.eps" format="EPS" scale="&imgscale;"/>
657     </imageobject>
658     <textobject> <phrase>ZoomIn Tool</phrase> </textobject>
659     </inlinemediaobject>
660     enlarges a region of the map. Clicking once on the map
661     will double the magnification and center the map on the point that
662     was clicked. Clicking and dragging selects a region that will be
663     enlarged to fit the window.
664     </para>
665     </listitem>
666     <listitem>
667     <para>
668     The ZoomOut tool
669     <inlinemediaobject>
670     <imageobject>
671     <imagedata fileref="../images/3_2_zoomout.png" format="PNG" scale="&imgscale;"/>
672     </imageobject>
673     <imageobject>
674     <imagedata fileref="./images/3_2_zoomout.eps" format="EPS" scale="&imgscale;"/>
675     </imageobject>
676     <textobject> <phrase>ZoomOut Tool</phrase> </textobject>
677     </inlinemediaobject>
678     shrinks the map so that a larger region is visible. A single click
679     reduces the magnification by a factor of two. Clicking and dragging
680     selects a box such that the current contents of the window will be
681     scaled to fit into that box.
682     </para>
683     </listitem>
684     <listitem>
685     <para>
686     The Pan tool
687     <inlinemediaobject>
688     <imageobject>
689     <imagedata fileref="../images/3_2_pan.png" format="PNG" scale="&imgscale;"/>
690     </imageobject>
691     <imageobject>
692     <imagedata fileref="./images/3_2_pan.eps" format="EPS" scale="&imgscale;"/>
693     </imageobject>
694     <textobject> <phrase>Pan Tool</phrase> </textobject>
695     </inlinemediaobject>
696     allows the user to move the map around by clicking and dragging.
697     </para>
698     </listitem>
699     <listitem>
700     <para>
701     The Full Extent tool
702     <inlinemediaobject>
703     <imageobject>
704     <imagedata fileref="../images/3_2_fullextent.png" format="PNG" scale="&imgscale;"/>
705     </imageobject>
706     <imageobject>
707     <imagedata fileref="./images/3_2_fullextent.eps" format="EPS" scale="&imgscale;"/>
708     </imageobject>
709     <textobject> <phrase>Full Extent Tool</phrase> </textobject>
710     </inlinemediaobject>
711     rescales the viewable region so that the entire map is visible.
712     </para>
713     </listitem>
714     <listitem>
715     <para>
716     The Full Layer Extent tool
717     <inlinemediaobject>
718     <imageobject>
719     <imagedata fileref="../images/3_2_fulllayerextent.png" format="PNG" scale="&imgscale;"/>
720     </imageobject>
721     <imageobject>
722     <imagedata fileref="./images/3_2_fulllayerextent.eps" format="EPS" scale="&imgscale;"/>
723     </imageobject>
724     <textobject> <phrase>Full Layer Extent Tool</phrase> </textobject>
725     </inlinemediaobject>
726     rescales the viewable region so that the currently selected
727     layer fits within the window. If no layer is selected this button
728     will be disabled.
729     </para>
730     </listitem>
731     <listitem>
732     <para>
733     The Full Shape Extent tool
734     <inlinemediaobject>
735     <imageobject>
736     <imagedata fileref="../images/3_2_fullshapeextent.png" format="PNG" scale="&imgscale;"/>
737     </imageobject>
738     <imageobject>
739     <imagedata fileref="./images/3_2_fullshapeextent.eps" format="EPS" scale="&imgscale;"/>
740     </imageobject>
741     <textobject> <phrase>Full Shape Extent Tool</phrase> </textobject>
742     </inlinemediaobject>
743     rescales the viewable region so that the currently selected
744     shape fits within the window. If the shape is a point, it is
745     centered and the map is zoomed all the way in. If no shape is
746     selected this button will be disabled. This feature is especially
747     helpful when identifying an object related to a selected record
748     in a tableview (see below).
749    
750     </para>
751     </listitem>
752     </itemizedlist>
753     </section>
754    
755     <section><title>Object Identification</title>
756     <para>
757     Objects on the map can be identified using the Identify tool
758     <inlinemediaobject>
759     <imageobject>
760     <imagedata fileref="../images/3_3_identify.png" format="PNG" scale="&imgscale;"/>
761     </imageobject>
762     <imageobject>
763     <imagedata fileref="./images/3_3_identify.eps" format="EPS" scale="&imgscale;"/>
764     </imageobject>
765     <textobject> <phrase>Identify Tool</phrase> </textobject>
766     </inlinemediaobject>.
767     Clicking on an object selects that object and opens a dialog which
768     shows all the table attributes for that object. Any current selection
769     is lost. Objects on the map are typically shapes and this document
770     will often refer to objects as shapes.
771     </para>
772     </section>
773    
774     <section><title>Object Labeling</title>
775     <para>
776     Objects can be labeled using the Label tool
777     <inlinemediaobject>
778     <imageobject>
779     <imagedata fileref="../images/3_3_label.png" format="PNG" scale="&imgscale;"/>
780     </imageobject>
781     <imageobject>
782     <imagedata fileref="./images/3_3_label.eps" format="EPS" scale="&imgscale;"/>
783     </imageobject>
784     <textobject> <phrase>Label Tool</phrase> </textobject>
785     </inlinemediaobject>.
786     Clicking on an object selects that object and opens a dialog which
787     displays the table attributes for that object. An attribute can
788     be selected to be the label on the map. The label will be placed
789     at the center of the shape. Clicking on an object that already has
790     a label will remove the label.
791     </para>
792     </section>
793    
794     <section><title>The Legend</title>
795     <para>
796     <inlinemediaobject>
797     <imageobject>
798     <imagedata fileref="../images/3_5_legend.png" format="PNG" scale="&imgscale;"/>
799     </imageobject>
800     <imageobject>
801     <imagedata fileref="./images/3_5_legend.eps" format="EPS" scale="&imgscale;"/>
802     </imageobject>
803     <textobject> <phrase>Legend</phrase> </textobject>
804     </inlinemediaobject>
805     </para>
806     <para>
807     The Legend provides an overview of the layers in the map. Layers
808     that appear higher in the legend will appear ``closer'' to the user.
809     If a layer supports classification (currently, only shape layers
810     have this feature) then the classification groups will be shown
811     below each layer. The properties for each group are also displayed
812     with a small graphic. Polygon layers appear as rectangles, lines
813     appear as curved lines, and points appear as circles.
814     </para>
815     <para>
816     Along the top of the legend is a toolbar which allows quick access
817     to some of the layer manipulation options under
818     <menuchoice><guimenu>Map</guimenu></menuchoice>.
819     </para>
820    
821     <itemizedlist>
822     <listitem>
823     <para>
824     The Move Layer to Top tool
825     <inlinemediaobject>
826     <imageobject>
827     <imagedata fileref="../images/3_5_totop.png" format="PNG" scale="&imgscale;"/>
828     </imageobject>
829     <imageobject>
830     <imagedata fileref="./images/3_5_totop.eps" format="EPS" scale="&imgscale;"/>
831     </imageobject>
832     <textobject> <phrase>Move Layer to Top</phrase> </textobject>
833     </inlinemediaobject> raises the selected layer to the top of the map.
834     </para>
835     </listitem>
836     <listitem>
837    
838     <para>
839     The Move Layer Up tool
840     <inlinemediaobject>
841     <imageobject>
842     <imagedata fileref="../images/3_5_moveup.png" format="PNG" scale="&imgscale;"/>
843     </imageobject>
844     <imageobject>
845     <imagedata fileref="./images/3_5_moveup.eps" format="EPS" scale="&imgscale;"/>
846     </imageobject>
847     <textobject> <phrase>Move Layer Up</phrase> </textobject>
848     </inlinemediaobject> raises the selected layer one level.
849     </para>
850     </listitem>
851     <listitem>
852    
853     <para>
854     The Move Layer Down tool
855     <inlinemediaobject>
856     <imageobject>
857     <imagedata fileref="../images/3_5_movedown.png" format="PNG" scale="&imgscale;"/>
858     </imageobject>
859     <imageobject>
860     <imagedata fileref="./images/3_5_movedown.eps" format="EPS" scale="&imgscale;"/>
861     </imageobject>
862     <textobject> <phrase>Move Layer Down</phrase> </textobject>
863     </inlinemediaobject> lowers the selected layer one level.
864     </para>
865    
866     </listitem>
867     <listitem>
868     <para>
869     The Move Layer to Bottom tool
870     <inlinemediaobject>
871     <imageobject>
872     <imagedata fileref="../images/3_5_tobottom.png" format="PNG" scale="&imgscale;"/>
873     </imageobject>
874     <imageobject>
875     <imagedata fileref="./images/3_5_tobottom.eps" format="EPS" scale="&imgscale;"/>
876     </imageobject>
877     <textobject> <phrase>Move Layer to Bottom</phrase> </textobject>
878     </inlinemediaobject> lowers the selected layer to the bottom of the map.
879     </para>
880    
881     </listitem>
882     <listitem>
883     <para>
884     The Visible tool
885     <inlinemediaobject>
886     <imageobject>
887     <imagedata fileref="../images/3_5_visible.png" format="PNG" scale="&imgscale;"/>
888     </imageobject>
889     <imageobject>
890     <imagedata fileref="./images/3_5_visible.eps" format="EPS" scale="&imgscale;"/>
891     </imageobject>
892     <textobject> <phrase>Visible</phrase> </textobject>
893     </inlinemediaobject> shows the selected layer in the map if it was
894     hidden.
895     </para>
896    
897     </listitem>
898     <listitem>
899     <para>
900     The Invisible tool
901     <inlinemediaobject>
902     <imageobject>
903     <imagedata fileref="../images/3_5_invisible.png" format="PNG" scale="&imgscale;"/>
904     </imageobject>
905     <imageobject>
906     <imagedata fileref="./images/3_5_invisible.eps" format="EPS" scale="&imgscale;"/>
907     </imageobject>
908     <textobject> <phrase>Invisible</phrase> </textobject>
909     </inlinemediaobject> hides the selected layer in the map.
910     </para>
911    
912     </listitem>
913     <listitem>
914     <para>
915     The Properties tool
916     <inlinemediaobject>
917     <imageobject>
918     <imagedata fileref="../images/3_5_props.png" format="PNG" scale="&imgscale;"/>
919     </imageobject>
920     <imageobject>
921     <imagedata fileref="./images/3_5_props.eps" format="EPS" scale="&imgscale;"/>
922     </imageobject>
923     <textobject> <phrase>Properties</phrase> </textobject>
924     </inlinemediaobject> opens the layer's properties dialog box.
925     Double-clicking on a layer or a group of a layer will open the
926     properties dialog for that layer.
927     </para>
928     </listitem>
929     </itemizedlist>
930    
931     <para>
932     The most used layer related actions are also available from a
933     popup menu. It is raised when a layer is clicked with the right mouse
934     button.
935     </para>
936    
937     <para>
938     <figure>
939     <title>Layer Popup Menu</title>
940     <mediaobject>
941     <imageobject><imagedata fileref="../images/3_5_popup_menu.png" format="PNG" scale="&imgscale;"/></imageobject>
942     <imageobject><imagedata fileref="./images/3_5_popup_menu.eps" format="EPS" scale="&imgscale;"/></imageobject>
943     </mediaobject>
944     </figure>
945     </para>
946    
947     <para>
948     Along the bottom of the legend is the scalebar. The scalebar
949     will be available if there are any layers and the map has a
950     projection set.
951     </para>
952     </section>
953    
954     <section><title>Exporting</title>
955     <para>
956     Under Windows, maps can be exported in Enhanced Metafile format
957     (<varname>.wmf</varname>)
958     from
959     <menuchoice>
960     <guimenu>Map</guimenu>
961     <guimenuitem>Export</guimenuitem>
962     </menuchoice> for use in reports, presentations, or further
963     modification. The current map view, legend, and, if available,
964     scalebar are exported. Under other platforms this option is not
965     available. Clicking this menu item open a file selection dialog
966     that lets the user select a location to export the map.
967     </para>
968     </section>
969    
970     <section><title>Printing</title>
971     <para>
972     The map can be printed using
973     <menuchoice>
974     <guimenu>Map</guimenu>
975     <guimenuitem>Print</guimenuitem>
976     </menuchoice>. The current map view, legend, and, if available,
977     scalebar are printed. A standard printing dialog will open allowing
978     the user to configure the printer. This dialog will differ depending
979     on which platform Thuban is running.
980     </para>
981     </section>
982    
983     </chapter>
984    
985     <chapter><title>Layer Management</title>
986     <para>
987     </para>
988    
989     <section><title>Types of Layers</title>
990     <para>
991     There are three types of layers supported by Thuban: shape layers,
992     database layers and
993     image layers. Shape layers consist of vector based shapes with
994     geo-referenced coordinates. There are three types of supported
995     shapes: polygons, lines (arc), and points. Database layers are similar
996     to shape layers but loaded from a database instead of the file system.
997     Image layers can be any image
998     file format supported by the Geo-spatial Data Abstraction Library
999     (GDAL). The images must have geographic
1000     coordinate data either embedded within the file or in a separate
1001     file that is in the same directory as the image file. GeoTIFF files
1002     work very well with Thuban and were designed specifically to be image
1003     layers in GIS programs.
1004     </para>
1005     <para>
1006     All actions in the
1007     <menuchoice>
1008     <guimenu>Layer</guimenu>
1009     </menuchoice> menu act on the currently selected layer in the legend.
1010     </para>
1011     </section>
1012    
1013     <section><title>Properties</title>
1014     <para>
1015     To view the properties for a layer it must first be selected in the
1016     legend. The menu option
1017     <menuchoice>
1018     <guimenu>Layer</guimenu>
1019     <guimenuitem>Properties</guimenuitem>
1020     </menuchoice> opens a dialog that displays a layer's properties.
1021     All layers have a title which can be modified in the text field
1022     provided. The type of layer is also shows. If the type is a type
1023     of shape (polygon, arc, point) the classification table will be
1024     shown. Image layers have no other properties other than title
1025     and type.
1026     </para>
1027     <para>
1028     <figure>
1029     <title>Properties Window</title>
1030     <mediaobject>
1031     <imageobject><imagedata fileref="../images/4_2_layer_properties.png" format="PNG" scale="&imgscale;"/></imageobject>
1032     <imageobject><imagedata fileref="./images/4_2_layer_properties.eps" format="EPS" scale="&imgscale;"/></imageobject>
1033     </mediaobject>
1034     </figure>
1035     </para>
1036     <para>
1037     <figure>
1038     <title>Properties Window</title>
1039     <mediaobject>
1040     <imageobject><imagedata fileref="../images/4_2_raster_layer_properties.png" format="PNG" scale="&imgscale;"/></imageobject>
1041     <imageobject><imagedata fileref="./images/4_2_raster_layer_properties.eps" format="EPS" scale="&imgscale;"/></imageobject>
1042     </mediaobject>
1043     </figure>
1044     </para>
1045     </section>
1046    
1047     <section><title>Visibility</title>
1048     <para>
1049     Sometimes it is not desirable to view all layers at the same time.
1050     Some layers may take a long time to draw and so while navigating
1051     around the map the user may not want to wait for the map to redraw
1052     all the layers each time the map is changed. Each layer can be
1053     independently turned on or off using the
1054     <menuchoice>
1055     <guimenu>Layer</guimenu>
1056     <guimenuitem>Show</guimenuitem>
1057     </menuchoice>
1058     or
1059     <menuchoice>
1060     <guimenu>Layer</guimenu>
1061     <guimenuitem>Hide</guimenuitem>
1062     </menuchoice> options respectively.
1063     </para>
1064     </section>
1065    
1066     <section><title>Duplication</title>
1067     <para>
1068     Layers and all their properties, including classifications, can
1069     be duplicated using
1070     <menuchoice>
1071     <guimenu>Layer</guimenu>
1072     <guimenuitem>Duplicate</guimenuitem>
1073     </menuchoice>. Duplicating a layer is useful if the user wishes
1074     to model a layer in several different ways. Even though the layers
1075     overlap, by carefully selecting the shape properties it is possible
1076     to display several pieces of information at once. For example, one
1077     copy of a roads layer may be classified on a length property and
1078     another copy may be classified on a type property. If the length
1079     property was expressed with color and the type property expressed
1080     with line thickness then it would be possible to view both
1081     classifications by placing the type property copy over the
1082     length property copy.
1083     </para>
1084     </section>
1085    
1086     </chapter>
1087    
1088     <chapter><title>Layer Classifications</title>
1089     <para>
1090     A layer classification is a way of assigning drawing properties to
1091     groups of shapes based on attributes stored in the layer's table.
1092     Only layer's with shapes can have a classification; image layers
1093     cannot be classified.
1094     </para>
1095     <para>
1096     A classification consists of a number of groups, each group
1097     having a value or range of values to match against, and symbol
1098     properties which control how a shape is drawn on the map. The user
1099     selects which field in the table is used by the classification and
1100     when the map is drawn the value for that field for each shape is
1101     compared with each group's value. The properties of the first group
1102     to match are used to draw the shape. This allows the user to get a
1103     visual impression of not only how the data is laid out but also what
1104     kind of data lies where.
1105     </para>
1106     <para>
1107     A layer always has a classification. When a new layer is added to the
1108     map, a default classification is created with the DEFAULT group. This
1109     group cannot be removed but can be hidden (see below). Every shape in the
1110     layer, regardless of its attributes, will match this group if no other
1111     group matches.
1112     </para>
1113    
1114     <section><title>Editing Classifications</title>
1115     <para>
1116     A layer's classification can be modified under the properties dialog
1117     (<menuchoice>
1118     <guimenu>Layer</guimenu>
1119     <guimenuitem>Properties</guimenuitem>
1120     </menuchoice>). The layer's classification field can be set to None,
1121     which simply assigns a DEFAULT group to the classification. No new
1122     groups can be added to the classification if the field is None.
1123     The user must first select a field to classify on. New groups can
1124     be added to the classification with the <guibutton>Add</guibutton>
1125     button.
1126     </para>
1127     <para>
1128     To apply the changes to the map the user can click
1129     either <guibutton>Try</guibutton> or <guibutton>OK</guibutton>.
1130     <guibutton>Try</guibutton> will not close the dialog box, allowing
1131     the user to see how the classification changes the map.
1132     <guibutton>Revert</guibutton> will undo the last classification applied
1133     to the map. <guibutton>OK</guibutton> will commit the changes and
1134     close the dialog. The user will be unable to undo the changes.
1135     <guibutton>Close</guibutton> simply closes the dialog box. If any
1136     changes have not been applied with <guibutton>Try</guibutton> the
1137     changes will not be applied to the map.
1138     </para>
1139     <para>
1140     <figure>
1141     <title>Properties Window</title>
1142     <mediaobject>
1143     <imageobject><imagedata fileref="../images/5_classification.png" format="PNG" scale="&imgscale;"/></imageobject>
1144     <imageobject><imagedata fileref="./images/5_classification.eps" format="EPS" scale="&imgscale;"/></imageobject>
1145     </mediaobject>
1146     </figure>
1147     </para>
1148     <para>
1149     The order of the groups in the classification is significant
1150     except for the DEFAULT group, which remains at the top. When shapes
1151     are matched against groups the matching begins at the first group
1152     after the DEFAULT group so that groups higher in the list will
1153     be checked first. Matching for a
1154     given shape will stop at the first group that matches. The user can
1155     use <guibutton>Move Up</guibutton> and <guibutton>Move Down</guibutton>
1156     to change the order of the groups. The DEFAULT group will always
1157     match a shape that hasn't matched another group.
1158     </para>
1159     <section><title>Visible</title>
1160     <para>
1161     The Visible column has check-boxes that determine whether a
1162     classification group will be displayed in the legend. This is
1163     useful if the user knows that the groups completely cover
1164     the data set and don't want the DEFAULT group to be displayed
1165     in the legend and on a printout.
1166     </para>
1167     </section>
1168     <section><title>Symbols</title>
1169     <para>
1170     Each type of shape has its own type of symbol. Thuban supports three
1171     types of shapes: polygons, lines, and points. Polygons and points
1172     have outline and fill color, while lines have only line color. Each
1173     group has associated symbol properties. To edit the symbol
1174     properties for a group the user can double click on the Symbol
1175     column or select a group and click the
1176     <guibutton>Edit Symbol</guibutton> button.
1177     </para>
1178     </section>
1179     <section><title>Value</title>
1180     <para>
1181     The Value column of the classification table is the value that will
1182     be matched when the map is being drawn. The type of data that can
1183     entered into this field depends on the type of data of the
1184     classification field.
1185     </para>
1186     <para>
1187     If the field is of type Text, anything entered
1188     into the field is valid. The text will be compared literally to the
1189     value of the shape attribute, including case sensitivity.
1190     If the type is Integer, then any valid integer may be entered. In
1191     addition, with special syntax, a range of values can be entered.
1192     A range from <varname>start</varname> to <varname>end</varname>
1193     inclusive is specified like this: <literal>[start;end]</literal>.
1194     The exclusive range is specified like this:
1195     <literal>]start;end[</literal>. Ranges can include infinity like
1196     this: <literal>[-oo;oo]</literal>. Field types can also be of type
1197     Decimal. They represent any rational number and can be used in
1198     ranges as well.
1199     </para>
1200     </section>
1201     <section><title>Label</title>
1202     <para>
1203     By default, the text that is displayed for a group in the legend
1204     is the value for that group. The label can substitute a more
1205     descriptive term in the legend.
1206     </para>
1207     </section>
1208     </section>
1209    
1210     <section><title>Generating Classes</title>
1211     <para>
1212     <figure>
1213     <title>Generate Class</title>
1214     <mediaobject>
1215     <imageobject><imagedata fileref="../images/5_3_genclass.png" format="PNG" scale="&imgscale;"/></imageobject>
1216     <imageobject><imagedata fileref="./images/5_3_genclass.eps" format="EPS" scale="&imgscale;"/></imageobject>
1217     </mediaobject>
1218     </figure>
1219     </para>
1220     <para>
1221     Creating a classification by hand can be tedious.
1222     Thuban, therefore, provides a means of generating an entire
1223     classification at once while still giving the user control over
1224     how it appears. Clicking <guibutton>Generate Class</guibutton>
1225     opens the <varname>Generate Classification</varname> dialog.
1226     Under the <varname>Generate</varname> pull down there are at most
1227     three different ways to generate classifications:
1228     Unique Values, Uniform Distribution, and Quantiles. Some options
1229     may not be available if the data type for the field does not
1230     support them. For instance, <varname>Uniform Distribution</varname>
1231     doesn't make sense for a Text field.
1232     </para>
1233     <para>
1234     For every way of generating a classification, a color scheme must
1235     be selected. Thuban provides several different color schemes that
1236     affect how the group properties change over the classification.
1237     It may be desirable that only certain properties change over the
1238     classification. If the shape type is a polygon or a point then
1239     the <guibutton>Fix Border Color</guibutton> option will be available.
1240     This allows the user to select a border color for all classification
1241     groups.
1242     It is also possible to create a custom color scheme. Selecting
1243     this option will display two symbols: the one of the left has the
1244     properties of the first group and the one on the right has the
1245     properties of the last group. Thuban will interpolate between these
1246     two properties to generate the other groups.
1247     <figure>
1248     <title>Custom Color Scheme</title>
1249     <mediaobject>
1250     <imageobject><imagedata fileref="../images/5_2_custom_ramp.png" format="PNG" scale="&imgscale;"/></imageobject>
1251     <imageobject><imagedata fileref="./images/5_2_custom_ramp.eps" format="EPS" scale="&imgscale;"/></imageobject>
1252     </mediaobject>
1253     </figure>
1254     </para>
1255     <para>
1256     The Unique Values option lets the user select specific values that
1257     appear in the table. Clicking <guibutton>Retrieve From Table</guibutton>
1258     searches the table for all unique values and displays them in the
1259     list on the left. Items can be selected and moved to the list on the
1260     right. Each list can be sorted or reversed for easier searching.
1261     The classification that is generated will be in the same order as
1262     the list on the right.
1263     <figure>
1264     <title>Unique Values</title>
1265     <mediaobject>
1266     <imageobject><imagedata fileref="../images/5_2_unique_values.png" format="PNG" scale="&imgscale;"/></imageobject>
1267     <imageobject><imagedata fileref="./images/5_2_unique_values.eps" format="EPS" scale="&imgscale;"/></imageobject>
1268     </mediaobject>
1269     </figure>
1270     </para>
1271     <para>
1272     The Uniform Distribution option creates a user specified number of
1273     groups of ranges such that each range covers equal intervals. The
1274     minimum and maximum values can automatically be retrieved from the
1275     table by clicking <guibutton>Retrieve From Table</guibutton>. The
1276     stepping is how large each interval is. Adjusting this value will
1277     automatically recalculate how many groups is appropriate.
1278     <figure>
1279     <title>Uniform Distribution</title>
1280     <mediaobject>
1281     <imageobject><imagedata fileref="../images/5_2_uniform_dist.png" format="PNG" scale="&imgscale;"/></imageobject>
1282     <imageobject><imagedata fileref="./images/5_2_uniform_dist.eps" format="EPS" scale="&imgscale;"/></imageobject>
1283     </mediaobject>
1284     </figure>
1285     </para>
1286     <para>
1287     The Quantiles option generates ranges based on the number of items
1288     in the table. For example, by specifying five groups Thuban will
1289     generate five groups with appropriate ranges such that 20% of the table
1290     data is in each group. If it is impossible to generate exact
1291     groupings, Thuban will issue a warning but allow the user to continue.
1292     <figure>
1293     <title>Quantiles</title>
1294     <mediaobject>
1295     <imageobject><imagedata fileref="../images/5_2_quantiles.png" format="PNG" scale="&imgscale;"/></imageobject>
1296     <imageobject><imagedata fileref="./images/5_2_quantiles.eps" format="EPS" scale="&imgscale;"/></imageobject>
1297     </mediaobject>
1298     </figure>
1299     </para>
1300     </section>
1301     </chapter>
1302    
1303     <chapter><title>Projection Management</title>
1304     <para>
1305     Projections control how the geographic data is displayed on the screen.
1306     If multiple layers are loaded into Thuban where the geographic data
1307     is in a different projection system, then the user must specify a
1308     projection for each layer. The user must also tell Thuban which
1309     projection the map is in. This can be the same as the layers or a different
1310     projection in which case the layers are reprojected into that space.
1311     The map projection can be set using
1312     <menuchoice>
1313     <guimenu>Map</guimenu>
1314     <guimenuitem>Projection</guimenuitem>
1315     </menuchoice> and the layer projection can be set using
1316     <menuchoice>
1317     <guimenu>Layer</guimenu>
1318     <guimenuitem>Projection</guimenuitem>
1319     </menuchoice>.
1320     <figure>
1321     <title>Projection Window</title>
1322     <mediaobject>
1323     <imageobject><imagedata fileref="../images/6_projection.png" format="PNG" scale="&imgscale;"/></imageobject>
1324     <imageobject><imagedata fileref="./images/6_projection.eps" format="EPS" scale="&imgscale;"/></imageobject>
1325     </mediaobject>
1326     </figure>
1327     </para>
1328     <para>
1329     Thuban is distributed with a sample collection of projections and the
1330     set of coordinate systems as used by the EPSG
1331     (European Petroleum Survey Group). This quite large set is only displayed
1332     if activated by the according checkbox. The set falls into two parts:
1333     deprecated lists all projections which are no longer part of the
1334     EPSG data base.
1335     </para>
1336     <para>
1337     The
1338     user can create new projections and make them available to all
1339     future Thuban sessions. They may also be exported and imported so
1340     that custom projections can be distributed.
1341     </para>
1342     <section><title>Selecting a Projection</title>
1343     <para>
1344     The available projections are listed on the left. If the layer
1345     or map already has a projection it will initially be highlighted
1346     and will end with <varname>(current)</varname>. Selecting
1347     <varname>&lt;None&gt;</varname> will cause Thuban to use the data as
1348     it appears in the source file and will not use a projection.
1349     </para>
1350     </section>
1351     <section><title>Editing a Projection</title>
1352     <para>
1353     Whenever a projection is selected from the list its properties
1354     are displayed on the right. These properties can be changed
1355     and the changes saved to the selected projection using
1356     <guibutton>Update</guibutton>. Only a projection that comes
1357     from a file can be updated, so if the current layer's projection
1358     is selected, <guibutton>Update</guibutton> will be disabled.
1359     <guibutton>Add to List</guibutton> adds the projection to the
1360     list of available projections as a new entry, and thus makes it
1361     available to future Thuban sessions. Clicking <guibutton>New</guibutton>
1362     will create an entirely new, empty projection. The
1363     <guibutton>Remove</guibutton> button will permanently remove a
1364     projection from the list of available projections.
1365     </para>
1366     <para>
1367     To apply the selected projection to the map the user can click
1368     either <guibutton>Try</guibutton> or <guibutton>OK</guibutton>.
1369     <guibutton>Try</guibutton> will not close the dialog box, allowing
1370     the user to see how the projeciton changes the map.
1371     <guibutton>Revert</guibutton> will undo the last projection applied
1372     to the map. <guibutton>OK</guibutton> will commit the changes and
1373     close the dialog. The user will be unable to undo the changes.
1374     <guibutton>Close</guibutton> simply closes the dialog box. If no
1375     selection has been applied with <guibutton>Try</guibutton> the
1376     selection will not be applied to the map.
1377     </para>
1378     </section>
1379     <section><title>Importing/Exporting Projections</title>
1380     <para>
1381     The projections that appear in the list of available projections
1382     can be exported to another file that the user chooses. By selecting
1383     one or more projections and clicking <guibutton>Export</guibutton>
1384     the user will be able to select a file in which to store those
1385     projections.
1386     The file can then be distributed to other Thuban users. To import
1387     a projection file the user can click <guibutton>Import</guibutton>.
1388     The imported projections are added to the list and are then available
1389     to the current session and any future Thuban sessions.
1390     </para>
1391     </section>
1392     </chapter>
1393    
1394     <chapter><title>Table Management</title>
1395     <para>
1396     Thuban distinguishes two different types of tables: Attribute tables
1397     (which belong to a layer) and normal data tables. Both provide
1398     the same general functionality with the difference that actions on an
1399     attribute table might also effect the map display.
1400     </para>
1401    
1402     <section><title>Table View</title>
1403     <para>
1404     <figure>
1405     <title>Table View</title>
1406     <mediaobject>
1407     <imageobject><imagedata fileref="../images/7_1_table_view.png" format="PNG" scale="&imgscale;"/></imageobject>
1408     <imageobject><imagedata fileref="./images/7_1_table_view.eps" format="EPS" scale="&imgscale;"/></imageobject>
1409     </mediaobject>
1410     </figure>
1411     </para>
1412     <para>
1413     Thuban provides a standard dialog to display table contents, the
1414     Table View. The view has five sections: The title, selections,
1415     the table grid, export functions, and the status bar.
1416     </para>
1417     <para>
1418     The title bar identifies the table with its name.
1419     </para>
1420     <para>
1421     The selections box let the user perform simple analysis on the data
1422     based on comparisons: The first choice must be a field identifier of
1423     the table, the second choice determines the type of comparison. The
1424     third choice can be either a specific value (interpreted as numerical
1425     or string depending on the type of the first field) or a second field
1426     identifier. Thus you can perform analysis like selecting all
1427     records where <literal>population > 10000</literal> or
1428     <literal>cars_per_inhabitant < bikes_per_inhabitant</literal>
1429     (note that the field names are only explanatory, the dBase files
1430     allow only 11 character field names).
1431    
1432     Selections can be combined either by applying a selection only on
1433     a previously selected set of records or by adding the results of a
1434     selection to a previous set. The default is that a selection replaces
1435     earlier results.
1436     </para>
1437     <para>
1438     The table grid shows the contents of the table (one record per row),
1439     with highlighted selection results. Columns and rows can be resized.
1440     </para>
1441     <para>
1442     The contents of a table can be exported into a file, either dBase
1443     format (DBF) or comma separated values (CSV). The
1444     <guibutton>Export</guibutton> button
1445     raises a file dialog to specify a path and file name, the export type
1446     is determined by the file extension (either .dbf or .csv).
1447    
1448     The <guibutton>Export Selection</guibutton> button works similarly
1449     but exports only the selected records.
1450    
1451     The <guibutton>Close</guibutton> button closes the table view window.
1452     This is different from the menu item
1453     <menuchoice>
1454     <guimenu>Table</guimenu>
1455     <guimenuitem>Close</guimenuitem>
1456     </menuchoice> which unloads the table from Thuban.
1457     </para>
1458     <para>
1459     The status bar displays some statistics about the table and optional
1460     selection results.
1461     </para>
1462     </section>
1463    
1464     <section><title>General Functionality (Menu Table)</title>
1465     <para>
1466     The general functions affect all tables open in Thuban. Attribute
1467     tables are considered here as normal data tables (with the exception
1468     that they cannot be closed).
1469     </para>
1470     <section><title>Open</title>
1471     <para>
1472     The
1473     <menuchoice>
1474     <guimenu>Table</guimenu>
1475     <guimenuitem>Open</guimenuitem>
1476     </menuchoice>
1477     item raises a file dialog to let you select a
1478     dBase file from the file system to be loaded into Thuban read-only.
1479     On <guibutton>OK</guibutton> the selected file is loaded and a
1480     table view is opened.
1481     </para>
1482     </section>
1483    
1484     <section><title>Close</title>
1485     <para>
1486     The
1487     <menuchoice>
1488     <guimenu>Table</guimenu>
1489     <guimenuitem>Close</guimenuitem>
1490     </menuchoice>
1491     item raises a dialog listing the currently open
1492     data tables
1493     (loaded via
1494     <menuchoice>
1495     <guimenu>Table</guimenu>
1496     <guimenuitem>Open</guimenuitem>
1497     </menuchoice>). Selected tables are dereferenced on confirmation.
1498     Since tables are opened read-only the contents of the tables are
1499     not affected.
1500    
1501     Any open views of the tables are closed as well.
1502    
1503     Tables used in a join cannot be closed.
1504     </para>
1505     </section>
1506    
1507     <section><title>Rename</title>
1508     <para>
1509     <menuchoice>
1510     <guimenu>Table</guimenu>
1511     <guimenuitem>Rename</guimenuitem>
1512     </menuchoice> changes the table title.
1513     </para>
1514     </section>
1515    
1516     <section><title>Show</title>
1517     <para>
1518     The
1519     <menuchoice>
1520     <guimenu>Table</guimenu>
1521     <guimenuitem>Show</guimenuitem>
1522     </menuchoice>
1523     item raises a list of available tables (explicitly
1524     loaded, attribute tables, results of a join). Selected tables are
1525     show in tables views on <guibutton>OK</guibutton>.
1526     </para>
1527     </section>
1528    
1529     <section><title>Join</title>
1530     <para>
1531     <figure>
1532     <title>Join Tables</title>
1533     <mediaobject>
1534     <imageobject><imagedata fileref="../images/7_2_5_join.png" format="PNG" scale="&imgscale;"/></imageobject>
1535     <imageobject><imagedata fileref="./images/7_2_5_join.eps" format="EPS" scale="&imgscale;"/></imageobject>
1536     </mediaobject>
1537     </figure>
1538     </para>
1539     <para>
1540     The
1541     <menuchoice>
1542     <guimenu>Table</guimenu>
1543     <guimenuitem>Join</guimenuitem>
1544     </menuchoice>
1545     item raises a dialog to specify the two tables to be
1546     joined. The join results in a new table named 'Join of "left table"
1547     and "right table"'.
1548    
1549     The dialog lets you select the two tables to be joined and the two
1550     fields the join has to be performed on. By default, the new
1551     table contains only those records which are matched by the join.
1552    
1553     If you want to preserve the records of the left table you can
1554     perform an outer join. The fields from the right table for records
1555     not matched by the join are filled with <varname>None</varname> in
1556     this case.
1557     </para>
1558     </section>
1559    
1560     </section>
1561     <section><title>Attribute Tables</title>
1562     <para>
1563     To clearly separate between both types of tables (data and
1564     attribute), Thuban provides functionality regarding the attribute
1565     tables under the <menuchoice><guimenu>Layer</guimenu></menuchoice> menu.
1566     </para>
1567    
1568     <section><title>Show Table</title>
1569     <para>
1570     <menuchoice>
1571     <guimenu>Layer</guimenu>
1572     <guimenuitem>Show Table</guimenuitem>
1573     </menuchoice>
1574     opens the attribute table of the currently active layer in a table
1575     view.
1576    
1577     In addition to the functionality described above selections
1578     affect also the map display: objects related to selected records
1579     are highlighted.
1580     </para>
1581     </section>
1582    
1583     <section><title>Join Table</title>
1584     <para>
1585     Unlike the join described above, the join does not result in a
1586     new table. The attribute table of the currently active layer is the
1587     left table and other tables are joined to this table. The results of
1588     the join are available for classification.
1589    
1590     As a consequence, the join cannot result in fewer
1591     records than the source attribute table. The user is warned if the
1592     right table does not fulfill this constraint. An outer join must be
1593     used in such cases.
1594     </para>
1595     </section>
1596    
1597     <section><title>Unjoin Table</title>
1598     <para>
1599     As said above, a normal table cannot be closed while it is still
1600     used in a join. While the joined table resulting from a join of
1601     normal tables can be simply closed (and thereby dereferencing
1602     the source tables), this is not possible for attribute tables.
1603    
1604     Hence joins on attribute tables must be solved explicitly. This is
1605     what the
1606     <menuchoice>
1607     <guimenu>Layer</guimenu>
1608     <guimenuitem>Unjoin Table</guimenuitem>
1609     </menuchoice>
1610     item is used for: The last join for the currently
1611     active layer is solved.
1612     </para>
1613     </section>
1614     </section>
1615     </chapter>
1616    
1617     <chapter><title>Extensions</title>
1618     <para>
1619     Thuban is designed to be extensible. The term Extension is used as a
1620     general term for anything that extends Thuban.
1621     This chapter introduces into some oppportunities how to add and
1622     handle extra functionality developed by your own or third parties.
1623     </para>
1624    
1625     <section><title>Add personal extensions via thubanstart.py</title>
1626     <para>
1627     After Thuban has been started for the first time, a directory
1628     .thuban is created within your home directory.
1629     There you can add a file thubanstart.py which will be imported
1630     by Thuban at start-up. It is recommended to add only import-statements
1631     to this file to keep the actual code of extensions separate.
1632     </para>
1633     <para>
1634     The modules to import must either be found through the environment
1635     variable PYTHONPATH or directly be placed into the .thuban-directory.
1636     </para>
1637     <para>
1638     As an example, copy the file examples/simple_extensions/hello_world.py
1639     of the Thuban source code into the .thuban-directory of your home
1640     directory. Now add add the statement import hello_world to the
1641     file thubanstart.py and run Thuban. You will notice an additional
1642     menu <menuchoice><guimenu>Extensions</guimenu></menuchoice> where
1643     the new item for the Hello-World extension is placed - select it
1644     to see the Hello-World message.
1645     </para>
1646     </section>
1647    
1648     <section><title>Extensions included in Thuban package</title>
1649     <para>
1650     The extensions described in this section are part of the
1651     Thuban package, but not activated by default.
1652     You will find them in the Thuban installation directory
1653     under <literal>Extensions/</literal>. Activate them as personal
1654     extensions via PYTHONPATH as described in the previous section.
1655     Stable extensions will appear under the menu
1656     <menuchoice><guimenu>Extensions</guimenu></menuchoice> and
1657     extensions which are in experimental state and therefore
1658     not fully functional under
1659     <menuchoice><guimenu>Experimental</guimenu></menuchoice>.
1660     </para>
1661    
1662     <section><title>Stable extensions</title>
1663     <para>
1664     These extensions provide extra-functionality to Thuban
1665     that has not (yet) been integrated in the main application.
1666     They are considered to be free of bugs, but may be
1667     further polished with helpful user interactions.
1668     </para>
1669     <section><title>gns2shp</title>
1670     <para>
1671     This tool converts data of the Geospatial Names Server
1672     (GNS, see <ulink url="http://www.nima.mil/gns"/>)
1673     into Shapefile format.
1674     The above web-site offer to download named places
1675     information grouped by countries for all of the world
1676     except USA for which other data are provided.
1677     </para>
1678     <para>
1679     If you download and unpack a package, you will have
1680     a text-file with suffix .txt.
1681     Selecting such a file via gns2shp will create the
1682     corresponding Shapefile with the same basename and
1683     place it in the same direcory. Afterwards it
1684     is automatically loaded into Thuban.
1685     The Shapefile will not automatically be delete afterwards.
1686     </para>
1687     <para>
1688     The gns2shp.py module can also be executed on the
1689     command line for batch processing purposes.
1690     </para>
1691     <para>
1692     A sample (<literal>ls.txt</literal> for Liechtenstein)
1693     is included in the directory
1694     <literal>Extensions/gns2shp/test</literal>.
1695     </para>
1696     </section>
1697     </section>
1698     <section><title>Experimental extensions</title>
1699     <para>
1700     All all of these functions have to be handled with care,
1701     since they are neither complete nor well tested.
1702     They are to be seen as a proof-of-concept and may
1703     additionally in some cases of practical help.
1704     </para>
1705     <para>
1706     Any interest on further improvement of these extensions
1707     should be communicated towards the developer and user
1708     community.
1709     </para>
1710    
1711     <section><title>importAPR</title>
1712     <para>
1713     This command offer to load an ESRI® ArcView® project
1714     file (suffix .apr) and convert it for use within Thuban.
1715     After selecting a apr-file to load, a list
1716     will be presented that offers to select one of the views
1717     of the apr-file, provided there is more than one.
1718     Furthermore, the Session Info-Tree is extended with
1719     a complete representation of the parsed apr-file.
1720     </para>
1721     <para>
1722     The legend of Thuban does not yet cover all of the elements as
1723     supported by the legend of ArcView®. Therefore, the Thuban
1724     map will look different. Furthermore, the apr-format is
1725     a proprietary format, not openly documented.
1726     Therefore, the interpretation is
1727     partly based on reverse engeneering and good guessing.
1728     </para>
1729     <para>
1730     The file-paths within the apr-file may not fit and potentially
1731     are subject to fix in the apr-file. You can do this
1732     applying any text editor. The paths are either absolute
1733     or relative from where Thuban has been started.
1734     </para>
1735     <para>
1736     A sample for the Iceland data is included as
1737     <literal>Extensions/importAPR/samples/iceland.apr</literal>.
1738     The file-paths are relative from the Thuban main directory.
1739     </para>
1740     </section>
1741     </section>
1742     </section>
1743    
1744     <section><title>Writing simple extensions</title>
1745     <para>
1746     Writing an extension for Thuban basically means to
1747     implement the extra functionality in Python with all of the
1748     Thuban classes, methods and variables available.
1749     </para>
1750     <para>
1751     All classes and their methods are documented in the source code
1752     (see their doc-strings). Here is an example from
1753     Thuban/Model/layer.py that describes some of the methods
1754     of a Layer object:
1755     </para>
1756     <programlisting>
1757     <![CDATA[
1758     class BaseLayer(TitledObject, Modifiable):
1759    
1760     """Base class for the layers."""
1761    
1762     def __init__(self, title, visible = True, projection = None):
1763     """Initialize the layer.
1764    
1765     title -- the title
1766     visible -- boolean. If true the layer is visible.
1767     """
1768     TitledObject.__init__(self, title)
1769     Modifiable.__init__(self)
1770     self.visible = visible
1771     self.projection = projection
1772    
1773     def Visible(self):
1774     """Return true if layer is visible"""
1775     return self.visible
1776    
1777     def SetVisible(self, visible):
1778     """Set the layer's visibility."""
1779     self.visible = visible
1780     self.issue(LAYER_VISIBILITY_CHANGED, self)
1781    
1782     def HasClassification(self):
1783     """Determine if this layer support classifications."""
1784     ...
1785     ]]>
1786     </programlisting>
1787     <para>
1788     This example intends to give you an impression of the
1789     source-code-level documentation.
1790     You have to make yourself familiar with
1791     the Python programming language to understand some special
1792     code elements.
1793     </para>
1794     <section><title>hello_world.py</title>
1795     <para>
1796     Traditionally, the first example should welcome the world.
1797     Most of the code handles the frame for integrating a menu
1798     item into Thuban while the actual raising of a message
1799     is done in a single line.
1800     </para>
1801     <programlisting>
1802     <![CDATA[
1803     # Copyright (C) 2003 by Intevation GmbH
1804     # Authors:
1805     # Jan-Oliver Wagner <[email protected]>
1806     #
1807     # This program is free software under the GPL (>=v2)
1808     # Read the file COPYING coming with Thuban for details.
1809    
1810     """
1811     Extend Thuban with a sample Hello World to demonstrate simple
1812     extensions.
1813     """
1814    
1815     __version__ = '$Revision$'
1816    
1817     # use _() already now for all strings that may later be translated
1818     from Thuban import _
1819    
1820     # Thuban has named commands which can be registered in the central
1821     # instance registry.
1822     from Thuban.UI.command import registry, Command
1823    
1824     # The instance of the main menu of the Thuban application
1825     # See Thuban/UI/menu.py for the API of the Menu class
1826     from Thuban.UI.mainwindow import main_menu
1827    
1828     def hello_world_dialog(context):
1829     """Just raise a simple dialog to greet the world.
1830    
1831     context -- The Thuban context.
1832     """
1833     context.mainwindow.RunMessageBox(_('Hello World'), _('Hello World!'))
1834    
1835    
1836     # create a new command and register it
1837     registry.Add(Command('hello_world', _('Hello World'), hello_world_dialog,
1838     helptext = _('Welcome everyone on this planet')))
1839    
1840     # find the extensions menu (create it anew if not found)
1841     extensions_menu = main_menu.FindOrInsertMenu('extensions', _('E&xtensions'))
1842    
1843     # finally bind the new command with an entry in the extensions menu
1844     extensions_menu.InsertItem('hello_world')
1845     ]]>
1846     </programlisting>
1847     </section>
1848     <section><title>Registering a Command</title>
1849     <para>
1850     Mainly, our new function has to be registered to the Thuban
1851     framework in order to connect it to the menu. A registered
1852     command can also be connected to e.g. a toolbar button.
1853     </para>
1854     <para>
1855     The instances and classes for this are imported at the beginning.
1856     Any code not inside a method or class is directly executed when
1857     the source-code module is imported. Therefore, the second
1858     part of this example consist of the plain statements to create a new
1859     Command and to add it to the menu.
1860     </para>
1861     <para>
1862     By convention, it looks for a menu registered as ``extensions'' to
1863     insert the new command. If it does not exist yet, it gets created.
1864     It is advisable to copy this code for any of your extensions.
1865     </para>
1866     </section>
1867     <section><title>The Thuban context</title>
1868     <para>
1869     A registered command that is called, always receives the
1870     Thuban context. This instance provides our method with
1871     hook references to all important components of the Thuban
1872     application.
1873     </para>
1874     <para>
1875     In the example hello_world.py, our function uses the
1876     mainwindow component which offers a method to raise a
1877     message dialog. In total there are three hooks:
1878     <itemizedlist>
1879     <listitem>
1880     <para>application:
1881     This object is the instance of the Thuban Application class.
1882     Except maybe for loading or savinf sessions, you will not
1883     need this object for a simple extension.
1884     See Thuban/UI/application.py for the API.
1885     </para>
1886     </listitem>
1887     <listitem>
1888     <para>session:
1889     The instance of the current session. It manages the sessions'
1890     map and tables. You can set and remove the map or tables.
1891     In may also get the map object. However, you should know that
1892     internally it is already prepared to handle many maps.
1893     Therfore, currently you would always receive a list with exactlty
1894     one element. In the future, if there are more than one map,
1895     you will not know which one is the currently display one and
1896     therefore you should use the mainwindow as hook to find
1897     the currently displayed map.
1898     See Thuban/Model/session.py for the API.
1899     </para>
1900     </listitem>
1901     <listitem>
1902     <para>
1903     mainwindow: The mainwindow object is central to manage various
1904     GUI things such as the Legend sub-window. Most notably,
1905     you get access to the canvas which is the window part where
1906     the map is drawn. The canvas knows, which map it currently
1907     draws and therefore you get the current map via
1908     context.mainwindow.canvas.Map().
1909     See Thuban/UI/mainwindow.py for the API.
1910     </para>
1911     </listitem>
1912     </itemizedlist>
1913     </para>
1914     </section>
1915     </section>
1916     </chapter>
1917    
1918     <chapter><title>Trouble Shooting</title>
1919     <para>
1920     Here are a few problems that users have encountered when first using Thuban.
1921     </para>
1922     <para>
1923    
1924     <itemizedlist>
1925     <listitem>
1926     <para>After adding two or more layers nothing is drawn in the map window.
1927     </para>
1928     <para>
1929     This is probably because the layers have different projections. Projections
1930     must be set on all layers and on the map itself if the layers' projections
1931     are different.
1932     </para>
1933     </listitem>
1934    
1935     <listitem>
1936     <para>Thuban crashes on startup with the error
1937     <literal>NameError: global name 'False' is not defined</literal>.
1938     </para>
1939     <para>
1940     <varname>True</varname> and <varname>False</varname> were only introduced
1941     in Python 2.2.1. Thuban depends on at least Python 2.2.1.
1942     </para>
1943     </listitem>
1944    
1945     <listitem>
1946     <para>After compiling Thuban, Thuban crashes with an error similar to
1947     <literal>
1948     ImportError: /usr/local//lib/thuban/Thuban/../Lib/wxproj.so: undefined symbol: __gxx_personality_v0
1949     </literal>
1950     </para>
1951     <para>
1952     Thuban depends on the wxWindows library. If Thuban is compiled with an
1953     incompatible version of the compiler than wxWindows was compiled with
1954     this error may occur. Try compiling with a different version of the
1955     compiler.
1956     </para>
1957     </listitem>
1958     </itemizedlist>
1959     </para>
1960     <para>
1961     If an error occurs Thuban will display a dialog indicating the error
1962     before closing. The text should be copied and reported to the
1963     <ulink url="http://thuban.intevation.org/bugtracker.html">
1964     Intevation bugtracker
1965     </ulink>.
1966     More information about the system is available from
1967     <menuchoice><guimenu>Help</guimenu><guimenuitem>About</guimenuitem></menuchoice> box.
1968     This should also be included in the bug report.
1969     <figure>
1970     <title>Error Dialog</title>
1971     <mediaobject>
1972     <imageobject><imagedata fileref="../images/8_int_error.png" format="PNG" scale="&imgscale;"/></imageobject>
1973     <imageobject><imagedata fileref="./images/8_int_error.eps" format="EPS" scale="&imgscale;"/></imageobject>
1974     </mediaobject>
1975     </figure>
1976     </para>
1977    
1978     </chapter>
1979    
1980     <appendix><title>Supported Data Sources</title>
1981     <para>
1982     </para>
1983     <variablelist>
1984     <varlistentry>
1985     <term>Shapefile</term>
1986     <listitem>
1987     <para>
1988     The Shapefile format has become a standard format for saving
1989     geographic vector information. It supports polygons, lines, and
1990     points.
1991    
1992     <ulink url="http://www.esri.com/library/whitepapers/pdfs/shapefile.pdf">
1993     Technical Specification.
1994     </ulink>
1995     </para>
1996     </listitem>
1997     </varlistentry>
1998    
1999     <varlistentry>
2000     <term>dBase file</term>
2001     <listitem>
2002     <para>
2003     dBase files are used to store the attributes for each layer. This
2004     is closely associated with the Shapefile format. For detailed
2005     specifications on the correct format of a dBase file used with
2006     Thuban please see the Technical Specification for the Shapefile
2007     format above.
2008     </para>
2009     </listitem>
2010     </varlistentry>
2011    
2012     <varlistentry>
2013     <term>PostGIS</term>
2014     <listitem>
2015     <para>
2016     PostGIS adds support for geographic objects to the PostgreSQL
2017     object-relational database. Different layer types (as for Shapefiles)
2018     are supported. <ulink url="http://postgis.refractions.net">PostGIS
2019     Homepage</ulink>
2020     </para>
2021     </listitem>
2022     </varlistentry>
2023    
2024     <varlistentry>
2025     <term>Raster files</term>
2026     <listitem>
2027     <para>
2028     Binding the GDAL library Thuban supports numerous raster file formats,
2029     see <ulink url="http://www.remotesensing.org/gdal/formats_list.html">
2030     GDAL format list</ulink> for details.</para>
2031    
2032     <para>Most commonly used is the <emphasis>TIFF/GeoTIFF</emphasis>
2033     format: Raster maps are provided as TIFF images, with an additional
2034     "world file" storing the geographic reference (usually with an
2035     extension ".tfw").
2036     </para>
2037     </listitem>
2038     </varlistentry>
2039    
2040     </variablelist>
2041     </appendix>
2042    
2043     <appendix><title>Working with PostGIS</title>
2044     <para>
2045     This section focusses on the use of PostGIS in the Thuban framework. For
2046     installation and maintenance of spatial databases we refer to the
2047     <ulink url="http://postgis.refractions.net">PostGIS Homepage</ulink>.
2048     The Thuban PostGIS support requires the
2049     <ulink url="http://initd.org/software/psycopg">psycopg module</ulink>.
2050     </para>
2051    
2052     <para>
2053     Working with PostGIS Databases is seperated into two steps:
2054     <itemizedlist>
2055     <listitem><para>Opening a Database Connection</para></listitem>
2056     <listitem><para>Loading a Data Layer</para></listitem>
2057     </itemizedlist>
2058     </para>
2059     <section><title>Opening a Database Connection</title>
2060     <para>
2061     Before a data layer can be loaded from a PostGIS database a
2062     connection with the database has to be established.
2063     <menuchoice>
2064     <guimenu>Session</guimenu>
2065     <guimenuitem>Database Connections ...</guimenuitem>
2066     </menuchoice> opens a dialog for database connection
2067     management. In the dialog new connections can be added
2068     and existing ones can be removed. Removing a database
2069     connection is not possible if the map still displays a
2070     layer provided by this database connection.
2071     </para>
2072     <figure>
2073     <title>Database Management Dialog</title>
2074     <mediaobject>
2075     <imageobject><imagedata fileref="../images/app_postgis_db_management.png" format="PNG" scale="&imgscale;"/></imageobject>
2076     <imageobject><imagedata fileref="./images/app_postgis_db_management.eps" format="EPS" scale="&imgscale;"/></imageobject>
2077     </mediaobject>
2078     </figure>
2079    
2080     <para>
2081     To add a new database connection to the session a dialog is
2082     opened to specify the relevant connection data. Enter all
2083     data relevant for your connection. If the connection fails
2084     the dialog remains open and provides some hints on the failure.
2085     </para>
2086     <figure>
2087     <title>Add Database Dialog</title>
2088     <mediaobject>
2089     <imageobject><imagedata fileref="../images/app_postgis_db_add.png" format="PNG" scale="&imgscale;"/></imageobject>
2090     <imageobject><imagedata fileref="./images/app_postgis_db_add.eps" format="EPS" scale="&imgscale;"/></imageobject>
2091     </mediaobject>
2092     </figure>
2093    
2094     <para>
2095     It is important to note that information on database connections are
2096     also stored with the session. Passwords are NOT stored. If you load a
2097     session with database connections you are asked to enter these
2098     passwords again where required.
2099     </para>
2100    
2101     </section>
2102    
2103     <section><title>Loading a Data Layer</title>
2104     <para>
2105     Data layers as part of a map are loaded with the
2106     <menuchoice>
2107     <guimenu>Map</guimenu>
2108     <guimenuitem>Add Database Layer ...</guimenuitem>
2109     </menuchoice> menu item. A dialog is raised displaying two choice
2110     lists. In the left list all connected databases are shown.
2111     Highlighting
2112     one of these and issuing a retrieval results in a list of available
2113     layer tables from that database. After selection of a
2114     layer the dialog is closed.
2115     </para>
2116     <figure>
2117     <title>Add Database Dialog</title>
2118     <mediaobject>
2119     <imageobject><imagedata fileref="../images/app_postgis_add_layer.png" format="PNG" scale="&imgscale;"/></imageobject>
2120     <imageobject><imagedata fileref="./images/app_postgis_add_layer.eps" format="EPS" scale="&imgscale;"/></imageobject>
2121     </mediaobject>
2122     </figure>
2123    
2124     </section>
2125    
2126     </appendix>
2127    
2128     <appendix><title>Supported Projections</title>
2129     <para>
2130     The following types of projections are directly support by
2131     Thuban. The specific values for each are provided by the user
2132     to create custom projections. Thuban comes with predefined
2133     projections which are available through the Projections dialog.
2134     </para>
2135     <itemizedlist>
2136     <listitem>
2137     <para>Geographic</para>
2138     <itemizedlist>
2139     <listitem><para><literal>Ellipsoid</literal></para></listitem>
2140     <listitem><para>
2141     <literal>Source Data</literal>: either Degrees or Radians
2142     </para></listitem>
2143     </itemizedlist>
2144     </listitem>
2145     <listitem>
2146     <para>Lambert Conic Conformal</para>
2147     <itemizedlist>
2148     <listitem><para><literal>Ellipsoid</literal></para></listitem>
2149     <listitem><para><literal>Latitude of 1st standard parallel</literal></para></listitem>
2150     <listitem><para><literal>Latitude of 2nd standard parallel</literal></para></listitem>
2151     <listitem><para><literal>Central Meridian</literal></para></listitem>
2152     <listitem><para><literal>Latitude of Origin</literal></para></listitem>
2153     <listitem><para><literal>False Easting</literal> (meters)</para></listitem>
2154     <listitem><para><literal>False Northing</literal> (meters)</para></listitem>
2155     </itemizedlist>
2156     </listitem>
2157     <listitem>
2158     <para>Transverse Mercator</para>
2159     <itemizedlist>
2160     <listitem><para><literal>Ellipsoid</literal></para></listitem>
2161     <listitem><para><literal>Latitude</literal>of origin</para></listitem>
2162     <listitem><para><literal>Longitude</literal>at central meridian</para></listitem>
2163     <listitem><para><literal>Scale Factor</literal>at central meridian</para></listitem>
2164     <listitem><para><literal>False Easting</literal> (meters)</para></listitem>
2165     <listitem><para><literal>False Northing</literal> (meters)</para></listitem>
2166     </itemizedlist>
2167     </listitem>
2168     <listitem>
2169     <para>Universal Transverse Mercator</para>
2170     <itemizedlist>
2171     <listitem><para><literal>Ellipsoid</literal></para></listitem>
2172     <listitem><para><literal>Zone</literal>
2173     (can be guessed appling the Propose button)</para></listitem>
2174     <listitem><para><literal>Southern Hemisphere</literal> flag</para></listitem>
2175     </itemizedlist>
2176     </listitem>
2177     </itemizedlist>
2178    
2179     <para>
2180     Thuban comes with a sample set of map projections for various
2181     European countries. Apart from the basic projection they differ
2182     especially in their parameterization:
2183     </para>
2184     <itemizedlist>
2185     <listitem><para>Belgium Datum 1972 (Lambert Conic Conformal)</para>
2186     </listitem>
2187    
2188     <listitem><para>Gauss-Boaga Zone 1 (Italy, Transverse Mercartor)</para>
2189     </listitem>
2190    
2191     <listitem><para>Gauss-Krueger Zone 2 (Germany, Transverse Mercartor)
2192     </para>
2193     </listitem>
2194    
2195     <listitem><para>Reseau Geodesique Francaise
2196     (France, Lambert Conic Conformal)</para>
2197     </listitem>
2198    
2199     <listitem><para>UK National Grid (United Kingdom, Transverse Mercartor)
2200     </para>
2201     </listitem>
2202     </itemizedlist>
2203    
2204     <para>
2205     Thuban uses the comprehensive PROJ library for projections. PROJ provides
2206     more than the four commonly used projections described above. If needed
2207     Thuban can be easily extended to a new projection covered by PROJ.
2208     </para>
2209     </appendix>
2210    
2211     </book>
2212    

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26