1 |
# Copyright (C) 2003 by Intevation GmbH |
# Copyright (C) 2003, 2004 by Intevation GmbH |
2 |
# Authors: |
# Authors: |
3 |
# Jan-Oliver Wagner <[email protected]> |
# Jan-Oliver Wagner <[email protected]> (2003, 2004) |
4 |
# |
# |
5 |
# This program is free software under the GPL (>=v2) |
# This program is free software under the GPL (>=v2) |
6 |
# Read the file COPYING coming with Thuban for details. |
# Read the file COPYING coming with Thuban for details. |
32 |
from Thuban import _ |
from Thuban import _ |
33 |
from Thuban.Model.layer import Layer |
from Thuban.Model.layer import Layer |
34 |
|
|
|
from Thuban.UI.extensionregistry import ExtensionDesc, ext_registry |
|
|
|
|
35 |
import shapelib |
import shapelib |
36 |
import dbflib |
import dbflib |
37 |
|
|
|
|
|
|
ext_registry.add(ExtensionDesc( |
|
|
name = 'gns2shp', |
|
|
version = '1.0.0', |
|
|
authors= [ 'Jan-Oliver Wagner' ], |
|
|
copyright = '2003, 2004 Intevation GmbH', |
|
|
desc = _("Converts GNS (Geographical Name Service\n" \ |
|
|
"of NIMA) to Shapefile format and\n" \ |
|
|
"displays the data."))) |
|
|
|
|
|
|
|
38 |
def gns2shp(src_fname, dest_fname): |
def gns2shp(src_fname, dest_fname): |
39 |
"""Convert a file from gns textformat into a Shapefile. |
"""Convert a file from gns textformat into a Shapefile. |
40 |
|
|