
Copyright © 2005 Anne-Marie Mahfouf
Copyright © 2008 Kushal Das
KGeography is a geography learning tool for KDE. Right now it has seven usage modes:
Browse the maps clicking in a map division to see its name, capital and flag
The game tells you a map division name and you have to click on it
The game tells you a capital and you have to guess the division it belongs to
The game tells you a division and you have to guess its capital
The game shows you a map division flag and you have to guess its name
The game tells you a map division name and you have to guess its flag
The game shows an empty map and you have to place divisions on it one by one
Table of Contents

When you run KGeography for the first time, it first asks you to choose a map to start with.

Here we choose Canada

And KGeography main window appears with the map of Canada:

You can then choose what type of learning or testing you want to do by looking at the menu on the left:

Explore Map: a
mouse button click on an area of the map will display information about that area, if you click on the small info icon on the popmap, it will open the wikipedia page for that division in the system's default browser:
Location of Provinces or Territories: you are first asked how many questions you want

Then you are asked to click on a specific province:

When you finish all the questions, a result dialog is shown with your correct and uncorrect answers:

Place Provinces or Territories in the Map: the cursor takes the shape of a province and you have to place it in the map:

Provinces or Territories by Capital: you are asked to find the name of a province among a choice of 4 given its capital:

And the results are displayed when the test is finished:

Capitals of Provinces and Territories: you have a capital and four province names and you must choose the correct one. As before, at the end a result dialog is shown.
Provinces or Territories by Flag: a flag is shown and you must find the province it belongs to.

Flags of Provinces and Territories: a province name is given and you must find the correct flag among four.


KGeography displays information about some countries and tests you about those information.

Another feature of KGeography is the possibility of zoom on a map.


A map in KGeography is made by two files, one is the image of the map and the other one is its description.
You can find here a tool (made by Yann Verley) which helped him with the map of France. To find out its usage, simply execute it and read the help message. It basically creates the .kgm
file from a plain text file and creates a file with the colors it has assigned to each division, so you can fill the map according to them.
There is another tool colorchecker.py written by Albert Astals Cid. You need PyQt4 to run this. Just run this with the .kgm filename as argument (you also need the .png file of the map in the same folder). This will tell you if any pixel on the map has a different color which is not defined in the .kgm (description) file.

The description file is needed and its file extension is .kgm
. It should begin with <map>
and end with </map>
.
Inside of those tags there should be:
<mapFile>
and</mapFile>
: the name of the file (without any path) containing the map image, e.g. “europe.png”.<name>
and</name>
: the name of map, e.g. “Europe”.<divisionsName>
and</divisionsName>
: the general name of divisions in this map, that is, Provinces, States, Countries, etc.A
<division>
and</division>
for each division in the map.
Each division has these tags:
<name>
and</name>
: the name of the division, e.g. “Albania”.<capital>
and</capital>
: the name of the capital of the division, e.g. “Tirana”.<ignore>
and</ignore>
: can be set toyes
,allowClickMode
,allowClickFlagMode
andno
. If this tag is set toyes
then the division will be ignored when asking for divisions in that map. It is then as if this division does not exist in KGeography quiz modes. If this tag is set toallowClickMode
then KGeography will ask for the division in the mode but not in other quiz modes. If this tag is set toallowClickFlagMode
then KGeography will ask for the division in the mode and in the flag related quizes but not in other quiz modes. Setting this tag tono
means the division will appear in all modes (browse and quizzes). This tag is optional and when there is no<ignore>
tag that means as it is set tono
. For example “Algeria” has this tag set toyes
in the “Europe” map which means that “Algeria” will not be part of any quiz in the “Europe” map.<flag>
and</flag>
: the file (without any path) containing the flag of the division, e.g. “albania.png”. This tag is optional. Not needed for the divisions whose<ignore>
tag is set toyes
.<color>
and</color>
: the color the division has in the map.<falseCapital>
and</falseCapital>
: There can be any number of falseCapital pairs, they are used to provide a list of false answers to the capital question instead of choosing the false answers amongst the other divisions capitals.
The color is defined using three tags:
<red>
and</red>
: red component of the color. Valid values are between 0 and 255.<green>
and</green>
: green component of the color. Valid values are between 0 and 255.<blue>
and</blue>
: blue component of the color. Valid values are between 0 and 255.
Tip
It is convenient to create 2 or 3 false divisions like “Water”, “Frontier” and “Coast” and set them with the <ignore>
tag set to yes
. Don't forget not to set
color for any “Frontier” 0,0,0 in RGB. Please make it something like 1,1,1 so that a border outline comes while placing any division on the map.
Important
All names (capitals and divisions) must be in English.

