raise ValueError instead of ctypes.ArgumentError

ctypes.ArgumentError got imported through PyOpenGL import *
This commit is contained in:
KIU Shueng Chuan 2021-07-17 18:29:42 +08:00
parent f85a1015ad
commit 31e10fdc1d

View File

@ -39,7 +39,7 @@ class GLTextItem(GLGraphicsItem):
args = ['pos', 'color', 'text', 'font']
for k in kwds.keys():
if k not in args:
raise ArgumentError('Invalid keyword argument: %s (allowed arguments are %s)' % (k, str(args)))
raise ValueError('Invalid keyword argument: %s (allowed arguments are %s)' % (k, str(args)))
for arg in args:
if arg in kwds:
value = kwds[arg]