import matplotlib.patches as mpatch
import matplotlib.pyplot as plt

styles = mpatch.BoxStyle.get_styles()

figheight = (len(styles)+.5)
fig1 = plt.figure(1, (4/1.5, figheight/1.5))
fontsize = 0.3 * 72

for i, (stylename, styleclass) in enumerate(styles.items()):
    fig1.text(0.5, (float(len(styles)) - 0.5 - i)/figheight, stylename,
              ha="center",
              size=fontsize,
              transform=fig1.transFigure,
              bbox=dict(boxstyle=stylename, fc="w", ec="k"))
plt.draw()
plt.show()


[((4, 9, 4, 37), 'matplotlib.patches.BoxStyle.get_styles', 'mpatch.BoxStyle.get_styles', ({}, {}), '()', True, 'import matplotlib.patches as mpatch\n'), ((7, 7, 7, 44), 'matplotlib.pyplot.figure', 'plt.figure', ({(7, 18, 7, 19): '1', (7, 21, 7, 43): '(4 / 1.5, figheight / 1.5)'}, {}), '(1, (4 / 1.5, figheight / 1.5))', True, 'import matplotlib.pyplot as plt\n'), ((16, 0, 16, 10), 'matplotlib.pyplot.draw', 'plt.draw', ({}, {}), '()', True, 'import matplotlib.pyplot as plt\n'), ((17, 0, 17, 10), 'matplotlib.pyplot.show', 'plt.show', ({}, {}), '()', True, 'import matplotlib.pyplot as plt\n')]