from globals import *
import os, sys, getopt, re, traceback, tempfile, shutil, cPickle
+from xml.parsers import expat
# Local modules
from tree import * # imports xxx which imports params
data = wx.CustomDataObject('XRCED')
# Set encoding in header
# (False,True)
- s = (xxx.element.toxml(encoding=g.currentEncoding),
- xxx.element.toxml())[not g.currentEncoding]
+ s = xxx.element.toxml(encoding=expat.native_encoding)
data.SetData(cPickle.dumps(s))
wx.TheClipboard.SetData(data)
wx.TheClipboard.Close()
if wx.TheClipboard.Open():
data = wx.CustomDataObject('XRCED')
# (False, True)
- s = (elem.toxml(encoding=g.currentEncoding),
- elem.toxml())[not g.currentEncoding]
+ s = elem.toxml(encoding=expat.native_encoding)
data.SetData(cPickle.dumps(s))
wx.TheClipboard.SetData(data)
wx.TheClipboard.Close()
allParams = ['size', 'option', 'flag', 'border']
paramDict = {'option': ParamInt}
default = {'size': '0,0'}
+ def __init__(self, parent, element, refElem=None):
+ # For GridBag sizer items, extra parameters added
+ if isinstance(parent, xxxGridBagSizer):
+ self.allParams = self.allParams + ['cellpos', 'cellspan']
+ xxxObject.__init__(self, parent, element, refElem)
class xxxMenuBar(xxxContainer):
allParams = ['style']