Make batch files for the tool scripts, and other related changes for
win32. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@16422 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
6b2cf8c9e1
commit
bd4b9c8c54
@ -139,7 +139,7 @@ other menu stuff.
|
||||
|
||||
Added wxIEHtmlWin. This is essentially the same as using IE with the
|
||||
ActiveXWrapper already in the library, but it is implemented all in
|
||||
C++ and therefore does not need any of the modules from win32 all and
|
||||
C++ and therefore does not need any of the modules from win32all and
|
||||
so it is less fragile in the face of changes.
|
||||
|
||||
Fixed the ActiveXWrapper problem. Looks like when the win32com
|
||||
@ -156,7 +156,9 @@ Changed the wxDateTime.Parse* methods to return an int that will be -1
|
||||
on failure, and the index where parsing stopped otherwise.
|
||||
|
||||
Moved tools to be a Python package in wxPython.tools, added scripts to
|
||||
import and launch each tool.
|
||||
import and launch each tool. This will let you import and use the
|
||||
tools in your own scripts or apps as needed.
|
||||
|
||||
|
||||
|
||||
|
||||
|
@ -7,9 +7,7 @@ files...
|
||||
"""
|
||||
|
||||
import sys, string
|
||||
sys.path.insert(0, "../tools")
|
||||
|
||||
import img2py
|
||||
from wxPython.tools import img2py
|
||||
|
||||
|
||||
command_lines = [
|
||||
|
@ -145,7 +145,12 @@ Source: "wxPython\tools\XRCed\*.xrc"; DestDir: "{app}\wxPython\tools\XRCed
|
||||
Source: "wxPython\tools\XRCed\*.ico"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
|
||||
Source: "wxPython\tools\XRCed\*.sh"; DestDir: "{app}\wxPython\tools\XRCed"; Components: tools
|
||||
|
||||
;; Where to put the scripts on Win32???
|
||||
Source: "scripts\*.bat"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
Source: "scripts\*.py"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
Source: "scripts\img2png"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
Source: "scripts\img2py"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
Source: "scripts\img2xpm"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
Source: "scripts\xrced"; DestDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
|
||||
Source: "samples\doodle\*.py"; DestDir: "{app}\wxPython\samples\doodle"; Components: samples
|
||||
Source: "samples\doodle\*.txt"; DestDir: "{app}\wxPython\samples\doodle"; Components: samples
|
||||
@ -178,6 +183,13 @@ Source: "samples\embedded\*.unx"; DestDir: "{app}\wxPython\samples\embe
|
||||
Source: "samples\embedded\*.ico"; DestDir: "{app}\wxPython\samples\embedded"; Components: samples
|
||||
Source: "samples\embedded\*.xpm"; DestDir: "{app}\wxPython\samples\embedded"; Components: samples
|
||||
|
||||
;;------------------------------------------------------------
|
||||
|
||||
[Run]
|
||||
;; Recreate the tool scripts to use the paths on the users machine
|
||||
Filename: "{code:GetPythonDir}\python.exe"; Parameters: "CreateBatchFiles.py"; WorkingDir: "{code:GetPythonDir}\Scripts"; Components: tools
|
||||
|
||||
|
||||
;;------------------------------------------------------------
|
||||
|
||||
[Icons]
|
||||
@ -206,6 +218,10 @@ Type: files; Name: "{app}\wxPython\lib\mixins\*.pyc";
|
||||
Type: files; Name: "{app}\wxPython\lib\mixins\*.pyo";
|
||||
Type: files; Name: "{app}\wxPython\lib\PyCrust\*.pyc";
|
||||
Type: files; Name: "{app}\wxPython\lib\PyCrust\*.pyo";
|
||||
Type: files; Name: "{app}\wxPython\tools\*.pyc";
|
||||
Type: files; Name: "{app}\wxPython\tools\*.pyo";
|
||||
Type: files; Name: "{app}\wxPython\tools\XRCed\*.pyc";
|
||||
Type: files; Name: "{app}\wxPython\tools\XRCed\*.pyo";
|
||||
Type: files; Name: "{app}\wxPython\demo\*.pyc";
|
||||
Type: files; Name: "{app}\wxPython\demo\*.pyo";
|
||||
Type: files; Name: "{app}\wxPython\demo\data\showTips";
|
||||
|
36
wxPython/scripts/CreateBatchFiles.py
Normal file
36
wxPython/scripts/CreateBatchFiles.py
Normal file
@ -0,0 +1,36 @@
|
||||
#----------------------------------------------------------------------
|
||||
# Name: CreateBatchFiles.py
|
||||
# Purpose: Run by the InnoSetup installer to create a DOS batch
|
||||
# file for each of the wxPython tool scripts.
|
||||
#
|
||||
# Author: Robin Dunn
|
||||
#
|
||||
# Created: 8-Aug-2002
|
||||
# Copyright: (c) 2002 by Total Control Software
|
||||
# Licence: wxWindows license
|
||||
#----------------------------------------------------------------------
|
||||
|
||||
import sys, os
|
||||
|
||||
python = sys.executable
|
||||
scriptdir = os.getcwd()
|
||||
|
||||
scripts = [ "img2png",
|
||||
"img2py",
|
||||
"img2xpm",
|
||||
"xrced",
|
||||
]
|
||||
|
||||
template = """\
|
||||
@echo off
|
||||
%(python)s %(scriptdir)s\\%(script)s %%1 %%2 %%3 %%4 %%5 %%6 %%7 %%8 %%9
|
||||
"""
|
||||
|
||||
for script in scripts:
|
||||
batfile = os.path.join(scriptdir, script + '.bat')
|
||||
print "Creating", batfile
|
||||
f = open(batfile, 'w')
|
||||
f.write(template % vars())
|
||||
f.close()
|
||||
|
||||
|
2
wxPython/scripts/img2png.bat
Executable file
2
wxPython/scripts/img2png.bat
Executable file
@ -0,0 +1,2 @@
|
||||
@echo off
|
||||
C:\TOOLS\PYTHON22\PYTHON.EXE C:\projects\wx\wxPython\scripts\img2png %1 %2 %3 %4 %5 %6 %7 %8 %9
|
2
wxPython/scripts/img2py.bat
Executable file
2
wxPython/scripts/img2py.bat
Executable file
@ -0,0 +1,2 @@
|
||||
@echo off
|
||||
C:\TOOLS\PYTHON22\PYTHON.EXE C:\projects\wx\wxPython\scripts\img2py %1 %2 %3 %4 %5 %6 %7 %8 %9
|
2
wxPython/scripts/img2xpm.bat
Executable file
2
wxPython/scripts/img2xpm.bat
Executable file
@ -0,0 +1,2 @@
|
||||
@echo off
|
||||
C:\TOOLS\PYTHON22\PYTHON.EXE C:\projects\wx\wxPython\scripts\img2xpm %1 %2 %3 %4 %5 %6 %7 %8 %9
|
2
wxPython/scripts/xrced.bat
Executable file
2
wxPython/scripts/xrced.bat
Executable file
@ -0,0 +1,2 @@
|
||||
@echo off
|
||||
C:\TOOLS\PYTHON22\PYTHON.EXE C:\projects\wx\wxPython\scripts\xrced %1 %2 %3 %4 %5 %6 %7 %8 %9
|
Loading…
Reference in New Issue
Block a user