Skip to content
Snippets Groups Projects
Commit 87279811 authored by Mark Tearle's avatar Mark Tearle
Browse files

Add code to display Coca Cola logo

parent 4758f6a9
Branches
No related merge requests found
__ ___ __ .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"
......@@ -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
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment