~toolpart/+junk/pythoncard

« back to all changes in this revision

Viewing changes to tools/standaloneBuilder/outputWindow.py

  • Committer: Bazaar Package Importer
  • Author(s): Sandro Tosi
  • Date: 2010-03-04 23:55:10 UTC
  • mfrom: (3.1.3 sid)
  • Revision ID: james.westby@ubuntu.com-20100304235510-3v6lbhzwrgm0pcca
Tags: 0.8.2-1
* QA upload.
* New upstream release
* debian/control
  - set maintainer to QA group
  - set Homepage field, removing the URL from packages description
  - bump versioned b-d-i on python-support, to properly support Python module
  - replace b-d on python-all-dev with python-all, since building only
    arch:all packages
  - replace Source-Version substvar with source:Version
  - add ${misc:Depends} to binary packages Depends
* debian/watch
  - updated to use the SourceForge redirector; thanks to Raphael Geissert for
    the report and to Dario Minnucci for the patch; Closes: #449904
* debian/{pythoncard-doc, python-pythoncard}.install
  - use wildcards instead of site-packages to fix build with python 2.6;
    thanks to Ilya Barygin for the report and patch; Closes: #572332
* debian/pythoncard-doc.doc-base
  - set section to Programmin/Python
* debian/pythoncard-tools.menu
  - set menu main section to Applications
* debian/pythoncard-tools.postinst
  - removed, needed only to update the menu, but it's now created by debhelper

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
#!/usr/bin/python
 
2
#
 
3
# projectmanager message output window
 
4
#
 
5
# This program is free software; you can redistribute it and/or modify
 
6
# it under the terms of the GNU General Public License as published by
 
7
# the Free Software Foundation; either version 2 of the License, or
 
8
# (at your option) any later version.
 
9
#
 
10
# This program is distributed in the hope that it will be useful,
 
11
# but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 
13
# GNU General Public License for more details.
 
14
#
 
15
# You should have received a copy of the GNU General Public License
 
16
# along with this program; if not, write to the Free Software
 
17
# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
 
18
#
 
19
# Copyright (C)2003 Phil Edwards, phil@linux2000.com
 
20
# vim: ts=4 sw=4 ai et
 
21
 
 
22
import string
 
23
import time
 
24
import sys
 
25
 
 
26
from PythonCard import model, dialog
 
27
import wx
 
28
 
 
29
class outputWindow(model.Background):
 
30
 
 
31
    def on_initialize(self, event):
 
32
        self.parent = self.GetParent()
 
33
        
 
34
    def clearLines(self):
 
35
        self.components.returnedText.text = ''
 
36
        self.components.importError.text = ''
 
37
        self.Refresh()
 
38
        wx.Yield()
 
39
        
 
40
    def addLine(self, text):
 
41
        if self.components.returnedText.enabled:
 
42
            self.components.returnedText.text += str(text)
 
43
        else:
 
44
            self.components.importError.text += str(text)
 
45
        #self.Refresh()
 
46
        #self.Update()
 
47
        #wx.Yield()
 
48
        
 
49
    def on_closeBtn_mouseClick(self, event):
 
50
        self.Hide()
 
51
        
 
52
    def on_close(self, event):
 
53
        self.Hide()
 
54
        
 
55
    def on_clipBoardBtn_mouseClick(self, event):
 
56
        if sys.platform.startswith('win'):
 
57
            stuff = wx.TextDataObject()
 
58
            stuff.SetText(self.components.clipBoardBtn.userdata)
 
59
            if wx.TheClipboard.Open():
 
60
                wx.TheClipboard.SetData(stuff)
 
61
                wx.TheClipboard.Close()
 
62
 
 
63
 
 
64
 
 
65
if __name__ == '__main__':
 
66
    app = model.PythonCardApp(outputWindow)
 
67
    app.MainLoop()