summaryrefslogtreecommitdiffstats
path: root/Mac/Modules/ctl/ctlsupport.py
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1998-02-20 16:02:09 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1998-02-20 16:02:09 (GMT)
commit21f96872f20080d5f07a72ea4141fac137ac9b15 (patch)
tree5a300f0e769bddbc7795b7bc955f9f84f3bc1f2e /Mac/Modules/ctl/ctlsupport.py
parentcbe6a53d1ffe76702a2873429f2c57f9609a7f48 (diff)
downloadcpython-21f96872f20080d5f07a72ea4141fac137ac9b15.zip
cpython-21f96872f20080d5f07a72ea4141fac137ac9b15.tar.gz
cpython-21f96872f20080d5f07a72ea4141fac137ac9b15.tar.bz2
Regenerated from Universal Headers 3.0.1. Some new calls are
blacklisted, because they are not available in classic 68k programs, and bgen doesn't have a way to put #ifdef/#endif in the generated code. For now we only implement calls that work on all three models.
Diffstat (limited to 'Mac/Modules/ctl/ctlsupport.py')
-rw-r--r--Mac/Modules/ctl/ctlsupport.py36
1 files changed, 36 insertions, 0 deletions
diff --git a/Mac/Modules/ctl/ctlsupport.py b/Mac/Modules/ctl/ctlsupport.py
index 50efd94..a905970 100644
--- a/Mac/Modules/ctl/ctlsupport.py
+++ b/Mac/Modules/ctl/ctlsupport.py
@@ -33,6 +33,16 @@ CCTabHandle = OpaqueByValueType("CCTabHandle", "ResObj")
AuxCtlHandle = OpaqueByValueType("AuxCtlHandle", "ResObj")
ControlPartCode = Type("ControlPartCode", "h")
DragConstraint = Type("DragConstraint", "h")
+ControlVariant = Type("ControlVariant", "h")
+IconTransformType = Type("IconTransformType", "h")
+ControlButtonGraphicAlignment = Type("ControlButtonGraphicAlignment", "h")
+ControlButtonTextAlignment = Type("ControlButtonTextAlignment", "h")
+ControlButtonTextPlacement = Type("ControlButtonTextPlacement", "h")
+ControlContentType = Type("ControlContentType", "h")
+ControlFocusPart = Type("ControlFocusPart", "h")
+
+ControlFontStyleRec = OpaqueType('ControlFontStyleRec', 'ControlFontStyle')
+ControlFontStyleRec_ptr = ControlFontStyleRec
includestuff = includestuff + """
#include <%s>""" % MACHEADERFILE + """
@@ -40,10 +50,36 @@ includestuff = includestuff + """
#define resNotFound -192 /* Can't include <Errors.h> because of Python's "errors.h" */
extern PyObject *CtlObj_WhichControl(ControlHandle); /* Forward */
+extern PyObject *QdRGB_New(RGBColorPtr);
+extern QdRGB_Convert(PyObject *, RGBColorPtr);
#ifdef THINK_C
#define ControlActionUPP ProcPtr
#endif
+
+/*
+** Parse/generate ControlFontStyleRec records
+*/
+#if 0 /* Not needed */
+PyObject *ControlFontStyle_New(itself)
+ ControlFontStyleRec *itself;
+{
+
+ return Py_BuildValue("hhhhhhO&O&", itself->flags, itself->font,
+ itself->size, itself->style, itself->mode, itself->just,
+ QdRGB_New, &itself->foreColor, QdRGB_New, &itself->backColor);
+}
+#endif
+
+ControlFontStyle_Convert(v, itself)
+ PyObject *v;
+ ControlFontStyleRec *itself;
+{
+ return PyArg_ParseTuple(v, "hhhhhhO&O&", &itself->flags,
+ &itself->font, &itself->size, &itself->style, &itself->mode,
+ &itself->just, QdRGB_Convert, &itself->foreColor,
+ QdRGB_Convert, &itself->backColor);
+}
"""
finalstuff = finalstuff + """