Commits

Ronald Oussoren  committed d215c19

- Documentation updates
- Some more work on adding helper functions for difficult methods
- AddressBook/__init__.py now imports AppKit, this is needed to correctly
load the AppKit helper functions and definitions. I've also added an item
to the TODO list for this, it should be fixed in a less fragile way.

  • Participants
  • Parent commits aa0f044
  • Branches pyobjc-ancient

Comments (0)

Files changed (17)

 
 The test suite needs to be enhanced.
 
-* tests for ``pyobjc_instanceMethods``, ``pyobjc_classMethods``
-
 * tests for all functions in ``Modules/*/*Mapping*.m``
 
 
 Design and implement a set of performance tests for the bridge. Use this to 
 invistigate and fix any possible performance problems.
 
+Robustness
+..........
+
+Make core bridge more robust w.r.t. order of loading frameworks. You currently
+get incorrect wrappers if you manually load the AppKit.framework and then 
+import AppKit.

File Doc/api-notes-macosx.txt

 
 		mysheetDidEnd = NSEndSheetMethod(mysheetDidEnd)
 
+
+Class NSApplication
+...................
+
+``NSModalSession`` objects are wrapped as opaque values. You can check if
+two wrapper objects refer to the same session object by comparing their
+``ptr`` attributes.
+
 Class NSBezierPath
 ..................
 
 * ``setAssociatedPoints:atIndex:``
   Implementing this method in Python is not yet supported.
 
+Class ``NSBitmapImageRep``
+..........................
+
+* ``getBitMapDataPlanes``
+  This method is not supported (yet)
+
+* ``getTIFFCompressionTypes:count:``
+  This method is not supported (yet)
+
+* ``initWithBitmapDataPlanes:pixesWide:pixelsHigh:bitPerSample:samplesPerPixel:hasAlpha:isPlanar:colorSpaceName:bytesPerRow:bitsPerPixel:``
+  This method is not supported (yet)
+
+Class ``NSFont``
+................
+
+* ``positionsForCompositeSequence:numberOfGlyphs:pointArray:``
+  This method is not supported (yet)
+
+
 Class ``NSGraphicsContext``
 ...........................
 
 * ``graphicsPort``
   This method is not yet supported.
 
+Class ``NSLayoutManager``
+.........................
+
+* ``getGlyphs:range:``
+  This method is not yet supported
+
+* ``getGlyphsInRange:glyphs:characterIndexes:glyphInscriptions:elasticBits:``
+  This method is not yet supported
+
+* ``getGlyphsInRange:glyphs:characterIndexes:glyphInscriptions:elasticBits:bidiLevels:``
+  This method is not yet supported
+
+* ``rectArrayForCharacterRange:withinSelectedCharacterRange:inTextContainer:rectCount:``
+  This method is not yet supported
+
+* ``rectArrayForGlyphRange:withinSelectedGlyphRange:inTextContainer:rectCount:``
+  This method is not yet supported
+
 Class ``NSMatrix``
 ..................
 
   Calling this method from Python is supported, overriding it in Python
   is not. The ``context`` can be an arbitrary python object.
 
+Class ``NSMovie``
+.................
+
+The return value of ``QTMovie`` and the sole argument of ``initWithMovie:``
+are QT.Movie objects. Using these methods requires the use of MacPython 2.3.
+
+Class ``NSOpenGLContext``
+.........................
+
+* ``getValues:forParameter:``
+  This method is not yet supported.
+
+* ``setValues:forParameter:``
+  This method is not yet supported.
+
+* ``setOffScreen:width:height:rowbytes:``
+  This method is not yet supported.
+
+Class ``NSOpenGLPixelFormat``
+.............................
+
+* ``getValues:forAttribute:forVirtualScreen:``
+  This method is not yet supported
+
+* ``initWithAttributes:``
+  This method is not yet supported
+
+Class ``NSQuickDrawView``
+.........................
+
+* ``qdPort``
+  This method is not yet supported and will return a MacPython wrapper for
+  a QuickDraw port in the future.
+
+Class ``NSSimpleHorizontalTypesetter``
+......................................
+
+* ``baseOfTypesetterGlyphInfo``
+  This method is not yet supported
+
+* ``layoutGlyphsInHorizontalLineFragment:baseline:``
+  This method is not yet supported
+
+
 Class ``NSView``
+................
 
 * ``sortSubviewsUsingFunction:context:``
   Calling this method from Python is supported, overriding it in Python
   is not. The ``context`` can be an arbitrary python object.
 
+Class ``NSWindow``
+..................
+
+* ``graphicsPort``
+  This method is not yet supported
+
+* ``initWithWindowRef:``
+  This method is not yet supported
+
+* ``windowRef``
+  This method is not yet supported
+
 Foundation framework
 --------------------
 
   This method is not supported, use ``initWithArray:`` instead.
 
 
-Class NSString
-..............
+Class ``NSString``
+..................
 
 Objective-C strings are usually represented as instances of a subclass of
 the Python type ``unicode``. It is possible to access the "real" Objective-C
 
 Please let me know if there is documentation for this framework.
 
-Class IBObjCSourceParser
-........................
+Class ``IBObjCSourceParser``
+............................
 
 * ``parseClass:``
 
-Class NSView
-............
+Class ``NSView``
+................
+
 * ``objectAtPoint:rect:``
   Defined in a catagory on ``NSView``.
 

File Doc/wrapping.txt

 If your class library does not require helper functions for some methods this
 is all that is needed.
 
+Don't forget to import the frameworks that are used by your framework before
+calling ``objc.loadBundle``. This is necessary to arrange for the helper code
+for these modules (if there is any) to be loaded.
 
 Wrapping global functions and constants
 ---------------------------------------
 future.
 
 NOTE: It is likely that there will be changes w.r.t. the special wrappers.
+
+protocols
+.........
+
+If the framework defines any (informal) protocols you should add 
+``objc.informal_protocol`` objects for those protocols to your module. These
+can be defined in a submodule, as long as you arrange for that module to be
+loaded whenever someone imports your package.

File Examples/rendezvous.py

+#!/usr/bin/env python
+"""
+This script using NSNetServiceBrowser to look for local HTTP servers.
+"""
+
+import objc
+from Foundation import *
+
+class PrintingResolverDelegate(NSObject):
+    def netServiceDidResolveAddress_(self, service):
+        addresses = service.addresses()
+        if len(addresses) == 0:
+            return
+        print "%s.%s" % (service.name(), service.domain())
+        for address in service.addresses():
+            print "   %s"%(address,)
+        print ""
+
+    def netService_didNotResolve_(self, didNotResolve):
+        print "didNotResolve",didNotResolve
+
+class PrintingBrowserDelegate(NSObject):
+    def startLookup(self):
+        for aNetService in self.services:
+            prd = PrintingResolverDelegate.new()
+            aNetService.setDelegate_(prd)
+            aNetService.resolve()
+        
+    def netServiceBrowserWillSearch_(self, browser):
+        print "Browsing for advertised services..."
+        self.services = []
+
+    def netServiceBrowserDidStopSearch_(self, browser):
+        print "Browse complete"
+        self.startLookup()
+
+    def netServiceBrowser_didNotSearch_(self, browser, errorDict):
+        print "Could not search."
+
+    def netServiceBrowser_didFindService_moreComing_(self, browser, aNetService, moreComing):
+        print "Found a service: %s %s"%(aNetService.name(), aNetService.domain())
+        self.services.append(aNetService)
+        if not moreComing:
+            browser.stop()
+
+    def netServiceBrowser_didRemoveService_moreComing_(self, browser, aNetService, moreComing):
+        print "Service removed: %s"%(aNetService.name(),)
+        if not moreComing:
+            browser.stop()
+
+def findDomains(serviceName, seconds=5.0):
+    runloop = NSRunLoop.currentRunLoop()
+    browser = NSNetServiceBrowser.new()
+    pbd = PrintingBrowserDelegate.new()
+    browser.setDelegate_(pbd)
+    browser.searchForServicesOfType_inDomain_(serviceName, "")
+    untilWhen = NSDate.dateWithTimeIntervalSinceNow_(seconds)
+    runloop.runUntilDate_(untilWhen)
+
+if __name__ == '__main__':
+    # Use '_afpovertcp' instead of '_http' to look for fileservers.
+    findDomains("_http._tcp")
 
 .. _`the PyObjC download site`: http://sourceforge.net/project/showfiles.php?group_id=14534
 
-
 PyObjC is build and installed using the distutils package included with Python
 2.0 and beyond.  This package provides a single interface for building and
 packaging the module.   To see usage documentation for the module,
   % cd TableModel
   % python buildapp.py build
 
-The WebServicesTool and TableModel2 are both examples of Cocoa-Python
-applications created via the Cocoa-Python project template found in
-the ``Project Templates`` directory.  Use Project Builder to build the
-applications.
+The WebServicesTool is an example of Cocoa-Python applications created via 
+the Cocoa-Python project template found in the 
+``ProjectBuilder Extras/Project Templates`` directory.  Use Project Builder 
+to build the applications.
 
 Project Templates
 =================
 
+The ``ProjectBuilder Extras`` directory contains additional files that can
+be used with Project Builder. The diretory ``Specifications`` contains files
+that enable syntax coloring for Python files in Project Builder.
+
 The ``Project Templates`` directory contains project templates for
-project builder.  These have to be copied to
+Project Builder.  These have to be copied to
 ``/Developer/ProjectBuilder Extras/Project Templates/Application`` before
 they are useable from Project Builder.
 

File Lib/AddressBook/__init__.py

 # Load the AddressBook bundle, and gather all classes defined there
 import objc
 
+# AddressBook.framework has a dependency on AppKit.framework. Make sure we
+# load AppKit ourselfes, otherwise we might not load the custom wrappers for it.
+import AppKit
+del AppKit
+
 objc.loadBundle("AddressBook", globals(), bundle_path="/System/Library/Frameworks/AddressBook.framework")
 
 from _AddressBook import *

File Lib/AppKit/AppKit.byref

 ,NSFont,positionOfGlyph:precededByGlyph:isNominal:,{_NSPoint=ff}0@8:12I16I20^c24,{_NSPoint=ff}@:IIo^c
 ,NSFont,positionOfGlyph:struckOverGlyph:metricsExist:,{_NSPoint=ff}0@8:12I16I20^c24,{_NSPoint=ff}@:IIo^c
 ,NSFont,positionOfGlyph:struckOverRect:metricsExist:,{_NSPoint=ff}36@8:12I16{_NSRect={_NSPoint=ff}{_NSSize=ff}}20^c32,{_NSPoint=ff}@:I{_NSRect={_NSPoint=ff}{_NSSize=ff}}o^c
-,NSFont,positionOfGlyph:withRelation:toBaseGlyph:totalAdvancement:metricsExist:,{_NSPoint=ff}0@8:12I16i20I24^{_NSSize=ff}28^c32,{_NSPoint=ff}@:IiI^{_NSSize=ff}o^c
+,NSFont,positionOfGlyph:withRelation:toBaseGlyph:totalAdvancement:metricsExist:,{_NSPoint=ff}0@8:12I16i20I24^{_NSSize=ff}28^c32,{_NSPoint=ff}@:IiIo^{_NSSize=ff}o^c
 ,NSFont,positionsForCompositeSequence:numberOfGlyphs:pointArray:,i0@4:8^I12i16^{_NSPoint=ff}20,
 ,NSTextView,getMarkedText:selectedRange:,v0@4:8^@12^{_NSRange=II}16,
 ,NSColorPickerWheelView,_pointInPicker:,c0@4:8^{_NSPoint=ff}12,

File Lib/AppKit/_AppKitSignatures.py

 set_signature_for_selector("NSFont", "positionOfGlyph:precededByGlyph:isNominal:", "{_NSPoint=ff}@:IIo^c")
 set_signature_for_selector("NSFont", "positionOfGlyph:struckOverGlyph:metricsExist:", "{_NSPoint=ff}@:IIo^c")
 set_signature_for_selector("NSFont", "positionOfGlyph:struckOverRect:metricsExist:", "{_NSPoint=ff}@:I{_NSRect={_NSPoint=ff}{_NSSize=ff}}o^c")
-set_signature_for_selector("NSFont", "positionOfGlyph:withRelation:toBaseGlyph:totalAdvancement:metricsExist:", "{_NSPoint=ff}@:IiI^{_NSSize=ff}o^c")
+set_signature_for_selector("NSFont", "positionOfGlyph:withRelation:toBaseGlyph:totalAdvancement:metricsExist:", "{_NSPoint=ff}@:IiIo^{_NSSize=ff}o^c")
 set_signature_for_selector("NSWorkspace", "getFileSystemInfoForPath:isRemovable:isWritable:isUnmountable:description:type:", "c28@4:8@12o^c16o^c20o^c24o^@28o^@32")
 set_signature_for_selector("NSWorkspace", "getInfoForFile:application:type:", "c16@4:8@12o^@16o^@20")
 set_signature_for_selector("NSWorkspace", "performFileOperation:source:destination:files:tag:", "c@:@@@@o^i")

File Lib/InterfaceBuilder/__init__.py

 # Load the AddressBook bundle, and gather all classes defined there
 import objc 
 
+import AppKit
+del AppKit
+
 objc.loadBundle("InterfaceBuilder", globals(), bundle_path="/System/Library/Frameworks/InterfaceBuilder.framework")
 
 del objc

File Lib/PreferencePanes/__init__.py

 documentation for details on how to use these functions and classes.
 """
 
-# Load the AddressBook bundle, and gather all classes defined there
+# Load the PreferencePanes bundle, and gather all classes defined there
 import objc 
 
+import AppKit
+del AppKit
+
 objc.loadBundle("PreferencePanes", globals(), bundle_path="/System/Library/Frameworks/PreferencePanes.framework")
 
 del objc

File Lib/ScreenSaver/__init__.py

 # Load the ScreenSaver framework, and gather all classes defined there
 import objc
 
+import AppKit
+del AppKit
+
 # Custom method signature (undocumented class, this is a guess)
 objc.set_signature_for_selector("ScreenSaverUserInfo", "loginUserName:andID:", "v@:o^@o^I")
 

File Modules/AppKit/_AppKitMapping_NSFont.m

 /*
- * NSFont mappings for difficult methods:
+ * NSFont mappings for 'difficult' methods:
  *
- * TODO:
- * -positionsForCompositeSequence:numberOfGlyphs:pointArray:
+ * -positionsForCompositeSequence:numberOfGlyphs:pointArray:    [call, imp]
  */
 #include <Python.h>
 #include <Foundation/Foundation.h>
 #include "pyobjc-api.h"
 
