Recently I found out that the italic font is not applied to numbers in my legend. Here is the code:
import matplotlib.pyplot as plt
a = [1,2,3,4,5]
b = [1,3,5,7,9]
c = [1,2,4,6,8]
x = [1,2,3,4,5]
label = ['ABC123',r'it_$\it{ABC123}$', r'bf_$\bf{ABC123}$']
plt.plot(x,a, label = label[0])
plt.plot(x,b, label = label[1])
plt.plot(x,c,label = label[2])
plt.legend()
plt.show()
As you can see, the number 123 is not italicized, but if I try with bold font, it worked. Is there something I am missing here?