When trying to initialize an NSAttributedString like this:
attributedString =
AppKit.NSAttributedString.alloc().initWithHTML_baseURL_documentAttributes_(data,
url, None)
I get the error "TypeError: Need 2 arguments, got 3", although the
documentation makes it pretty clear that there are in fact 3 arguments.
Similarly,
attributedString =
AppKit.NSAttributedString.alloc().initWithHTML_documentAttributes_(data,
url)
gives the error "TypeError: Need 1 arguments, got 2", although the
documentation makes it pretty clear that there are in fact 2 arguments.
I've looked at the signatures for the function in PyObjC's
_FoundationSignatures.py, but wasn't able to interpret them well enough
to help me. For reference, they are:
setSignatureForSelector("NSAttributedString",
"initWithHTML:baseURL:documentAttributes:", "@[EMAIL PROTECTED]:[EMAIL
PROTECTED]@[EMAIL PROTECTED]")
setSignatureForSelector("NSAttributedString",
"initWithHTML:documentAttributes:", "@@:@o^@")
Can someone more familiar with what these mean help me out?
Thanks,
Mike
_______________________________________________
Pythonmac-SIG maillist - [email protected]
http://mail.python.org/mailman/listinfo/pythonmac-sig