summaryrefslogtreecommitdiffstats
path: root/Mac
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1996-04-12 16:29:23 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1996-04-12 16:29:23 (GMT)
commit46d9e79de61047ca4b1cc89aeded8a4b47972bf5 (patch)
treeeba59d4ffd410bdf18068b0f3161b2856f4b8498 /Mac
parent819fa1a794bf642da0b9bc6e345a784ab6bc3fa8 (diff)
downloadcpython-46d9e79de61047ca4b1cc89aeded8a4b47972bf5.zip
cpython-46d9e79de61047ca4b1cc89aeded8a4b47972bf5.tar.gz
cpython-46d9e79de61047ca4b1cc89aeded8a4b47972bf5.tar.bz2
bgen-generators now drop the python definition file straight in the
Lib:toolbox folder.
Diffstat (limited to 'Mac')
-rw-r--r--Mac/Modules/ae/AEmodule.c3
-rw-r--r--Mac/Modules/ae/aegen.py2
-rw-r--r--Mac/Modules/ae/aescan.py7
-rw-r--r--Mac/Modules/cm/Cmgen.py2
-rw-r--r--Mac/Modules/cm/Cmmodule.c3
-rw-r--r--Mac/Modules/cm/cmscan.py3
-rw-r--r--Mac/Modules/dlg/dlggen.py2
-rw-r--r--Mac/Modules/dlg/dlgscan.py3
-rw-r--r--Mac/Modules/evt/evtgen.py2
-rw-r--r--Mac/Modules/evt/evtscan.py3
-rw-r--r--Mac/Modules/fm/Fmgen.py2
-rw-r--r--Mac/Modules/fm/fmscan.py3
-rw-r--r--Mac/Modules/list/listgen.py2
-rw-r--r--Mac/Modules/list/listscan.py3
-rw-r--r--Mac/Modules/menu/menugen.py2
-rw-r--r--Mac/Modules/menu/menuscan.py3
-rw-r--r--Mac/Modules/qd/qdgen.py4
-rw-r--r--Mac/Modules/qd/qdscan.py5
-rw-r--r--Mac/Modules/qt/Qtmodule.c3
-rw-r--r--Mac/Modules/qt/qtgen.py2
-rw-r--r--Mac/Modules/qt/qtscan.py3
-rw-r--r--Mac/Modules/res/Resmodule.c3
-rw-r--r--Mac/Modules/res/resgen.py2
-rw-r--r--Mac/Modules/res/resscan.py3
-rw-r--r--Mac/Modules/snd/Sndmodule.c3
-rw-r--r--Mac/Modules/snd/sndgen.py2
-rw-r--r--Mac/Modules/snd/sndscan.py3
-rw-r--r--Mac/Modules/te/TEmodule.c26
-rw-r--r--Mac/Modules/te/tescan.py3
-rw-r--r--Mac/Modules/te/tesupport.py28
-rw-r--r--Mac/Modules/win/Winmodule.c3
-rw-r--r--Mac/Modules/win/wingen.py2
-rw-r--r--Mac/Modules/win/winscan.py3
33 files changed, 114 insertions, 29 deletions
diff --git a/Mac/Modules/ae/AEmodule.c b/Mac/Modules/ae/AEmodule.c
index e12c6c8..c479950 100644
--- a/Mac/Modules/ae/AEmodule.c
+++ b/Mac/Modules/ae/AEmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <AppleEvents.h>
diff --git a/Mac/Modules/ae/aegen.py b/Mac/Modules/ae/aegen.py
index 896eb78..d622cf8 100644
--- a/Mac/Modules/ae/aegen.py
+++ b/Mac/Modules/ae/aegen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:AppleEvents.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:AppleEvents.h'
f = AEFunction(OSErr, 'AECreateDesc',
(DescType, 'typeCode', InMode),
diff --git a/Mac/Modules/ae/aescan.py b/Mac/Modules/ae/aescan.py
index bc6cc58..4317195 100644
--- a/Mac/Modules/ae/aescan.py
+++ b/Mac/Modules/ae/aescan.py
@@ -10,6 +10,7 @@ import string
import regex
import regsub
import MacOS
+from bgenlocations import TOOLBOXDIR
from scantools import Scanner
@@ -17,7 +18,7 @@ def main():
print "=== Scanning AERegistry.h for defines ==="
input = "AERegistry.h"
output = "@dummy-registry.py"
- defsoutput = "AERegistry.py"
+ defsoutput = TOOLBOXDIR + "AERegistry.py"
scanner = AppleEventsScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
@@ -27,14 +28,14 @@ def main():
# once we start writing servers in python.
input = "AEObjects.h"
output = "@dummy-objects.py"
- defsoutput = "AEObjects.py"
+ defsoutput = TOOLBOXDIR + "AEObjects.py"
scanner = AppleEventsScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
print "=== Scanning AppleEvents.py ==="
input = "AppleEvents.h"
output = "aegen.py"
- defsoutput = "AppleEvents.py"
+ defsoutput = TOOLBOXDIR + "AppleEvents.py"
scanner = AppleEventsScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/cm/Cmgen.py b/Mac/Modules/cm/Cmgen.py
index f3b8991..5edeb24 100644
--- a/Mac/Modules/cm/Cmgen.py
+++ b/Mac/Modules/cm/Cmgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Components.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Components.h'
f = Function(Component, 'RegisterComponentResource',
(ComponentResourceHandle, 'tr', InMode),
diff --git a/Mac/Modules/cm/Cmmodule.c b/Mac/Modules/cm/Cmmodule.c
index fd8b331..372fb56 100644
--- a/Mac/Modules/cm/Cmmodule.c
+++ b/Mac/Modules/cm/Cmmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <Components.h>
diff --git a/Mac/Modules/cm/cmscan.py b/Mac/Modules/cm/cmscan.py
index d568a73..95abeed 100644
--- a/Mac/Modules/cm/cmscan.py
+++ b/Mac/Modules/cm/cmscan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "Components"
SHORT = "Cm"
@@ -10,7 +11,7 @@ SHORT = "Cm"
def main():
input = "Components.h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/dlg/dlggen.py b/Mac/Modules/dlg/dlggen.py
index b3f08ae..7eb9728 100644
--- a/Mac/Modules/dlg/dlggen.py
+++ b/Mac/Modules/dlg/dlggen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Dialogs.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Dialogs.h'
f = Function(DialogRef, 'NewDialog',
(NullStorage, 'wStorage', InMode),
diff --git a/Mac/Modules/dlg/dlgscan.py b/Mac/Modules/dlg/dlgscan.py
index b56edfd..31c88dd 100644
--- a/Mac/Modules/dlg/dlgscan.py
+++ b/Mac/Modules/dlg/dlgscan.py
@@ -4,6 +4,7 @@ import addpack
addpack.addpack(':Tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "Dialogs"
SHORT = "dlg"
@@ -12,7 +13,7 @@ OBJECT = "DialogPtr"
def main():
input = LONG + ".h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/evt/evtgen.py b/Mac/Modules/evt/evtgen.py
index 29f78d0..afffb10 100644
--- a/Mac/Modules/evt/evtgen.py
+++ b/Mac/Modules/evt/evtgen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Events.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Events.h'
f = Function(UInt32, 'GetCaretTime',
)
diff --git a/Mac/Modules/evt/evtscan.py b/Mac/Modules/evt/evtscan.py
index dc3b6ce..676c839 100644
--- a/Mac/Modules/evt/evtscan.py
+++ b/Mac/Modules/evt/evtscan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "Events"
SHORT = "evt"
@@ -11,7 +12,7 @@ OBJECT = "NOTUSED"
def main():
input = LONG + ".h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/fm/Fmgen.py b/Mac/Modules/fm/Fmgen.py
index 9f3f89c..194d034 100644
--- a/Mac/Modules/fm/Fmgen.py
+++ b/Mac/Modules/fm/Fmgen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Fonts.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Fonts.h'
f = Function(void, 'InitFonts',
)
diff --git a/Mac/Modules/fm/fmscan.py b/Mac/Modules/fm/fmscan.py
index adbb3dc..1a5d6a8 100644
--- a/Mac/Modules/fm/fmscan.py
+++ b/Mac/Modules/fm/fmscan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "Fonts"
SHORT = "Fm"
@@ -10,7 +11,7 @@ SHORT = "Fm"
def main():
input = "Fonts.h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/list/listgen.py b/Mac/Modules/list/listgen.py
index 85e0485..f6b8d86 100644
--- a/Mac/Modules/list/listgen.py
+++ b/Mac/Modules/list/listgen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Lists.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Lists.h'
f = Function(ListRef, 'LNew',
(Rect_ptr, 'rView', InMode),
diff --git a/Mac/Modules/list/listscan.py b/Mac/Modules/list/listscan.py
index 8061b56..ea11ba4 100644
--- a/Mac/Modules/list/listscan.py
+++ b/Mac/Modules/list/listscan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "Lists"
SHORT = "list"
@@ -11,7 +12,7 @@ OBJECT = "ListRef"
def main():
input = LONG + ".h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/menu/menugen.py b/Mac/Modules/menu/menugen.py
index b5a60ce..425003b 100644
--- a/Mac/Modules/menu/menugen.py
+++ b/Mac/Modules/menu/menugen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Menus.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Menus.h'
f = Function(short, 'GetMBarHeight',
)
diff --git a/Mac/Modules/menu/menuscan.py b/Mac/Modules/menu/menuscan.py
index 08a6a04..cf00dcc 100644
--- a/Mac/Modules/menu/menuscan.py
+++ b/Mac/Modules/menu/menuscan.py
@@ -3,11 +3,12 @@ import addpack
addpack.addpack(':Tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
def main():
input = "Menus.h"
output = "menugen.py"
- defsoutput = "Menus.py"
+ defsoutput = TOOLBOXDIR + "Menus.py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/qd/qdgen.py b/Mac/Modules/qd/qdgen.py
index 4df58f7..83f427f 100644
--- a/Mac/Modules/qd/qdgen.py
+++ b/Mac/Modules/qd/qdgen.py
@@ -1,4 +1,4 @@
-# Generated from 'flap:CodeWarrior:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:QuickDraw.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:QuickDraw.h'
f = Function(void, 'SetPort',
(GrafPtr, 'port', InMode),
@@ -926,7 +926,7 @@ f = Function(void, 'GetIndPattern',
)
functions.append(f)
-# Generated from 'flap:CodeWarrior:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:QuickDrawText.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:QuickDrawText.h'
f = Function(void, 'TextFont',
(short, 'font', InMode),
diff --git a/Mac/Modules/qd/qdscan.py b/Mac/Modules/qd/qdscan.py
index fd654f3..4155df0 100644
--- a/Mac/Modules/qd/qdscan.py
+++ b/Mac/Modules/qd/qdscan.py
@@ -4,11 +4,12 @@ import addpack
addpack.addpack(':Tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
def main():
input = "QuickDraw.h"
output = "qdgen.py"
- defsoutput = "QuickDraw.py"
+ defsoutput = TOOLBOXDIR + "QuickDraw.py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
@@ -33,7 +34,7 @@ def main():
ifp.close()
ofp.close()
ifp = open("@QuickDrawText.py")
- ofp = open("QuickDraw.py", "a")
+ ofp = open(TOOLBOXDIR + "QuickDraw.py", "a")
ofp.write(ifp.read())
ifp.close()
ofp.close()
diff --git a/Mac/Modules/qt/Qtmodule.c b/Mac/Modules/qt/Qtmodule.c
index ffba461..b53f133 100644
--- a/Mac/Modules/qt/Qtmodule.c
+++ b/Mac/Modules/qt/Qtmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <Movies.h>
diff --git a/Mac/Modules/qt/qtgen.py b/Mac/Modules/qt/qtgen.py
index b10312e..03b29e7 100644
--- a/Mac/Modules/qt/qtgen.py
+++ b/Mac/Modules/qt/qtgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Movies.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Movies.h'
f = Function(OSErr, 'EnterMovies',
)
diff --git a/Mac/Modules/qt/qtscan.py b/Mac/Modules/qt/qtscan.py
index 020c487..7fba936 100644
--- a/Mac/Modules/qt/qtscan.py
+++ b/Mac/Modules/qt/qtscan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "QuickTime"
SHORT = "qt"
@@ -11,7 +12,7 @@ OBJECTS = ("Movie", "Track", "Media", "UserData", "TimeBase", "MovieController")
def main():
input = "Movies.h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/res/Resmodule.c b/Mac/Modules/res/Resmodule.c
index 1e3e912..4ee935c 100644
--- a/Mac/Modules/res/Resmodule.c
+++ b/Mac/Modules/res/Resmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <Resources.h>
diff --git a/Mac/Modules/res/resgen.py b/Mac/Modules/res/resgen.py
index fe267da..6b6c365 100644
--- a/Mac/Modules/res/resgen.py
+++ b/Mac/Modules/res/resgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Resources.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Resources.h'
f = ResFunction(short, 'InitResources',
)
diff --git a/Mac/Modules/res/resscan.py b/Mac/Modules/res/resscan.py
index 9420a03..eff0005 100644
--- a/Mac/Modules/res/resscan.py
+++ b/Mac/Modules/res/resscan.py
@@ -10,13 +10,14 @@ import regsub
import MacOS
import addpack
addpack.addpack(':Tools:bgen:bgen')
+from bgenlocations import TOOLBOXDIR
from scantools import Scanner
def main():
input = "Resources.h"
output = "resgen.py"
- defsoutput = "Resources.py"
+ defsoutput = TOOLBOXDIR + "Resources.py"
scanner = ResourcesScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/snd/Sndmodule.c b/Mac/Modules/snd/Sndmodule.c
index 866ce75..ba87d0c 100644
--- a/Mac/Modules/snd/Sndmodule.c
+++ b/Mac/Modules/snd/Sndmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <Sound.h>
diff --git a/Mac/Modules/snd/sndgen.py b/Mac/Modules/snd/sndgen.py
index 323f637..c984e0c 100644
--- a/Mac/Modules/snd/sndgen.py
+++ b/Mac/Modules/snd/sndgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Sound.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Sound.h'
f = SndFunction(void, 'SetSoundVol',
(short, 'level', InMode),
diff --git a/Mac/Modules/snd/sndscan.py b/Mac/Modules/snd/sndscan.py
index f28c48e..8db540a 100644
--- a/Mac/Modules/snd/sndscan.py
+++ b/Mac/Modules/snd/sndscan.py
@@ -4,13 +4,14 @@
import addpack
addpack.addpack(':Tools:bgen:bgen')
+from bgenlocations import TOOLBOXDIR
from scantools import Scanner
def main():
input = "Sound.h"
output = "sndgen.py"
- defsoutput = "Sound.py"
+ defsoutput = TOOLBOXDIR + "Sound.py"
scanner = SoundScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/te/TEmodule.c b/Mac/Modules/te/TEmodule.c
index 5b54822..9d14b09 100644
--- a/Mac/Modules/te/TEmodule.c
+++ b/Mac/Modules/te/TEmodule.c
@@ -805,6 +805,32 @@ static PyObject *TEObj_getattr(self, name)
TEObject *self;
char *name;
{
+
+ if( strcmp(name, "destRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->destRect);
+ if( strcmp(name, "viewRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->viewRect);
+ if( strcmp(name, "selRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->selRect);
+ if( strcmp(name, "lineHeight") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->lineHeight);
+ if( strcmp(name, "fontAscent") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->fontAscent);
+ if( strcmp(name, "selPoint") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildPoint,
+ (*self->ob_itself)->selPoint);
+ if( strcmp(name, "selStart") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->selStart);
+ if( strcmp(name, "selEnd") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->selEnd);
+ if( strcmp(name, "active") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->active);
+ if( strcmp(name, "teLength") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->teLength);
+
return Py_FindMethodInChain(&TEObj_chain, (PyObject *)self, name);
}
diff --git a/Mac/Modules/te/tescan.py b/Mac/Modules/te/tescan.py
index e7bb74b..8d919e8 100644
--- a/Mac/Modules/te/tescan.py
+++ b/Mac/Modules/te/tescan.py
@@ -3,6 +3,7 @@
import addpack
addpack.addpack(':tools:bgen:bgen')
from scantools import Scanner
+from bgenlocations import TOOLBOXDIR
LONG = "TextEdit"
SHORT = "te"
@@ -11,7 +12,7 @@ OBJECT = "TEHandle"
def main():
input = LONG + ".h"
output = SHORT + "gen.py"
- defsoutput = LONG + ".py"
+ defsoutput = TOOLBOXDIR + LONG + ".py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()
diff --git a/Mac/Modules/te/tesupport.py b/Mac/Modules/te/tesupport.py
index eda089c..daadea0 100644
--- a/Mac/Modules/te/tesupport.py
+++ b/Mac/Modules/te/tesupport.py
@@ -86,6 +86,34 @@ class MyObjectDefinition(GlobalObjectDefinition):
}""")
def outputFreeIt(self, itselfname):
Output("TEDispose(%s);", itselfname)
+
+ def outputGetattrHook(self):
+ Output("""
+ if( strcmp(name, "destRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->destRect);
+ if( strcmp(name, "viewRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->viewRect);
+ if( strcmp(name, "selRect") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildRect,
+ (*self->ob_itself)->selRect);
+ if( strcmp(name, "lineHeight") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->lineHeight);
+ if( strcmp(name, "fontAscent") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->fontAscent);
+ if( strcmp(name, "selPoint") == 0 )
+ return Py_BuildValue("O&", PyMac_BuildPoint,
+ (*self->ob_itself)->selPoint);
+ if( strcmp(name, "selStart") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->selStart);
+ if( strcmp(name, "selEnd") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->selEnd);
+ if( strcmp(name, "active") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->active);
+ if( strcmp(name, "teLength") == 0 )
+ return Py_BuildValue("h", (*self->ob_itself)->teLength);
+ """)
# From here on it's basically all boiler plate...
diff --git a/Mac/Modules/win/Winmodule.c b/Mac/Modules/win/Winmodule.c
index afac85f..cfa23c7 100644
--- a/Mac/Modules/win/Winmodule.c
+++ b/Mac/Modules/win/Winmodule.c
@@ -40,6 +40,9 @@ extern int GrafObj_Convert(PyObject *, GrafPtr *);
extern PyObject *BMObj_New(BitMapPtr);
extern int BMObj_Convert(PyObject *, BitMapPtr *);
+extern PyObject *PMObj_New(PixMapHandle);
+extern int PMObj_Convert(PyObject *, PixMapHandle *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
#include <Windows.h>
diff --git a/Mac/Modules/win/wingen.py b/Mac/Modules/win/wingen.py
index 8841b1e..36d2851 100644
--- a/Mac/Modules/win/wingen.py
+++ b/Mac/Modules/win/wingen.py
@@ -1,4 +1,4 @@
-# Generated from 'Sap:CodeWarrior7:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Windows.h'
+# Generated from 'Sap:CW8 Gold:Metrowerks CodeWarrior:MacOS Support:Headers:Universal Headers:Windows.h'
f = Function(RgnHandle, 'GetGrayRgn',
)
diff --git a/Mac/Modules/win/winscan.py b/Mac/Modules/win/winscan.py
index 20771b0..2d332ad 100644
--- a/Mac/Modules/win/winscan.py
+++ b/Mac/Modules/win/winscan.py
@@ -1,13 +1,14 @@
# Scan an Apple header file, generating a Python file of generator calls.
import addpack
addpack.addpack(':Tools:bgen:bgen')
+from bgenlocations import TOOLBOXDIR
from scantools import Scanner
def main():
input = "Windows.h"
output = "wingen.py"
- defsoutput = "Windows.py"
+ defsoutput = TOOLBOXDIR + "Windows.py"
scanner = MyScanner(input, output, defsoutput)
scanner.scan()
scanner.close()