/[thuban]/branches/WIP-pyshapelib-bramz/Thuban/Model/load.py
ViewVC logotype

Diff of /branches/WIP-pyshapelib-bramz/Thuban/Model/load.py

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2687 by jan, Wed Jul 27 21:50:30 2005 UTC revision 2688 by frank, Fri Jun 30 12:27:20 2006 UTC
# Line 33  from Thuban.Model.layer import Layer, Ra Line 33  from Thuban.Model.layer import Layer, Ra
33  from Thuban.Model.proj import Projection  from Thuban.Model.proj import Projection
34  from Thuban.Model.range import Range  from Thuban.Model.range import Range
35  from Thuban.Model.classification import Classification, \  from Thuban.Model.classification import Classification, \
36      ClassGroupDefault, ClassGroupSingleton, ClassGroupRange, ClassGroupMap, \      ClassGroupDefault, ClassGroupSingleton, ClassGroupRange, \
37        ClassGroupPattern, ClassGroupMap, \
38      ClassGroupProperties      ClassGroupProperties
39  from Thuban.Model.data import DerivedShapeStore, ShapefileStore  from Thuban.Model.data import DerivedShapeStore, ShapefileStore
40  from Thuban.Model.table import DBFTable  from Thuban.Model.table import DBFTable
# Line 136  class SessionLoader(XMLReader): Line 137  class SessionLoader(XMLReader):
137              'clnull'        : ("start_clnull",         "end_clnull"),              'clnull'        : ("start_clnull",         "end_clnull"),
138              'clpoint'       : ("start_clpoint",        "end_clpoint"),              'clpoint'       : ("start_clpoint",        "end_clpoint"),
139              'clrange'       : ("start_clrange",        "end_clrange"),              'clrange'       : ("start_clrange",        "end_clrange"),
140                'clpattern'     : ("start_clpattern",      "end_clpattern"),
141              'cldata'        : ("start_cldata",         "end_cldata"),              'cldata'        : ("start_cldata",         "end_cldata"),
142              'table'         : ("start_table",          "end_table"),              'table'         : ("start_table",          "end_table"),
143              'labellayer'    : ("start_labellayer",     None),              'labellayer'    : ("start_labellayer",     None),
# Line 615  class SessionLoader(XMLReader): Line 617  class SessionLoader(XMLReader):
617          self.aLayer.GetClassification().AppendGroup(self.cl_group)          self.aLayer.GetClassification().AppendGroup(self.cl_group)
618          del self.cl_group, self.cl_prop          del self.cl_group, self.cl_prop
619    
620    
621        def start_clpattern(self, name, qname, attrs):
622            pattern = attrs.get((None, 'pattern'), "")
623    
624            self.cl_group = ClassGroupPattern(self.encode(pattern))
625            self.cl_group.SetLabel(self.encode(attrs.get((None, 'label'), "")))
626            self.cl_prop = ClassGroupProperties()
627    
628        def end_clpattern(self, name, qname):
629            self.cl_group.SetProperties(self.cl_prop)
630            self.aLayer.GetClassification().AppendGroup(self.cl_group)
631            del self.cl_group, self.cl_prop
632    
633    
634      def start_cldata(self, name, qname, attrs):      def start_cldata(self, name, qname, attrs):
635          self.cl_prop.SetLineColor(          self.cl_prop.SetLineColor(
636              parse_color(attrs.get((None, 'stroke'), "None")))              parse_color(attrs.get((None, 'stroke'), "None")))

Legend:
Removed from v.2687  
changed lines
  Added in v.2688

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26