Ignore:
Timestamp:
Nov 6, 2015 1:22:59 AM (9 years ago)
Author:
ldelgass
Message:

Add extra ogr fields, extent srs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gui/scripts/map.tcl

    r5917 r5932  
    4343    public method setAttribution { attribution }
    4444    public method setCamera { camera }
    45     public method setExtents { xmin ymin xmax ymax }
     45    public method setExtents { xmin ymin xmax ymax {srs "wgs84"} }
    4646    public method setLabel { label }
    4747    public method setProjection { projection }
     
    253253                # FIXME: Add test for valid file path
    254254                $_tree set $child "ogr.url" $file
     255            }
     256            foreach key { connection geometry geometry_url layer ogr_driver build_spatial_index } {
     257                set value [$layers get $layer.ogr.$key]
     258                if { $value != "" } {
     259                    $_tree set $child "ogr.$key" $value
     260                }
    255261            }
    256262            $_tree set $child "driver" "ogr"
     
    425431}
    426432
    427 itcl::body Rappture::Map::setExtents { xmin ymin xmax ymax } {
    428     $_tree set root "extents" "$xmin $ymin $xmax $ymax"
     433itcl::body Rappture::Map::setExtents { xmin ymin xmax ymax {srs "wgs84"} } {
     434    $_tree set root "extents" [list $xmin $ymin $xmax $ymax $srs]
    429435}
    430436
Note: See TracChangeset for help on using the changeset viewer.