The map file is quite simple but laborious to create. It has to be in PNG format. You can find some maps to transform at Cia Reference Maps. If no map fits your needs you can download the political world map, take a screenshot of it and work from it. Each division in the map should have one and only one color. To achieve this you can use image processing programs like The Gimp and Kolourpaint.

If you have used the <flag>
tag you should provide the flag files. They have to be in PNG format and better if they are 300x200 pixels and you provide a SVG file for it. To obtain SVG flags of almost all countries in the world and some other divisions, you can consult the Sodipodi flags collection.

Before sending your map to Albert (tsdgeos AT terra.es)
, you should test it to see it has no errors. To achieve that, you have to do the following:
Put the map description and map image file in
$
KDEDIR
/share/apps/kgeography/Put the flag PNG files (if any) in
$
KDEDIR
/share/apps/kgeography/flags/
If you don't know which is your $
, type KDEDIR
kde4-config
in a shell.
--prefix
Tip
Use the colorchecker.py tool from the helper tools to check if any extra color left on the map which is not defined on the .kgm file.

Is it possible to do non-political maps? Yes, it is!

Of course, the division concept can be extended to a river or a mountain. During the creation of the map, you should keep in mind that most times the river or mountain will be too small that you should provide an additional clicking area. In this example the river would have the maroon area and color <20,76,34> as its identifier.

- ->
Goes in zoom mode, then draw a rectangle to zoom in a part of the map
- ->
Sets the map back to its original size
- ->
Sets the map to automatic zoom using as much space as possible
- ->
Moves the current map. This item is only enabled, if you have zoomed into the map.
- ->
Show/Hide the KGeography toolbar.
- ->
Configure key shortcuts for KGeography.
- ->
Configure the KGeography toolbar.
KGeography has a default KDE as described below, with two additionional entries:
- ->
Displays a disclaimer about the accuracy of maps, flags and translations used by KGeography.
- ->
Displays the name of author who created the current map.
The default KDE entries are:
- -> (F1)
Invokes the KDE Help system starting at the KGeography help pages. (this document).
- -> (Shift+F1)
Changes the mouse cursor to a combination arrow and question mark. Clicking on items within KGeography will open a help window (if one exists for the particular item) explaining the item's function.
- ->
Opens the Bug report dialog where you can report a bug or request a “wishlist” feature.
- ->
Opens a dialog where you can edit the Primary language and Fallback language for this application.
- ->
This will display version and author information.
- ->
This displays the KDE version and other basic information.

KGeography
Program copyright 2004-2008 Albert Astals Cid (tsdgeos AT terra.es)
Documentation Copyright (c) 2005 Anne-Marie Mahfouf (annma AT kde.org)
2008 Kushal Das (kushaldas AT gmail.com)
This documentation is licensed under the terms of the GNU Free Documentation License.
This program is licensed under the terms of the GNU General Public License.

Table of Contents
KGeography is part of the KDE project http://www.kde.org/.
KGeography can be found in the kdeedu package on ftp://ftp.kde.org/pub/kde/, the main FTP site of the KDE project.

For detailed information on how to compile and install KDE applications see Building KDE4 From Source
Since KDE uses cmake you should have no trouble compiling it. Should you run into problems please report them to the KDE mailing lists.