Remove annotate from graph.

Legend box is smarter and looks better imho
This commit is contained in:
Worros 2009-12-02 14:07:06 +08:00
parent 395f19b5fb
commit 8d95835afe

View File

@ -185,14 +185,12 @@ class GuiGraphViewer (threading.Thread):
#TODO: Do something useful like alert user #TODO: Do something useful like alert user
print "No hands returned by graph query" print "No hands returned by graph query"
else: else:
# text = "All Hands, " + sitename + str(name) + "\nProfit: $" + str(line[-1]) + "\nTotal Hands: " + str(len(line)) #text = "Profit: $%.2f\nTotal Hands: %d" %(green[-1], len(green))
text = "All Hands, " + "\nProfit: $" + str(green[-1]) + "\nTotal Hands: " + str(len(green)) #self.ax.annotate(text,
# xy=(10, -10),
self.ax.annotate(text, # xycoords='axes points',
xy=(10, -10), # horizontalalignment='left', verticalalignment='top',
xycoords='axes points', # fontsize=10)
horizontalalignment='left', verticalalignment='top',
fontsize=10)
#Draw plot #Draw plot
self.ax.plot(green, color='green', label='Hands: %d\nProfit: $%.2f' %(len(green), green[-1])) self.ax.plot(green, color='green', label='Hands: %d\nProfit: $%.2f' %(len(green), green[-1]))