diff --git a/cokelogo.txt b/cokelogo.txt new file mode 100644 index 0000000000000000000000000000000000000000..ad07d116fcdf3926974546036b9274b59f34023b --- /dev/null +++ b/cokelogo.txt @@ -0,0 +1,14 @@ + __ ___ __ .ama , + ,d888a ,d88888888888ba. ,88"I) d + a88']8i a88".8"8) `"8888:88 " _a8' + .d8P' PP .d8P'.8 d) "8:88:baad8P' + ,d8P' ,ama, .aa, .ama.g ,mmm d8P' 8 .8' 88):888P' + ,d88' d8[ "8..a8"88 ,8I"88[ I88' d88 ]IaI" d8[ + a88' dP "bm8mP8'(8'.8I 8[ d88' `" .88 +,88I ]8' .d'.8 88' ,8' I[ ,88P ,ama ,ama, d8[ .ama.g +[88' I8, .d' ]8, ,88B ,d8 aI (88',88"8) d8[ "8. 88 ,8I"88[ +]88 `888P' `8888" "88P"8m" I88 88[ 8[ dP "bm8m88[.8I 8[ +]88, _,,aaaaaa,_ I88 8" 8 ]P' .d' 88 88' ,8' I[ +`888a,. ,aadd88888888888bma. )88, ,]I I8, .d' )88a8B ,d8 aI + "888888PP"' `8""""""8 "888PP' `888P' `88P"88P"8m" + diff --git a/virtualcoke.py b/virtualcoke.py index e8cfe93a8b74b62f7982cfb8757d5ae1b95d367d..34670f34770399711cce9e5cdd47b399ad82990d 100755 --- a/virtualcoke.py +++ b/virtualcoke.py @@ -8,9 +8,14 @@ from datetime import datetime import socket, select, errno # for emulator code +import os import sys import string +# Ascii Coke Logo +# by Normand Veilleux +# in cokelogo.txt + class ContainedMultiSelect(npyscreen.BoxTitle): _contained_widget = npyscreen.TitleMultiSelect @@ -48,6 +53,16 @@ class VirtualCoke(npyscreen.Form): def create(self, *args, **keywords): super(VirtualCoke, self).create(*args, **keywords) + logofile = os.path.join(os.path.dirname(os.path.realpath(sys.argv[0])), "cokelogo.txt") + logotext = open(logofile).read() + self.cokelogo = [] + + cly = 1 + for line in logotext.splitlines(): + widget = self.add(npyscreen.FixedText, value=line, editable = False, rely = cly) + cly = cly + 1 + self.cokelogo.append(widget) + # self.textdisplay = self.add(npyscreen.FixedText, value=self.parentApp.textdisplay, editable=False, relx=9) # self.textdisplay.important = True