On 4/21/12 2:50 AM, Zdravko Subakov wrote:
> Ok, it took me a couple of hours but I can now mix all that I want and get
> it on the form and even save it.(but we have new error on open file)
>
> The change was in dabo/ui/uisx/dEditor.py the line is 1476 it was:
>
> open(fname, "wb").write(self.GetText().encode(self.Encoding))
> for some time it was:
> codecs.open(fname,"wb").write(self.GetText().encode(self.Encoding))
> and final solution was
> codecs.open(fname,"wb").write(self.GetText().encode("utf-8"))
> (with appropriate import codecs statement in the begining of the dEditor.py)
>
> Of course it demanded reinstall, I suppose it would be enough to recompile
> just that file but as I am newbie I might be speaking nonsense.
>
> Before this solution I changed back what we did in utils.py (to CP-1252) and
> removed the settings_override.py
>
> the error I got now when I try to open saved file is:
> **********************
> C:\dabo\ide>python editor.py
> Traceback (most recent call last):
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dPemMixi
> n.py", line 566, in __onWxMenuOpen
>      menu.raiseEvent(dEvents.MenuOpen, evt)
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dPemMixi
> n.py", line 1045, in raiseEvent
>      super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args,
> **kwargs)
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\lib\eventMixin.p
> y", line 81, in raiseEvent
>      bindingFunction(event)
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dMenu.py
> ", line 94, in __onMenuHighlight
>      self._setDynamicEnabled()
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dMenu.py
> ", line 107, in _setDynamicEnabled
>      item.Enabled = de()
>    File "editor.py", line 586, in<lambda>
>      DynamicEnabled=lambda:self.CurrentEditor.Modified, bmp="save",
> help=_("Save
> file"))
> AttributeError: 'NoneType' object has no attribute 'Modified'
> Traceback (most recent call last):
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dMenuIte
> m.py", line 58, in __onWxHit
>      self.raiseEvent(dEvents.Hit, evt)
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\ui\uiwx\dPemMixi
> n.py", line 1045, in raiseEvent
>      super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args,
> **kwargs)
>    File
> "C:\Python27\lib\site-packages\dabo-0.9.4-py2.7.egg\dabo\lib\eventMixin.p
> y", line 81, in raiseEvent
>      bindingFunction(event)
>    File "editor.py", line 770, in onFileOpen
>      fileNames = self.CurrentEditor.promptForFileName(prompt=_("Open"),
> AttributeError: 'NoneType' object has no attribute 'promptForFileName'
> ***************************
> I am getting tired of it.

This last error could be caused by something different. I don't know why 
CurrentEditor wouldn't have been defined, but if you could wrap up a summary of 
the 
changes you've made to the Dabo source code so far to get to this point, we 
could at 
least test those changes and get them into the framework. If you happen to have 
done 
the Subversion checkout of your Dabo Source then this will be easy:

cd dabo
svn diff > dabo_diff.txt

and then copy/paste dabo_diff.txt to an email to dabo-users.

Thanks
Paul


_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/[email protected]

Reply via email to