dabo Commit
Revision 5414
Date: 2009-09-23 21:29:00 -0700 (Wed, 23 Sep 2009)
Author: Paul
Trac: http://trac.dabodev.com/changeset/5414
Changed:
U trunk/ide/ReportDesigner.py
Log:
If the x or y expr evaluation causes an error, don't leave the report designer
in an arbitrary unusable state, just put the object at position 0.
Diff:
Modified: trunk/ide/ReportDesigner.py
===================================================================
--- trunk/ide/ReportDesigner.py 2009-09-24 04:28:07 UTC (rev 5413)
+++ trunk/ide/ReportDesigner.py 2009-09-24 04:29:00 UTC (rev 5414)
@@ -1243,8 +1243,14 @@
"""Return the size and position needed to draw the object at
the current zoom factor."""
rw = self._rw
z = self.Parent.ZoomFactor
- x = rw.getPt(obj.getProp("x"))
- y_ = rw.getPt(obj.getProp("y"))
+ try:
+ x = rw.getPt(obj.getProp("x"))
+ except ValueError:
+ x = 0
+ try:
+ y_ = rw.getPt(obj.getProp("y"))
+ except ValueError:
+ y_ = 0
y = ((self.Height - self._bandLabelHeight)/z) - y_
if isinstance(obj, (SpanningLine, SpanningRectangle)):
_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-dev
Searchable Archives: http://leafe.com/archives/search/dabo-dev
This message:
http://leafe.com/archives/byMID/[email protected]