+static PyObject*
+call_NSFont_positionsForCompositeSequence_numberOfGlyphs_pointArray_(
+	PyObject* method, PyObject* self, PyObject* arguments)
+{
+	PyObject* result;
+	struct objc_super super;
+	int numGlyphs;
+	PyObject* glyphList;
+	PyObject* seq;
+	NSGlyph* glyphs;
+	NSPoint* points;
+	int i, len;
+
+	if (PyArg_ParseTuple(arguments, "Oi", &glyphList, &numGlyphs) < 0) {
+		return 0;
+	}
+
+	seq = PySequence_Fast(glyphList, "glyphList is not a sequence");
+	if (seq == NULL) {
+		return NULL;
+	}
+	
+	len = PySequence_Fast_GET_SIZE(seq);
+	if (len < numGlyphs) {
+		PyErr_SetString(PyExc_ValueError, "Too few glyphs");
+		Py_DECREF(seq);
+		return NULL;
+	}
+
+	glyphs = malloc(sizeof(NSGlyph));
+	if (glyphs == NULL) {
+		Py_DECREF(seq);
+		return NULL;
+	}
+
+	points = malloc(sizeof(NSPoint));
+	if (glyphs == NULL) {
+		free(glyphs);
+		Py_DECREF(seq);
+		return NULL;
+	}
+
+	for (i = 0; i < len; i++) {
+		int r;
+
+		r = PyObjC_PythonToObjC(@encode(NSGlyph), 
+			PySequence_Fast_GET_ITEM(seq, i),
+			glyphs + i);
+		if (r == -1) {
+			free(glyphs);
+			Py_DECREF(seq);
+			return NULL;
+		}
+	}
+	Py_DECREF(seq);
+
+	NS_DURING
+		PyObjC_InitSuper(&super,
+			PyObjCSelector_GetClass(method),
+			PyObjCObject_GetObject(self));
+
+		len = (int)objc_msgSendSuper(&super,
+			@selector(positionsForCompositeSequence:numberOfGlyphs:pointArray:),
+			glyphs, numGlyphs, points);
+	NS_HANDLER
+		PyObjCErr_FromObjC(localException);
+		len = -1;
+	NS_ENDHANDLER
+
+	if (len == -1 && PyErr_Occurred()) {
+		free(points);
+		free(glyphs);
+		return NULL;
+	}
+
+	free(glyphs);
+
+	seq = PyTuple_New(len > 0? len: 0);
+	if (seq == NULL) {
+		free(points);
+		return NULL;
+	}
+
+	for (i = 0; i < len; i++) {
+		PyObject* v;
+
+		v = PyObjC_ObjCToPython(@encode(NSPoint), points + i);
+		if (v == NULL) {
+			free(points);
+			return NULL;
+		}
+
+		PyTuple_SET_ITEM(seq, i, v);
+	}
+	free(points);
+
+	result = Py_BuildValue("(iO)", len, seq);
+	Py_DECREF(seq);
+
+	return result;
+}
+
+static int
+imp_NSFont_positionsForCompositeSequence_numberOfGlyphs_pointArray_(
+	id self, SEL sel, NSGlyph* glyphs, int numGlyphs, NSPoint* points)
+{
+	PyObject* args;
+	PyObject* result;
+	PyObject* seq;
+	PyObject* v;
+	int i;
+	int retValue;
+
+	args = PyTuple_New(3);
+	if (args == NULL) {
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+	
+	v = PyObjC_IdToPython(self);
+	if (v == NULL) {
+		Py_DECREF(args);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	PyTuple_SET_ITEM(args, 0, v);
+
+	v = PyTuple_New(numGlyphs);
+	if (v == NULL) {
+		Py_DECREF(args);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+	PyTuple_SET_ITEM(args, 1, v);
+
+	for (i = 0; i < numGlyphs; i++) {
+		PyObject* t;
+
+		t = PyObjC_ObjCToPython(@encode(NSGlyph), glyphs + i);
+		if (t == NULL) {
+			Py_DECREF(args);
+			PyObjCErr_ToObjC();
+			return -1;
+		}
+		PyTuple_SET_ITEM(v, i, t);
+	}
+
+	v = PyInt_FromLong(numGlyphs);
+	if (v == NULL) {
+		Py_DECREF(args);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	PyTuple_SET_ITEM(args, 2, v);
+
+	result = PyObjC_CallPython(self, sel, args);
+	Py_DECREF(args);
+	if (result == NULL) {
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	if (!PyTuple_Check(result)) {
+		PyErr_SetString(PyExc_TypeError, 
+			"Should return tuple (numPoints, points)");
+		Py_DECREF(result);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	if (PyObjC_PythonToObjC(
+		@encode(int), PyTuple_GET_ITEM(result, 0), &retValue) < 0) {
+		Py_DECREF(result);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	seq = PySequence_Fast(PyTuple_GET_ITEM(result, 1),
+		"Should return tuple (numPoints, points)");
+	if (seq == NULL) {
+		Py_DECREF(result);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	if (PySequence_Fast_GET_SIZE(seq) < retValue) {
+		PyErr_SetString(PyExc_ValueError, "Too few points returned");
+		Py_DECREF(result);
+		Py_DECREF(seq);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+	if (retValue > numGlyphs) {
+		PyErr_SetString(PyExc_ValueError, "Too many points returned");
+		Py_DECREF(result);
+		Py_DECREF(seq);
+		PyObjCErr_ToObjC();
+		return -1;
+	}
+
+
+	for (i = 0; i < retValue; i++) {
+		int r;
+
+		r = PyObjC_PythonToObjC(@encode(NSPoint),
+			PySequence_Fast_GET_ITEM(seq, i),
+			points + i);
+		if (r == -1) {
+			Py_DECREF(result);
+			Py_DECREF(seq);
+			PyObjCErr_ToObjC();
+			return -1;
+		}
+	}
+	Py_DECREF(seq);
+	Py_DECREF(result);
+
+	return retValue;
+}
+
 static int 
 _pyobjc_install_NSFont(void)
 {
 	if (PyObjC_RegisterMethodMapping(objc_lookUpClass("NSFont"), 
 		@selector(positionsForCompositeSequence:numberOfGlyphs:pointArray:),
-		PyObjCUnsupportedMethod_Caller,
-		PyObjCUnsupportedMethod_IMP) < 0 ) {
+		call_NSFont_positionsForCompositeSequence_numberOfGlyphs_pointArray_,
+		(IMP)imp_NSFont_positionsForCompositeSequence_numberOfGlyphs_pointArray_) < 0 ) {
 
 		return -1;
 	}

File Modules/AppKit/_AppKitMapping_NSOpenGLContext.m

  *
  * TODO:
  * -getValues:forParameter:
+ * -setValues:forParameter:
  * -setOffScreen:width:height:rowbytes:
  */
 #include <Python.h>
 
 	if (PyObjC_RegisterMethodMapping(
 		classNSOpenGLContext,
+		@selector(setValues:forParameter:),
+		PyObjCUnsupportedMethod_Caller,
+		PyObjCUnsupportedMethod_IMP) < 0) {
+
+		return -1;
+	}
+
+	if (PyObjC_RegisterMethodMapping(
+		classNSOpenGLContext,
 		@selector(setOffScreen:width:height:rowbytes:),
 		PyObjCUnsupportedMethod_Caller,
 		PyObjCUnsupportedMethod_IMP) < 0) {

File Modules/AppKit/_AppKitMapping_NSSimpleHorizontalTypesetter.m

  *
  * TODO:
  * -baseOfTypesetterGlyphInfo
- * -layoutGlyphsInHorizontalLineFragment_baseline:
+ * -layoutGlyphsInHorizontalLineFragment:baseline:
  */
 #include <Python.h>
 #include <AppKit/AppKit.h>

File Modules/Foundation/_FoundationMapping_NSArray.m

 	return res;
 }
 
-static PyObject* call_NSArray_sortedArrayUsingFunction_context_(
+static PyObject* 
+call_NSArray_sortedArrayUsingFunction_context_(
 		PyObject* method, PyObject* self, PyObject* arguments)
 {
 	PyObject* result;

File Modules/Foundation/_FoundationMapping_NSString.m

 /*
  * Special wrappers for NSString methods with 'difficult' arguments.
  *
- * TODO:
  * -getCString:maxLength:range:remainingRange:	[call]
  * -getCString:maxLength:			[call]
+ *
+ * TODO:
  * -getCharacters:
  * -getCharacters:range:
  * -getCString:

File Scripts/find-raw-pointers.py

 
 import objc
 import Foundation
-#import AddressBook
 import AppKit
 import PreferencePanes
 import ScreenSaver
 import InterfaceBuilder
+import AddressBook
 
 PTRSIG={}
 
     'NSMutableArray_sortUsingFunction_context_range_':1,    
 
     #<AppKit>
+    'NSBitmapImageRep_getBitmapDataPlanes_':1,
+    'NSBitmapImageRep_getTIFFCompressionTypes_count_':1,
+    'NSBitmapImageRep_initWithBitmapDataPlanes_pixelsWide_pixelsHigh_bitsPerSample_samplesPerPixel_hasAlpha_isPlanar_colorSpaceName_bytesPerRow_bitsPerPixel_':1,
+    'NSFont_positionsForCompositeSequence_numberOfGlyphs_pointArray_':1,
+    'NSSimpleHorizontalTypesetter_baseOfTypesetterGlyphInfo':1,
+    'NSSimpleHorizontalTypesetter_layoutGlyphsInHorizontalLineFragment_baseline_':1,
+    'NSWindow_graphicsPort':1,
+    'NSWindow_initWithWindowRef_':1,
+    'NSWindow_windowRef':1,
     'NSLayoutManager_getGlyphs_range_':1,
     'NSLayoutManager_getGlyphsInRange_glyphs_characterIndexes_glyphInscriptions_elasticBits_':1,
     'NSLayoutManager_getGlyphsInRange_glyphs_characterIndexes_glyphInscriptions_elasticBits_bidiLevels_':1,
 
 # Undocumented methods:
 
+    #<AddressBook>
+    'ABLDAP_ConfigController_editorDidEnd_returnCode_contextInfo_':1,
+    'ABGroupsController_deleteConfirmSheetDidEnd_returnCode_contextInfo_':1,
+    'ABCustomLabelEditor_sheetDidEnd_returnCode_contextInfo_':1,
+    'ABRemoteImageLoader_beginLoadingImageForPerson_forClient_orCallback_withRefcon_':1,
+    'ABLayoutManager_rectArrayForCharacterRange_withinSelectedCharacterRange_inTextContainer_rectCount_forCursorPosition_':1,
+    'ABLDAP_Manager_queryAttributes':1,
+    'ABPersonImageView_savePanelDidEnd_returnCode_contextInfo_':1,
+    'ABVCard_initWithVCardRef_':1,
+    'ABVCardEnumerator_initWithVCardRef_':1,
+    'ABRecord_firstLastSortingNamePart1_part2_':1,
+    'ABRecord_lastFirstSortingNamePart1_part2_':1,
+    'AB_AFDataFile_info':1,
+    'ABPeopleController_deleteConfirmSheetDidEnd_returnCode_contextInfo_':1,
+    'ABPeopleController_removeConfirmSheetDidEnd_returnCode_contextInfo_':1,
+
+
     #<Foundation>
+    'NSString_escapeStringForUnichar_and_advance_':1,
     'NSSet_getObjects_':1,
     'NSData_initWithBytes_length_copy_freeWhenDone_bytesAreVM_':1,
     'NSMessagePort_sendBeforeTime_streamData_components_from_msgid_':1,
     'NSConstantString_initWithCharactersNoCopy_length_':1,
 
     #<AppKit>
+    'NSCGSContext_windowID':1,
     'NSPreferences_confirmCloseSheetIsDone_returnCode_contextInfo_':1,
     'NSPasteboard_readDocumentFromPbtype_filename_':1,
     'NSView_knowsPagesFirst_last_':1,
     'NSHFSContainer_iconRef_label_forObjectName_':1,
     'NSHFSObject_iconRef_label_':1,
     'NSHFSObject_initWithRawCatalogInfo_name_parentRef_ref_hfsName_hidden_':1,
-    'SHyphenator_getHyphenLocations_inString_':1,
+    'NSHyphenator_getHyphenLocations_inString_':1,
     'NSHyphenator_getHyphenLocations_inString_wordAtIndex_':1,
     'NSImageReader_bitmapDataPlanes':1,
     'NSImageReader_loadImage_':1,