What's The Library Blender Uses to Draw?
Blender's drawing code is all custom C code calling opengl functions. Even the ui widget toolkit is custom. There is no python library. 

As suggested by batfinger, you can use bgl, blender's opengl wrapper for python if you need custom drawing.