diff --git a/TODO b/TODO index c515bc3..36817fd 100644 --- a/TODO +++ b/TODO @@ -1,18 +1,13 @@ Features: -* memo kicking -* user import -* Transparent background? -* tab right-click menu on tabbed convos, chat window -* link to memos +* X closes to tray * color text is not being translated to server? * convo backgrounds -- make them more like http://www.mspaintadventures.com/storyfiles/hs2/02546_2.gif * PESTERLOG: in convo window * help button on quirks menu? * tab recombining gives wrong window icon * help menu -- about and forum -* profile switch should say current profile -* X closes to tray -- release alpha +* scroll bar style * User commands/stop user from sending commands accidentally * shared buddy lists - changes to the buddy list should refresh it? multiple clients share buddy list??? @@ -21,13 +16,14 @@ Features: * comment history (up button) * page up/down scrolling * get rid of border on chat window? +* Idling * ctrl-tab should prefer new convos * More complex quirks: random, spelling, by-sound * Implement TC options * chumList not scaling -- QListView + delegate? * spell check? * Help menu -* more robust IRC error handling +* change profile only once we have confirmation from server -- release beta * log viewer * pick your own icon diff --git a/convo.py b/convo.py index c454e71..d5ffe33 100644 --- a/convo.py +++ b/convo.py @@ -3,7 +3,7 @@ import re from PyQt4 import QtGui, QtCore from dataobjs import PesterProfile, Mood -from generic import PesterIcon +from generic import PesterIcon, RightClickList from parsetools import escapeBrackets, convertTags class PesterTabWindow(QtGui.QFrame): @@ -255,7 +255,10 @@ class PesterText(QtGui.QTextEdit): def mousePressEvent(self, event): url = self.anchorAt(event.pos()) if url != "": - QtGui.QDesktopServices.openUrl(QtCore.QUrl(url, QtCore.QUrl.TolerantMode)) + if url[0] == "#" and url != "#pesterchum": + self.parent().mainwindow.showMemos(url[1:]) + else: + QtGui.QDesktopServices.openUrl(QtCore.QUrl(url, QtCore.QUrl.TolerantMode)) QtGui.QTextEdit.mousePressEvent(self, event) def mouseMoveEvent(self, event): QtGui.QTextEdit.mouseMoveEvent(self, event) @@ -283,7 +286,7 @@ class PesterConvo(QtGui.QFrame): self.mainwindow = mainwindow convo = self.mainwindow.theme["convo"] self.resize(*convo["size"]) - self.setStyleSheet(convo["style"]) + self.setStyleSheet("QFrame { %s } QScrollBar:vertical { %s } QScrollBar::handle:vertical { %s }" % (convo["style"], convo["scrollbar"]["style"], convo["scrollbar"]["handle"])) self.setWindowIcon(self.icon()) self.setWindowTitle(self.title()) @@ -313,7 +316,24 @@ class PesterConvo(QtGui.QFrame): self.setLayout(self.layout) + self.optionsMenu = QtGui.QMenu(self) + self.optionsMenu.setStyleSheet(self.mainwindow.theme["main/defaultwindow/style"]) + self.addChumAction = QtGui.QAction(self.mainwindow.theme["main/menus/rclickchumlist/addchum"], self) + self.connect(self.addChumAction, QtCore.SIGNAL('triggered()'), + self, QtCore.SLOT('addThisChum()')) + self.blockAction = QtGui.QAction(self.mainwindow.theme["main/menus/rclickchumlist/blockchum"], self) + self.connect(self.blockAction, QtCore.SIGNAL('triggered()'), + self, QtCore.SLOT('blockThisChum()')) + self.quirksOff = QtGui.QAction(self.mainwindow.theme["main/menus/rclickchumlist/quirksoff"], self) + self.quirksOff.setCheckable(True) + self.connect(self.quirksOff, QtCore.SIGNAL('toggled(bool)'), + self, QtCore.SLOT('toggleQuirks(bool)')) + self.optionsMenu.addAction(self.quirksOff) + self.optionsMenu.addAction(self.addChumAction) + self.optionsMenu.addAction(self.blockAction) + self.chumopen = False + self.applyquirks = True if parent: parent.addChat(self) @@ -394,15 +414,18 @@ class PesterConvo(QtGui.QFrame): if self.parent(): self.parent().showChat(self.title()) self.raiseChat() - + def contextMenuEvent(self, event): + if event.reason() == QtGui.QContextMenuEvent.Mouse: + self.optionsMenu.popup(event.globalPos()) def closeEvent(self, event): self.mainwindow.waitingMessages.messageAnswered(self.title()) self.windowClosed.emit(self.title()) + def setChumOpen(self, o): self.chumopen = o def changeTheme(self, theme): self.resize(*theme["convo/size"]) - self.setStyleSheet(theme["convo/style"]) + self.setStyleSheet("QFrame { %s } QScrollBar:vertical { %s } QScrollBar::handle:vertical { %s }" % (convo["style"], convo["scrollbar"]["style"], convo["scrollbar"]["handle"])) margins = theme["convo/margins"] self.layout.setContentsMargins(margins["left"], margins["top"], margins["right"], margins["bottom"]) @@ -415,17 +438,23 @@ class PesterConvo(QtGui.QFrame): self.chumLabel.setMaximumHeight(self.mainwindow.theme["convo/chumlabel/maxheight"]) self.chumLabel.setMinimumHeight(self.mainwindow.theme["convo/chumlabel/minheight"]) self.chumLabel.setSizePolicy(QtGui.QSizePolicy(QtGui.QSizePolicy.MinimumExpanding, QtGui.QSizePolicy.Expanding)) + self.quirksOff.setText(self.mainwindow.theme["main/menus/rclickchumlist/quirksoff"]) + self.addChumAction.setText(self.mainwindow.theme["main/menus/rclickchumlist/addchum"]) + self.blockAction.setText(self.mainwindow.theme["main/menus/rclickchumlist/blockchum"]) + self.textArea.changeTheme(theme) self.textInput.changeTheme(theme) + @QtCore.pyqtSlot() def sentMessage(self): text = self.textInput.text() if text == "": return # deal with quirks here - qtext = self.mainwindow.userprofile.quirks.apply(unicode(text)) - text = QtCore.QString(qtext) + if self.applyquirks: + qtext = self.mainwindow.userprofile.quirks.apply(unicode(text)) + text = QtCore.QString(qtext) self.textInput.setText("") self.addMessage(text, True) # if ceased, rebegin @@ -435,6 +464,17 @@ class PesterConvo(QtGui.QFrame): text = convertTags(unicode(text), "ctag") self.messageSent.emit(text, self.title()) + @QtCore.pyqtSlot() + def addThisChum(self): + self.mainwindow.addChum(self.chum) + @QtCore.pyqtSlot() + def blockThisChum(self): + self.mainwindow.blockChum(self.chum.handle) + @QtCore.pyqtSlot(bool) + def toggleQuirks(self, toggled): + self.applyquirks = not toggled + + messageSent = QtCore.pyqtSignal(QtCore.QString, QtCore.QString) windowClosed = QtCore.pyqtSignal(QtCore.QString) diff --git a/convo.pyc b/convo.pyc index 9fdf065..d509eef 100644 Binary files a/convo.pyc and b/convo.pyc differ diff --git a/generic.pyc b/generic.pyc index 69c7bc6..cc9b4e2 100644 Binary files a/generic.pyc and b/generic.pyc differ diff --git a/irc.py b/irc.py index f48289d..82def57 100644 --- a/irc.py +++ b/irc.py @@ -8,7 +8,7 @@ import random from dataobjs import Mood, PesterProfile from generic import PesterList -logging.basicConfig(level=logging.DEBUG) +logging.basicConfig(level=logging.INFO) class PesterIRC(QtCore.QObject): def __init__(self, window): @@ -85,6 +85,15 @@ class PesterIRC(QtCore.QObject): c = unicode(channel) h = unicode(handle) helpers.kick(self.cli, h, c) + @QtCore.pyqtSlot(QtCore.QString, QtCore.QString, QtCore.QString) + def setChannelMode(self, channel, mode, command): + c = unicode(channel) + m = unicode(mode) + cmd = unicode(command) + if cmd == "": + cmd = None + helpers.mode(self.cli, c, m, cmd) + def updateIRC(self): self.conn.next() diff --git a/irc.pyc b/irc.pyc index 34d021f..29bc2ff 100644 Binary files a/irc.pyc and b/irc.pyc differ diff --git a/mash b/mash new file mode 100644 index 0000000..449e112 --- /dev/null +++ b/mash @@ -0,0 +1,109 @@ +diff --git a/memos.py b/memos.py +index 239947e..af7ab32 100644 +--- a/memos.py ++++ b/memos.py +@@ -236,7 +236,9 @@ class MemoText(PesterText): + time = TimeTracker(newtime) + parent.times[chum.handle] = time + timeGrammar = time.getGrammar() +- self.append(convertTags(chum.memojoinmsg(systemColor, time.getTime(), timeGrammar, window.theme["convo/text/joinmemo"]))) ++ msg = chum.memojoinmsg(systemColor, time.getTime(), timeGrammar, window.theme["convo/text/joinmemo"]) ++ self.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + else: + time = parent.time + +@@ -356,7 +358,9 @@ class PesterMemo(PesterConvo): + p = self.mainwindow.profile() + timeGrammar = self.time.getGrammar() + systemColor = QtGui.QColor(self.mainwindow.theme["memos/systemMsgColor"]) +- self.textArea.append(convertTags(p.memoopenmsg(systemColor, self.time.getTime(), timeGrammar, self.mainwindow.theme["convo/text/openmemo"], self.channel))) ++ msg = p.memoopenmsg(systemColor, self.time.getTime(), timeGrammar, self.mainwindow.theme["convo/text/openmemo"], self.channel) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + + self.op = False + self.newmessage = False +@@ -482,18 +486,24 @@ class PesterMemo(PesterConvo): + self.times[handle].setCurrent(close) + grammar = self.times[handle].getGrammar() + self.times[handle].removeTime(close) +- self.textArea.append(convertTags(chum.memoclosemsg(systemColor, grammar, window.theme["convo/text/closememo"]))) ++ msg = chum.memoclosemsg(systemColor, grammar, window.theme["convo/text/closememo"]) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + elif timed not in self.times[handle]: + self.times[handle].addTime(timed) + grammar = self.times[handle].getGrammar() +- self.textArea.append(convertTags(chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]))) ++ msg = chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + else: + self.times[handle].setCurrent(timed) + else: + if timed is not None: + ttracker = TimeTracker(timed) + grammar = ttracker.getGrammar() +- self.textArea.append(convertTags(chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]))) ++ msg = chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + self.times[handle] = ttracker + + @QtCore.pyqtSlot() +@@ -556,7 +566,9 @@ class PesterMemo(PesterConvo): + while self.times[h].getTime() is not None: + t = self.times[h] + grammar = t.getGrammar() +- self.textArea.append(convertTags(chum.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]))) ++ msg = chum.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + self.times[h].removeTime(t.getTime()) + if update == "nick": + self.addUser(newnick) +@@ -583,7 +595,9 @@ class PesterMemo(PesterConvo): + opgrammar = self.time.getGrammar() + else: + opgrammar = TimeGrammar("CURRENT", "C", "RIGHT NOW") +- self.textArea.append(convertTags(chum.memobanmsg(opchum, opgrammar, systemColor, grammar))) ++ msg = chum.memobanmsg(opchum, opgrammar, systemColor, grammar) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + ttracker.removeTime(ttracker.getTime()) + + if chum is self.mainwindow.profile(): +@@ -599,7 +613,9 @@ class PesterMemo(PesterConvo): + self.resetSlider(curtime) + self.mainwindow.joinChannel.emit(self.channel) + me = self.mainwindow.profile() +- self.textArea.append(convertTags(me.memoopenmsg(systemColor, self.time.getTime(), self.time.getGrammar(), self.mainwindow.theme["convo/text/openmemo"], self.channel))) ++ msg = me.memoopenmsg(systemColor, self.time.getTime(), self.time.getGrammar(), self.mainwindow.theme["convo/text/openmemo"], self.channel) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + elif ret == QtGui.QMessageBox.Cancel: + if self.parent(): + i = self.parent().tabIndices[self.channel] +@@ -639,7 +655,9 @@ class PesterMemo(PesterConvo): + time = txt2delta(self.timeinput.text()) + present = self.time.addTime(time) + if not present: +- self.textArea.append(convertTags(me.memojoinmsg(systemColor, time, self.time.getGrammar(), self.mainwindow.theme["convo/text/joinmemo"]))) ++ msg = me.memojoinmsg(systemColor, time, self.time.getGrammar(), self.mainwindow.theme["convo/text/joinmemo"]) ++ self.textArea.append(convertTags(msg)) ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + + serverText = "PESTERCHUM:TIME>"+delta2txt(time, "server") + self.messageSent.emit(serverText, self.title()) +@@ -651,7 +669,9 @@ class PesterMemo(PesterConvo): + if removed: + grammar = self.time.getGrammarTime(time) + systemColor = QtGui.QColor(self.mainwindow.theme["memos/systemMsgColor"]) +- self.textArea.append(convertTags(me.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]))) ++ ++ self.textArea.append(convertTags( ++ window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) + + newtime = self.time.getTime() + if newtime is None: diff --git a/memos.py b/memos.py index 239947e..2de5da2 100644 --- a/memos.py +++ b/memos.py @@ -236,7 +236,9 @@ class MemoText(PesterText): time = TimeTracker(newtime) parent.times[chum.handle] = time timeGrammar = time.getGrammar() - self.append(convertTags(chum.memojoinmsg(systemColor, time.getTime(), timeGrammar, window.theme["convo/text/joinmemo"]))) + msg = chum.memojoinmsg(systemColor, time.getTime(), timeGrammar, window.theme["convo/text/joinmemo"]) + self.append(convertTags(msg)) + window.chatlog.log(parent.channel, convertTags(msg, "bbcode")) else: time = parent.time @@ -356,7 +358,9 @@ class PesterMemo(PesterConvo): p = self.mainwindow.profile() timeGrammar = self.time.getGrammar() systemColor = QtGui.QColor(self.mainwindow.theme["memos/systemMsgColor"]) - self.textArea.append(convertTags(p.memoopenmsg(systemColor, self.time.getTime(), timeGrammar, self.mainwindow.theme["convo/text/openmemo"], self.channel))) + msg = p.memoopenmsg(systemColor, self.time.getTime(), timeGrammar, self.mainwindow.theme["convo/text/openmemo"], self.channel) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) self.op = False self.newmessage = False @@ -482,18 +486,24 @@ class PesterMemo(PesterConvo): self.times[handle].setCurrent(close) grammar = self.times[handle].getGrammar() self.times[handle].removeTime(close) - self.textArea.append(convertTags(chum.memoclosemsg(systemColor, grammar, window.theme["convo/text/closememo"]))) + msg = chum.memoclosemsg(systemColor, grammar, window.theme["convo/text/closememo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) elif timed not in self.times[handle]: self.times[handle].addTime(timed) grammar = self.times[handle].getGrammar() - self.textArea.append(convertTags(chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]))) + msg = chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) else: self.times[handle].setCurrent(timed) else: if timed is not None: ttracker = TimeTracker(timed) grammar = ttracker.getGrammar() - self.textArea.append(convertTags(chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]))) + msg = chum.memojoinmsg(systemColor, timed, grammar, window.theme["convo/text/joinmemo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) self.times[handle] = ttracker @QtCore.pyqtSlot() @@ -556,7 +566,9 @@ class PesterMemo(PesterConvo): while self.times[h].getTime() is not None: t = self.times[h] grammar = t.getGrammar() - self.textArea.append(convertTags(chum.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]))) + msg = chum.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) self.times[h].removeTime(t.getTime()) if update == "nick": self.addUser(newnick) @@ -583,7 +595,9 @@ class PesterMemo(PesterConvo): opgrammar = self.time.getGrammar() else: opgrammar = TimeGrammar("CURRENT", "C", "RIGHT NOW") - self.textArea.append(convertTags(chum.memobanmsg(opchum, opgrammar, systemColor, grammar))) + msg = chum.memobanmsg(opchum, opgrammar, systemColor, grammar) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) ttracker.removeTime(ttracker.getTime()) if chum is self.mainwindow.profile(): @@ -599,7 +613,9 @@ class PesterMemo(PesterConvo): self.resetSlider(curtime) self.mainwindow.joinChannel.emit(self.channel) me = self.mainwindow.profile() - self.textArea.append(convertTags(me.memoopenmsg(systemColor, self.time.getTime(), self.time.getGrammar(), self.mainwindow.theme["convo/text/openmemo"], self.channel))) + msg = me.memoopenmsg(systemColor, self.time.getTime(), self.time.getGrammar(), self.mainwindow.theme["convo/text/openmemo"], self.channel) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) elif ret == QtGui.QMessageBox.Cancel: if self.parent(): i = self.parent().tabIndices[self.channel] @@ -639,7 +655,9 @@ class PesterMemo(PesterConvo): time = txt2delta(self.timeinput.text()) present = self.time.addTime(time) if not present: - self.textArea.append(convertTags(me.memojoinmsg(systemColor, time, self.time.getGrammar(), self.mainwindow.theme["convo/text/joinmemo"]))) + msg = me.memojoinmsg(systemColor, time, self.time.getGrammar(), self.mainwindow.theme["convo/text/joinmemo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) serverText = "PESTERCHUM:TIME>"+delta2txt(time, "server") self.messageSent.emit(serverText, self.title()) @@ -651,7 +669,9 @@ class PesterMemo(PesterConvo): if removed: grammar = self.time.getGrammarTime(time) systemColor = QtGui.QColor(self.mainwindow.theme["memos/systemMsgColor"]) - self.textArea.append(convertTags(me.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]))) + msg = me.memoclosemsg(systemColor, grammar, self.mainwindow.theme["convo/text/closememo"]) + self.textArea.append(convertTags(msg)) + self.mainwindow.chatlog.log(self.channel, convertTags(msg, "bbcode")) newtime = self.time.getTime() if newtime is None: diff --git a/memos.pyc b/memos.pyc index 8e6e6b4..577a5f0 100644 Binary files a/memos.pyc and b/memos.pyc differ diff --git a/menus.py b/menus.py index eb3611c..25ab2c4 100644 --- a/menus.py +++ b/menus.py @@ -187,6 +187,7 @@ class PesterChooseProfile(QtGui.QDialog): self.parent = parent self.setStyleSheet(self.theme["main/defaultwindow/style"]) + self.currentHandle = QtGui.QLabel("CHANGING FROM %s" % userprofile.chat.handle) self.chumHandle = QtGui.QLineEdit(self) self.chumHandle.setMinimumWidth(200) self.chumHandleLabel = QtGui.QLabel(self.theme["main/mychumhandle/label/text"], self) @@ -232,6 +233,8 @@ class PesterChooseProfile(QtGui.QDialog): if collision: collision_warning = QtGui.QLabel("%s is taken already! Pick a new profile." % (collision)) layout_0.addWidget(collision_warning) + else: + layout_0.addWidget(self.currentHandle, alignment=QtCore.Qt.AlignHCenter) layout_0.addLayout(layout_1) if avail_profiles: profileLabel = QtGui.QLabel("Or choose an existing profile:", self) @@ -389,7 +392,7 @@ class PesterUserlist(QtGui.QDialog): addChum = QtCore.pyqtSignal(QtCore.QString) class PesterMemoList(QtGui.QDialog): - def __init__(self, parent): + def __init__(self, parent, channel=""): QtGui.QDialog.__init__(self, parent) self.setModal(False) self.theme = parent.theme @@ -406,7 +409,8 @@ class PesterMemoList(QtGui.QDialog): self, QtCore.SLOT('joinActivatedMemo(QListWidgetItem *)')) self.orjoinlabel = QtGui.QLabel("OR MAKE A NEW MEMO:") - self.newmemo = QtGui.QLineEdit(self) + self.newmemo = QtGui.QLineEdit(channel, self) + self.secretChannel = QtGui.QCheckBox("HIDDEN?", self) self.timelabel = QtGui.QLabel("TIMEFRAME:") self.timeslider = TimeSlider(QtCore.Qt.Horizontal, self) @@ -428,6 +432,7 @@ class PesterMemoList(QtGui.QDialog): layout_0.addWidget(self.channelarea) layout_0.addWidget(self.orjoinlabel) layout_0.addWidget(self.newmemo) + layout_0.addWidget(self.secretChannel) layout_0.addWidget(self.timelabel) layout_0.addWidget(self.timeslider) layout_0.addWidget(self.timeinput) diff --git a/menus.pyc b/menus.pyc index e7171d2..a149307 100644 Binary files a/menus.pyc and b/menus.pyc differ diff --git a/oyoyo/helpers.py b/oyoyo/helpers.py index 38841b1..104f023 100644 --- a/oyoyo/helpers.py +++ b/oyoyo/helpers.py @@ -41,6 +41,12 @@ def channel_list(cli): def kick(cli, handle, channel): cli.send("KICK %s %s" % (channel, handle)) +def mode(cli, channel, mode, options=None): + cmd = "MODE %s %s" % (channel, mode) + if options: + cmd += " %s" % (options) + cli.send(cmd) + def msgrandom(cli, choices, dest, user=None): o = "%s: " % user if user else "" o += random.choice(choices) diff --git a/oyoyo/helpers.pyc b/oyoyo/helpers.pyc index 6167088..e5b17da 100644 Binary files a/oyoyo/helpers.pyc and b/oyoyo/helpers.pyc differ diff --git a/parsetools.py b/parsetools.py index 5417607..da7231e 100644 --- a/parsetools.py +++ b/parsetools.py @@ -5,6 +5,7 @@ from PyQt4 import QtGui _ctag_begin = re.compile(r'<c=(.*?)>') _ctag_rgb = re.compile(r'\d+,\d+,\d+') _urlre = re.compile(r"(?i)(http://[^\s<]+)") +_memore = re.compile(r" (#[A-Za-z0-9_]+)") def convertTags(string, format="html"): if format not in ["html", "bbcode", "ctag"]: @@ -40,6 +41,10 @@ def convertTags(string, format="html"): elif format=="ctag": return matchobj.group(1) string = _urlre.sub(urlrep, string) + if format == "html": + print string + string = _memore.sub(r" <a href='\1'>\1</a>", string) + print string return string def escapeBrackets(string): diff --git a/parsetools.pyc b/parsetools.pyc index e63ad4e..d52cb82 100644 Binary files a/parsetools.pyc and b/parsetools.pyc differ diff --git a/pesterchum.js b/pesterchum.js index 2ab9987..233397c 100644 --- a/pesterchum.js +++ b/pesterchum.js @@ -1 +1 @@ -{"tabs": false, "chums": ["aquaMarinist", "marineAquist", "unknownTraveler", "tentacleTherapist", "macruralAlchemist", "vaginalEngineer", "mechanicalSpectacle", "carcinoGeneticist", "schlagzeugGator", "gamblingGenocider", "gardenGnostic", "superGhost", "centaursTesticle", "arachnidsGrip", "grimAuxiliatrix", "remoteBloodbath", "nitroZealist", "greenZephyr", "arsenicCatnip", "adiosToreador", "cuttlefishCuller", "rageInducer", "gallowsCalibrator", "caligulasAquarium", "terminallyCapricious", "illuminatedWax", "illuminatedWax"], "defaultprofile": "testProfile", "block": []} \ No newline at end of file +{"tabs": false, "chums": ["marineAquist", "unknownTraveler", "tentacleTherapist", "macruralAlchemist", "vaginalEngineer", "mechanicalSpectacle", "carcinoGeneticist", "schlagzeugGator", "gamblingGenocider", "gardenGnostic", "superGhost", "centaursTesticle", "arachnidsGrip", "grimAuxiliatrix", "remoteBloodbath", "nitroZealist", "greenZephyr", "arsenicCatnip", "adiosToreador", "cuttlefishCuller", "rageInducer", "gallowsCalibrator", "caligulasAquarium", "terminallyCapricious", "illuminatedWax", "testOut", "aquaMarinist"], "defaultprofile": "testProfile", "block": []} \ No newline at end of file diff --git a/pesterchum.py b/pesterchum.py index d9997d9..78f2715 100644 --- a/pesterchum.py +++ b/pesterchum.py @@ -7,6 +7,7 @@ from string import Template import random import json import re +import socket from PyQt4 import QtGui, QtCore import pygame @@ -52,11 +53,11 @@ class NoneSound(object): class PesterLog(object): def __init__(self, handle): self.handle = handle - if not os.path.exists("logs/%s" % (handle)): - os.mkdir("logs/%s" % (handle)) self.convos = {} def log(self, handle, msg): if not self.convos.has_key(handle): + if not os.path.exists("logs/%s" % (self.handle)): + os.mkdir("logs/%s" % (self.handle)) time = datetime.now().strftime("%Y-%m-%d.%H.%M.txt") if not os.path.exists("logs/%s/%s" % (self.handle, handle)): os.mkdir("logs/%s/%s" % (self.handle, handle)) @@ -126,7 +127,20 @@ class pesterTheme(dict): s = Template(v) d[k] = s.safe_substitute(path=self.path) return d - + def get(self, key, default): + try: + ret = self[key] + except KeyError: + return default + else: + return ret + def has_key(self, key): + try: + self[key] + except KeyError: + return False + else: + return True class userConfig(object): def __init__(self): @@ -147,8 +161,9 @@ class userConfig(object): def tabs(self): return self.config["tabs"] def addChum(self, chum): - newchums = self.config['chums'] + [chum.handle] - self.set("chums", newchums) + if chum.handle not in self.config['chums']: + newchums = self.config['chums'] + [chum.handle] + self.set("chums", newchums) def removeChum(self, chum): if type(chum) is PesterProfile: handle = chum.handle @@ -518,6 +533,9 @@ class PesterMoodHandler(QtCore.QObject): newbutton.setSelected(True) newmood = Mood(m) self.mainwindow.userprofile.chat.mood = newmood + if self.mainwindow.currentMoodIcon: + moodicon = newmood.icon(self.mainwindow.theme) + self.mainwindow.currentMoodIcon.setPixmap(moodicon.pixmap(moodicon.realsize())) self.mainwindow.moodUpdated.emit() class PesterMoodButton(QtGui.QPushButton): @@ -577,6 +595,7 @@ class PesterWindow(MovingWindow): self.tabconvo = None self.tabmemo = None + self.setAutoFillBackground(True) self.setObjectName("main") self.config = userConfig() if self.config.defaultprofile(): @@ -606,6 +625,9 @@ class PesterWindow(MovingWindow): self.memoaction = memoaction self.connect(memoaction, QtCore.SIGNAL('triggered()'), self, QtCore.SLOT('showMemos()')) + self.importaction = QtGui.QAction(self.theme["main/menus/client/import"], self) + self.connect(self.importaction, QtCore.SIGNAL('triggered()'), + self, QtCore.SLOT('importExternalConfig()')) self.menu = QtGui.QMenuBar(self) filemenu = self.menu.addMenu(self.theme["main/menus/client/_name"]) @@ -613,6 +635,7 @@ class PesterWindow(MovingWindow): filemenu.addAction(opts) filemenu.addAction(memoaction) filemenu.addAction(userlistaction) + filemenu.addAction(self.importaction) filemenu.addAction(exitaction) changetheme = QtGui.QAction(self.theme["main/menus/profile/theme"], self) @@ -718,6 +741,10 @@ class PesterWindow(MovingWindow): else: for m in self.memos.values(): m.close() + def paintEvent(self, event): + palette = QtGui.QPalette() + palette.setBrush(QtGui.QPalette.Window, QtGui.QBrush(self.backgroundImage)) + self.setPalette(palette) def closeEvent(self, event): self.closeConversations() @@ -793,7 +820,7 @@ class PesterWindow(MovingWindow): self.connect(self.tabmemo, QtCore.SIGNAL('windowClosed()'), self, QtCore.SLOT('memoTabsClosed()')) - def newMemo(self, channel, timestr): + def newMemo(self, channel, timestr, secret=False): if channel == "#pesterchum": return if self.memos.has_key(channel): @@ -820,6 +847,10 @@ class PesterWindow(MovingWindow): # chat client send memo open self.memos[channel] = memoWindow self.joinChannel.emit(channel) # race condition? + self.secret = secret + if self.secret: + self.secret = True + self.setChannelMode.emit(channel, "+s", "") memoWindow.sendTimeInfo() memoWindow.show() @@ -845,7 +876,10 @@ class PesterWindow(MovingWindow): self.resize(*theme["main/size"]) self.setWindowIcon(PesterIcon(theme["main/icon"])) self.setWindowTitle(theme["main/windowtitle"]) - self.setStyleSheet("QFrame#main { "+theme["main/style"]+" }") + self.setStyleSheet("QFrame#main { %s }" % (theme["main/style"])) + self.backgroundImage = QtGui.QPixmap(theme["main/background-image"]) + self.backgroundMask = self.backgroundImage.mask() + self.setMask(self.backgroundMask) self.menu.setStyleSheet("QMenuBar { background: transparent; %s } QMenuBar::item { background: transparent; %s } " % (theme["main/menubar/style"], theme["main/menu/menuitem"]) + "QMenu { background: transparent; %s } QMenu::item::selected { %s }" % (theme["main/menu/style"], theme["main/menu/selected"])) newcloseicon = PesterIcon(theme["main/close/image"]) self.closeButton.setIcon(newcloseicon) @@ -861,6 +895,7 @@ class PesterWindow(MovingWindow): self.exitaction.setText(theme["main/menus/client/exit"]) self.userlistaction.setText(theme["main/menus/client/userlist"]) self.memoaction.setText(theme["main/menus/client/memos"]) + self.importaction.setText(theme["main/menus/client/import"]) self.filemenu.setTitle(theme["main/menus/client/_name"]) self.changetheme.setText(theme["main/menus/profile/theme"]) self.changequirks.setText(theme["main/menus/profile/quirks"]) @@ -879,18 +914,27 @@ class PesterWindow(MovingWindow): self.moods = PesterMoodHandler(self, *[PesterMoodButton(self, **d) for d in theme["main/moods"]]) self.moods.showButtons() # chum + addChumStyle = "QPushButton { %s }" % (theme["main/addchum/style"]) + if theme.has_key("main/addchum/pressed"): + addChumStyle += "QPushButton:pressed { %s }" % (theme["main/addchum/pressed"]) + pesterButtonStyle = "QPushButton { %s }" % (theme["main/pester/style"]) + if theme.has_key("main/pester/pressed"): + pesterButtonStyle += "QPushButton:pressed { %s }" % (theme["main/pester/pressed"]) + blockButtonStyle = "QPushButton { %s }" % (theme["main/block/style"]) + if theme.has_key("main/block/pressed"): + pesterButtonStyle += "QPushButton:pressed { %s }" % (theme["main/block/pressed"]) self.addChumButton.setText(theme["main/addchum/text"]) self.addChumButton.resize(*theme["main/addchum/size"]) self.addChumButton.move(*theme["main/addchum/loc"]) - self.addChumButton.setStyleSheet(theme["main/addchum/style"]) + self.addChumButton.setStyleSheet(addChumStyle) self.pesterButton.setText(theme["main/pester/text"]) self.pesterButton.resize(*theme["main/pester/size"]) self.pesterButton.move(*theme["main/pester/loc"]) - self.pesterButton.setStyleSheet(theme["main/pester/style"]) + self.pesterButton.setStyleSheet(pesterButtonStyle) self.blockButton.setText(theme["main/block/text"]) self.blockButton.resize(*theme["main/block/size"]) self.blockButton.move(*theme["main/block/loc"]) - self.blockButton.setStyleSheet(theme["main/block/style"]) + self.blockButton.setStyleSheet(blockButtonStyle) # buttons self.mychumhandleLabel.setText(theme["main/mychumhandle/label/text"]) self.mychumhandleLabel.move(*theme["main/mychumhandle/label/loc"]) @@ -902,6 +946,18 @@ class PesterWindow(MovingWindow): self.mychumcolor.resize(*theme["main/mychumhandle/colorswatch/size"]) self.mychumcolor.move(*theme["main/mychumhandle/colorswatch/loc"]) self.mychumcolor.setStyleSheet("background: %s" % (self.profile().colorhtml())) + if self.theme.has_key("main/mychumhandle/currentMood"): + moodicon = self.profile().mood.icon(theme) + self.currentMoodIcon = QtGui.QLabel(self) + self.currentMoodIcon.setPixmap(moodicon.pixmap(moodicon.realsize())) + self.currentMoodIcon.move(*theme["main/mychumhandle/currentMood"]) + self.currentMoodIcon.show() + else: + if hasattr(self, 'currentMoodIcon') and self.currentMoodIcon: + self.currentMoodIcon.hide() + self.currentMoodIcon = None + + if theme["main/mychumhandle/colorswatch/text"]: self.mychumcolor.setText(theme["main/mychumhandle/colorswatch/text"]) @@ -915,6 +971,8 @@ class PesterWindow(MovingWindow): self.theme = theme # do self self.initTheme(theme) + # set mood + self.moods.updateMood(theme['main/defaultmood']) # chum area self.chumList.changeTheme(theme) # do open windows @@ -1136,12 +1194,22 @@ class PesterWindow(MovingWindow): self.unblockedChum.emit(handle) @QtCore.pyqtSlot() - def showMemos(self): + def importExternalConfig(self): + f = QtGui.QFileDialog.getOpenFileName(self) + fp = open(f, 'r') + for l in fp.xreadlines(): + # import chumlist + chum_mo = re.match("handle: ([A-Za-z0-9]+)", l) + if chum_mo is not None: + chum = PesterProfile(chum_mo.group(1)) + self.addChum(chum) + @QtCore.pyqtSlot() + def showMemos(self, channel=""): if not hasattr(self, 'memochooser'): self.memochooser = None if self.memochooser: return - self.memochooser = PesterMemoList(self) + self.memochooser = PesterMemoList(self, channel) self.connect(self.memochooser, QtCore.SIGNAL('accepted()'), self, QtCore.SLOT('joinSelectedMemo()')) self.connect(self.memochooser, QtCore.SIGNAL('rejected()'), @@ -1153,9 +1221,11 @@ class PesterWindow(MovingWindow): newmemo = self.memochooser.newmemoname() selectedmemo = self.memochooser.selectedmemo() time = unicode(self.memochooser.timeinput.text()) + secret = self.memochooser.secretChannel.isChecked() if newmemo: channel = "#"+unicode(newmemo).replace(" ", "_") - self.newMemo(channel, time) + channel = re.sub(r"[^A-Za-z0-9#_]", "", channel) + self.newMemo(channel, time, secret=secret) elif selectedmemo: channel = "#"+unicode(selectedmemo.text()) self.newMemo(channel, time) @@ -1415,6 +1485,7 @@ class PesterWindow(MovingWindow): kickUser = QtCore.pyqtSignal(QtCore.QString, QtCore.QString) joinChannel = QtCore.pyqtSignal(QtCore.QString) leftChannel = QtCore.pyqtSignal(QtCore.QString) + setChannelMode = QtCore.pyqtSignal(QtCore.QString, QtCore.QString, QtCore.QString) class IRCThread(QtCore.QThread): def __init__(self, ircobj): @@ -1422,8 +1493,12 @@ class IRCThread(QtCore.QThread): self.irc = ircobj def run(self): irc = self.irc + irc.IRCConnect() while 1: - irc.updateIRC() + try: + irc.updateIRC() + except socket.error: + self.exit(1) class PesterTray(QtGui.QSystemTrayIcon): def __init__(self, icon, mainwindow, parent): @@ -1440,134 +1515,161 @@ class PesterTray(QtGui.QSystemTrayIcon): else: self.setIcon(PesterIcon(self.mainwindow.theme["main/newmsgicon"])) -def main(): +class MainProgram(QtCore.QObject): + def __init__(self): + QtCore.QObject.__init__(self) + self.app = QtGui.QApplication(sys.argv) + if pygame.mixer: + # we could set the frequency higher but i love how cheesy it sounds + try: + pygame.mixer.init() + except pygame.error, e: + print "Warning: No sound! %s" % (e) + else: + print "Warning: No sound!" + self.widget = PesterWindow() + self.widget.show() - app = QtGui.QApplication(sys.argv) - if pygame.mixer: - # we could set the frequency higher but i love how cheesy it sounds - pygame.mixer.init() - else: - print "Warning: No sound!" - widget = PesterWindow() - widget.show() + self.trayicon = PesterTray(PesterIcon(self.widget.theme["main/icon"]), self.widget, self.app) + self.trayicon.show() + self.trayicon.connect(self.trayicon, + QtCore.SIGNAL('activated(QSystemTrayIcon::ActivationReason)'), + self.widget, + QtCore.SLOT('systemTrayActivated(QSystemTrayIcon::ActivationReason)')) + self.trayicon.connect(self.widget, + QtCore.SIGNAL('trayIconSignal(int)'), + self.trayicon, + QtCore.SLOT('changeTrayIcon(int)')) - trayicon = PesterTray(PesterIcon(widget.theme["main/icon"]), widget, app) - trayicon.show() - - trayicon.connect(trayicon, - QtCore.SIGNAL('activated(QSystemTrayIcon::ActivationReason)'), - widget, - QtCore.SLOT('systemTrayActivated(QSystemTrayIcon::ActivationReason)')) - trayicon.connect(widget, - QtCore.SIGNAL('trayIconSignal(int)'), - trayicon, - QtCore.SLOT('changeTrayIcon(int)')) - - - irc = PesterIRC(widget) - irc.IRCConnect() - irc.connect(widget, QtCore.SIGNAL('sendMessage(QString, QString)'), - irc, QtCore.SLOT('sendMessage(QString, QString)')) - irc.connect(widget, - QtCore.SIGNAL('newConvoStarted(QString, bool)'), - irc, QtCore.SLOT('startConvo(QString, bool)')) - irc.connect(widget, - QtCore.SIGNAL('convoClosed(QString)'), - irc, QtCore.SLOT('endConvo(QString)')) - irc.connect(widget, - QtCore.SIGNAL('profileChanged()'), - irc, - QtCore.SLOT('updateProfile()')) - irc.connect(widget, - QtCore.SIGNAL('moodRequest(PyQt_PyObject)'), - irc, - QtCore.SLOT('getMood(PyQt_PyObject)')) - irc.connect(widget, - QtCore.SIGNAL('moodsRequest(PyQt_PyObject)'), - irc, - QtCore.SLOT('getMoods(PyQt_PyObject)')) - irc.connect(widget, - QtCore.SIGNAL('moodUpdated()'), - irc, - QtCore.SLOT('updateMood()')) - irc.connect(widget, - QtCore.SIGNAL('mycolorUpdated()'), - irc, - QtCore.SLOT('updateColor()')) - irc.connect(widget, - QtCore.SIGNAL('blockedChum(QString)'), - irc, - QtCore.SLOT('blockedChum(QString)')) - irc.connect(widget, - QtCore.SIGNAL('unblockedChum(QString)'), - irc, - QtCore.SLOT('unblockedChum(QString)')) - irc.connect(widget, - QtCore.SIGNAL('requestNames(QString)'), - irc, - QtCore.SLOT('requestNames(QString)')) - irc.connect(widget, - QtCore.SIGNAL('requestChannelList()'), - irc, - QtCore.SLOT('requestChannelList()')) - irc.connect(widget, - QtCore.SIGNAL('joinChannel(QString)'), - irc, - QtCore.SLOT('joinChannel(QString)')) - irc.connect(widget, - QtCore.SIGNAL('leftChannel(QString)'), - irc, - QtCore.SLOT('leftChannel(QString)')) - irc.connect(widget, - QtCore.SIGNAL('kickUser(QString, QString)'), - irc, - QtCore.SLOT('kickUser(QString, QString)')) + self.irc = PesterIRC(self.widget) + self.connectWidgets(self.irc, self.widget) + self.ircapp = IRCThread(self.irc) + self.connect(self.ircapp, QtCore.SIGNAL('finished()'), + self, QtCore.SLOT('restartIRC()')) -# IRC --> Main window - irc.connect(irc, QtCore.SIGNAL('connected()'), - widget, QtCore.SLOT('connected()')) - irc.connect(irc, - QtCore.SIGNAL('moodUpdated(QString, PyQt_PyObject)'), - widget, - QtCore.SLOT('updateMoodSlot(QString, PyQt_PyObject)')) - irc.connect(irc, - QtCore.SIGNAL('colorUpdated(QString, QColor)'), - widget, - QtCore.SLOT('updateColorSlot(QString, QColor)')) - irc.connect(irc, - QtCore.SIGNAL('messageReceived(QString, QString)'), - widget, - QtCore.SLOT('deliverMessage(QString, QString)')) - irc.connect(irc, - QtCore.SIGNAL('memoReceived(QString, QString, QString)'), - widget, - QtCore.SLOT('deliverMemo(QString, QString, QString)')) - irc.connect(irc, - QtCore.SIGNAL('nickCollision(QString, QString)'), - widget, - QtCore.SLOT('nickCollision(QString, QString)')) - irc.connect(irc, - QtCore.SIGNAL('namesReceived(QString, PyQt_PyObject)'), - widget, - QtCore.SLOT('updateNames(QString, PyQt_PyObject)')) - irc.connect(irc, - QtCore.SIGNAL('userPresentUpdate(QString, QString, QString)'), - widget, - QtCore.SLOT('userPresentUpdate(QString, QString, QString)')) - irc.connect(irc, - QtCore.SIGNAL('channelListReceived(PyQt_PyObject)'), - widget, - QtCore.SLOT('updateChannelList(PyQt_PyObject)')) - irc.connect(irc, - QtCore.SIGNAL('timeCommand(QString, QString, QString)'), - widget, - QtCore.SLOT('timeCommand(QString, QString, QString)')) + def connectWidgets(self, irc, widget): + irc.connect(widget, QtCore.SIGNAL('sendMessage(QString, QString)'), + irc, QtCore.SLOT('sendMessage(QString, QString)')) + irc.connect(widget, + QtCore.SIGNAL('newConvoStarted(QString, bool)'), + irc, QtCore.SLOT('startConvo(QString, bool)')) + irc.connect(widget, + QtCore.SIGNAL('convoClosed(QString)'), + irc, QtCore.SLOT('endConvo(QString)')) + irc.connect(widget, + QtCore.SIGNAL('profileChanged()'), + irc, + QtCore.SLOT('updateProfile()')) + irc.connect(widget, + QtCore.SIGNAL('moodRequest(PyQt_PyObject)'), + irc, + QtCore.SLOT('getMood(PyQt_PyObject)')) + irc.connect(widget, + QtCore.SIGNAL('moodsRequest(PyQt_PyObject)'), + irc, + QtCore.SLOT('getMoods(PyQt_PyObject)')) + irc.connect(widget, + QtCore.SIGNAL('moodUpdated()'), + irc, + QtCore.SLOT('updateMood()')) + irc.connect(widget, + QtCore.SIGNAL('mycolorUpdated()'), + irc, + QtCore.SLOT('updateColor()')) + irc.connect(widget, + QtCore.SIGNAL('blockedChum(QString)'), + irc, + QtCore.SLOT('blockedChum(QString)')) + irc.connect(widget, + QtCore.SIGNAL('unblockedChum(QString)'), + irc, + QtCore.SLOT('unblockedChum(QString)')) + irc.connect(widget, + QtCore.SIGNAL('requestNames(QString)'), + irc, + QtCore.SLOT('requestNames(QString)')) + irc.connect(widget, + QtCore.SIGNAL('requestChannelList()'), + irc, + QtCore.SLOT('requestChannelList()')) + irc.connect(widget, + QtCore.SIGNAL('joinChannel(QString)'), + irc, + QtCore.SLOT('joinChannel(QString)')) + irc.connect(widget, + QtCore.SIGNAL('leftChannel(QString)'), + irc, + QtCore.SLOT('leftChannel(QString)')) + irc.connect(widget, + QtCore.SIGNAL('kickUser(QString, QString)'), + irc, + QtCore.SLOT('kickUser(QString, QString)')) + irc.connect(widget, + QtCore.SIGNAL('setChannelMode(QString, QString, QString)'), + irc, + QtCore.SLOT('setChannelMode(QString, QString, QString)')) - ircapp = IRCThread(irc) - ircapp.start() - status = widget.loadingscreen.exec_() - if status == QtGui.QDialog.Rejected: - sys.exit(0) - sys.exit(app.exec_()) -main() + # IRC --> Main window + irc.connect(irc, QtCore.SIGNAL('connected()'), + widget, QtCore.SLOT('connected()')) + irc.connect(irc, + QtCore.SIGNAL('moodUpdated(QString, PyQt_PyObject)'), + widget, + QtCore.SLOT('updateMoodSlot(QString, PyQt_PyObject)')) + irc.connect(irc, + QtCore.SIGNAL('colorUpdated(QString, QColor)'), + widget, + QtCore.SLOT('updateColorSlot(QString, QColor)')) + irc.connect(irc, + QtCore.SIGNAL('messageReceived(QString, QString)'), + widget, + QtCore.SLOT('deliverMessage(QString, QString)')) + irc.connect(irc, + QtCore.SIGNAL('memoReceived(QString, QString, QString)'), + widget, + QtCore.SLOT('deliverMemo(QString, QString, QString)')) + irc.connect(irc, + QtCore.SIGNAL('nickCollision(QString, QString)'), + widget, + QtCore.SLOT('nickCollision(QString, QString)')) + irc.connect(irc, + QtCore.SIGNAL('namesReceived(QString, PyQt_PyObject)'), + widget, + QtCore.SLOT('updateNames(QString, PyQt_PyObject)')) + irc.connect(irc, + QtCore.SIGNAL('userPresentUpdate(QString, QString, QString)'), + widget, + QtCore.SLOT('userPresentUpdate(QString, QString, QString)')) + irc.connect(irc, + QtCore.SIGNAL('channelListReceived(PyQt_PyObject)'), + widget, + QtCore.SLOT('updateChannelList(PyQt_PyObject)')) + irc.connect(irc, + QtCore.SIGNAL('timeCommand(QString, QString, QString)'), + widget, + QtCore.SLOT('timeCommand(QString, QString, QString)')) + + @QtCore.pyqtSlot() + def restartIRC(self): + self.widget.show() + self.widget.activateWindow() + self.irc = PesterIRC(self.widget) + self.connectWidgets(self.irc, self.widget) + self.ircapp = IRCThread(self.irc) + self.connect(self.ircapp, QtCore.SIGNAL('finished()'), + self, QtCore.SLOT('restartIRC()')) + self.ircapp.start() + status = self.widget.loadingscreen.exec_() + if status == QtGui.QDialog.Rejected: + sys.exit(0) + + def run(self): + self.ircapp.start() + status = self.widget.loadingscreen.exec_() + if status == QtGui.QDialog.Rejected: + sys.exit(0) + sys.exit(self.app.exec_()) + +pesterchum = MainProgram() +pesterchum.run() diff --git a/profiles/ghostDunk.js b/profiles/ghostDunk.js index 43ce8df..7c7adc1 100644 --- a/profiles/ghostDunk.js +++ b/profiles/ghostDunk.js @@ -1 +1 @@ -{"color": "#ff00ff", "theme": "trollian", "quirks": [], "handle": "ghostDunk"} \ No newline at end of file +{"color": "#ff00ff", "theme": "pesterchum7", "quirks": [], "handle": "ghostDunk"} \ No newline at end of file diff --git a/profiles/microMachines.js b/profiles/microMachines.js new file mode 100644 index 0000000..52c0648 --- /dev/null +++ b/profiles/microMachines.js @@ -0,0 +1 @@ +{"color": "#aa00ff", "theme": "pesterchum", "quirks": [], "handle": "microMachines"} \ No newline at end of file diff --git a/profiles/testProfile.js b/profiles/testProfile.js index 223100d..e63a331 100644 --- a/profiles/testProfile.js +++ b/profiles/testProfile.js @@ -1 +1 @@ -{"color": "#aa00ff", "theme": "trollian", "quirks": [], "handle": "testProfile"} \ No newline at end of file +{"color": "#aa00ff", "theme": "pesterchum", "quirks": [], "handle": "testProfile"} \ No newline at end of file diff --git a/themes/pesterchum/style.js b/themes/pesterchum/style.js index 2bfe997..aea785d 100644 --- a/themes/pesterchum/style.js +++ b/themes/pesterchum/style.js @@ -1,5 +1,6 @@ {"main": - {"style": "background-image:url($path/pcbg.png); background-repeat: no-repeat;", + {"style": "background-repeat: no-repeat;", + "background-image": "$path/pcbg.png", "size": [232, 380], "icon": "$path/trayicon.png", "newmsgicon": "$path/trayicon2.png", @@ -19,6 +20,7 @@ "options": "OPTIONS", "memos": "MEMOS", "userlist": "USERLIST", + "import": "IMPORT", "exit": "EXIT"}, "profile": {"_name": "PROFILE", "switch": "SWITCH", @@ -31,7 +33,8 @@ "blockchum": "BLOCK", "addchum": "ADD CHUM", "unblockchum": "UNBLOCK", - "banuser": "BAN USER" + "banuser": "BAN USER", + "quirksoff": "QUIRKS OFF" } }, "chums": { "style": "border:2px solid yellow; background-color: black;color: white;font: bold;font-family: 'Courier';selection-background-color:#646464; ", @@ -94,13 +97,14 @@ }, "mychumhandle": { "label": { "text": "CHUMHANDLE:", "loc": [19,232], - "style": "color: rgba(255, 255, 0, 0%) ;font:bold; font-family: 'Courier';" }, + "style": "color: rgba(255, 255, 0, 0%) ;font:bold; font-family: 'Courier';" }, "handle": { "style": "background: black; padding: 3px; color:white; font-family:'Courier'; font:bold; text-align:left;", - "loc": [14,246], + "loc": [36,246], "size": [190, 21] }, "colorswatch": { "loc": [196,246], "size": [23,21], - "text": "" } + "text": "" }, + "currentMood": [18, 249] }, "defaultwindow": { "style": "background: #fdb302; font-family:'Courier';font:bold;selection-background-color:#919191; " }, @@ -110,6 +114,7 @@ "text": "" }, "pester": { "style": "background: rgba(255, 255, 0, 0%); border:2px solid #c48a00; font: bold; color: rgba(255, 255, 0, 0%); font-family:'Courier';", + "pressed" : "background: rgb(255, 255, 255, 30%);", "loc": [150,202], "size": [71, 22], "text": "" @@ -185,16 +190,17 @@ }, "convo": {"style": "background-color: #fdb302; background-image:url($path/convobg.png); background-repeat: no-repeat; border:2px solid yellow; font-family: 'Courier'", + "scrollbar": { "style" : "", "handle": "" }, "margins": {"top": 0, "bottom": 6, "left": 0, "right": 0 }, - "size": [400, 250], - "chumlabel": { "style": "background: rgb(196, 138, 0); color: white; border:0px; font-size: 12px;", + "size": [520, 325], + "chumlabel": { "style": "background: rgb(196, 138, 0); color: white; border:0px; font-size: 14px;", "align": { "h": "center", "v": "center" }, "minheight": 26, "maxheight": 26, "text" : ":: $handle ::" }, "textarea": { - "style": "background: white; font:bold; border:2px solid #c48a00;text-align:center; margin-top:21px; margin-right:10px; margin-left:10px; font-size: 12px;" + "style": "background: white; font:bold; border:2px solid #c48a00;text-align:center; margin-top:21px; margin-right:10px; margin-left:10px; font-size: 14px;" }, "input": { "style": "background: white; border:2px solid #c48a00;margin-top:3px; margin-right:10px; margin-left:10px; font-size: 12px;" diff --git a/themes/pesterchum7/abouticon.png b/themes/pesterchum7/abouticon.png new file mode 100644 index 0000000..02fa887 Binary files /dev/null and b/themes/pesterchum7/abouticon.png differ diff --git a/themes/pesterchum7/acceptant.gif b/themes/pesterchum7/acceptant.gif new file mode 100644 index 0000000..f549f70 Binary files /dev/null and b/themes/pesterchum7/acceptant.gif differ diff --git a/themes/pesterchum7/alarm.wav b/themes/pesterchum7/alarm.wav new file mode 100644 index 0000000..910abdc Binary files /dev/null and b/themes/pesterchum7/alarm.wav differ diff --git a/themes/pesterchum7/amazed.gif b/themes/pesterchum7/amazed.gif new file mode 100644 index 0000000..9c2f1e6 Binary files /dev/null and b/themes/pesterchum7/amazed.gif differ diff --git a/themes/pesterchum7/bemused.gif b/themes/pesterchum7/bemused.gif new file mode 100644 index 0000000..15a9813 Binary files /dev/null and b/themes/pesterchum7/bemused.gif differ diff --git a/themes/pesterchum7/blocked.gif b/themes/pesterchum7/blocked.gif new file mode 100644 index 0000000..5031b07 Binary files /dev/null and b/themes/pesterchum7/blocked.gif differ diff --git a/themes/pesterchum7/chummy.gif b/themes/pesterchum7/chummy.gif new file mode 100644 index 0000000..26c9ad3 Binary files /dev/null and b/themes/pesterchum7/chummy.gif differ diff --git a/themes/pesterchum7/convobg.png b/themes/pesterchum7/convobg.png new file mode 100644 index 0000000..7907669 Binary files /dev/null and b/themes/pesterchum7/convobg.png differ diff --git a/themes/pesterchum7/detestful.gif b/themes/pesterchum7/detestful.gif new file mode 100644 index 0000000..c050d31 Binary files /dev/null and b/themes/pesterchum7/detestful.gif differ diff --git a/themes/pesterchum7/devious.gif b/themes/pesterchum7/devious.gif new file mode 100644 index 0000000..06ba8be Binary files /dev/null and b/themes/pesterchum7/devious.gif differ diff --git a/themes/pesterchum7/discontent.gif b/themes/pesterchum7/discontent.gif new file mode 100644 index 0000000..addcf54 Binary files /dev/null and b/themes/pesterchum7/discontent.gif differ diff --git a/themes/pesterchum7/distraught.gif b/themes/pesterchum7/distraught.gif new file mode 100644 index 0000000..0103ac5 Binary files /dev/null and b/themes/pesterchum7/distraught.gif differ diff --git a/themes/pesterchum7/ecstatic.gif b/themes/pesterchum7/ecstatic.gif new file mode 100644 index 0000000..dc3ee61 Binary files /dev/null and b/themes/pesterchum7/ecstatic.gif differ diff --git a/themes/pesterchum7/gbgbig.png b/themes/pesterchum7/gbgbig.png new file mode 100644 index 0000000..cb9bcc7 Binary files /dev/null and b/themes/pesterchum7/gbgbig.png differ diff --git a/themes/pesterchum7/h.gif b/themes/pesterchum7/h.gif new file mode 100644 index 0000000..184514e Binary files /dev/null and b/themes/pesterchum7/h.gif differ diff --git a/themes/pesterchum7/insolent.gif b/themes/pesterchum7/insolent.gif new file mode 100644 index 0000000..d642481 Binary files /dev/null and b/themes/pesterchum7/insolent.gif differ diff --git a/themes/pesterchum7/leftarrow.png b/themes/pesterchum7/leftarrow.png new file mode 100644 index 0000000..4caf00b Binary files /dev/null and b/themes/pesterchum7/leftarrow.png differ diff --git a/themes/pesterchum7/m.gif b/themes/pesterchum7/m.gif new file mode 100644 index 0000000..3f6c396 Binary files /dev/null and b/themes/pesterchum7/m.gif differ diff --git a/themes/pesterchum7/manipulative.gif b/themes/pesterchum7/manipulative.gif new file mode 100644 index 0000000..642d988 Binary files /dev/null and b/themes/pesterchum7/manipulative.gif differ diff --git a/themes/pesterchum7/memo.png b/themes/pesterchum7/memo.png new file mode 100644 index 0000000..92fd30a Binary files /dev/null and b/themes/pesterchum7/memo.png differ diff --git a/themes/pesterchum7/mirthful.gif b/themes/pesterchum7/mirthful.gif new file mode 100644 index 0000000..cbf895c Binary files /dev/null and b/themes/pesterchum7/mirthful.gif differ diff --git a/themes/pesterchum7/moodcheck1.gif b/themes/pesterchum7/moodcheck1.gif new file mode 100644 index 0000000..0804f90 Binary files /dev/null and b/themes/pesterchum7/moodcheck1.gif differ diff --git a/themes/pesterchum7/moodcheck2.gif b/themes/pesterchum7/moodcheck2.gif new file mode 100644 index 0000000..d646f21 Binary files /dev/null and b/themes/pesterchum7/moodcheck2.gif differ diff --git a/themes/pesterchum7/moodcheck3.gif b/themes/pesterchum7/moodcheck3.gif new file mode 100644 index 0000000..f88321b Binary files /dev/null and b/themes/pesterchum7/moodcheck3.gif differ diff --git a/themes/pesterchum7/moodcheck4.gif b/themes/pesterchum7/moodcheck4.gif new file mode 100644 index 0000000..4cea74f Binary files /dev/null and b/themes/pesterchum7/moodcheck4.gif differ diff --git a/themes/pesterchum7/moodcheck5.gif b/themes/pesterchum7/moodcheck5.gif new file mode 100644 index 0000000..40ba9a1 Binary files /dev/null and b/themes/pesterchum7/moodcheck5.gif differ diff --git a/themes/pesterchum7/mystified.gif b/themes/pesterchum7/mystified.gif new file mode 100644 index 0000000..56341d6 Binary files /dev/null and b/themes/pesterchum7/mystified.gif differ diff --git a/themes/pesterchum7/offline.gif b/themes/pesterchum7/offline.gif new file mode 100644 index 0000000..e3c6b53 Binary files /dev/null and b/themes/pesterchum7/offline.gif differ diff --git a/themes/pesterchum7/pcbg.png b/themes/pesterchum7/pcbg.png new file mode 100644 index 0000000..688eab7 Binary files /dev/null and b/themes/pesterchum7/pcbg.png differ diff --git a/themes/pesterchum7/perky.gif b/themes/pesterchum7/perky.gif new file mode 100644 index 0000000..1d19661 Binary files /dev/null and b/themes/pesterchum7/perky.gif differ diff --git a/themes/pesterchum7/pleasant.gif b/themes/pesterchum7/pleasant.gif new file mode 100644 index 0000000..3233ff4 Binary files /dev/null and b/themes/pesterchum7/pleasant.gif differ diff --git a/themes/pesterchum7/pranky.gif b/themes/pesterchum7/pranky.gif new file mode 100644 index 0000000..e46e45e Binary files /dev/null and b/themes/pesterchum7/pranky.gif differ diff --git a/themes/pesterchum7/rancorous.gif b/themes/pesterchum7/rancorous.gif new file mode 100644 index 0000000..a826c75 Binary files /dev/null and b/themes/pesterchum7/rancorous.gif differ diff --git a/themes/pesterchum7/relaxed.gif b/themes/pesterchum7/relaxed.gif new file mode 100644 index 0000000..55a31a0 Binary files /dev/null and b/themes/pesterchum7/relaxed.gif differ diff --git a/themes/pesterchum7/rightarrow.png b/themes/pesterchum7/rightarrow.png new file mode 100644 index 0000000..30a8b70 Binary files /dev/null and b/themes/pesterchum7/rightarrow.png differ diff --git a/themes/pesterchum7/sleek.gif b/themes/pesterchum7/sleek.gif new file mode 100644 index 0000000..5573aa5 Binary files /dev/null and b/themes/pesterchum7/sleek.gif differ diff --git a/themes/pesterchum7/smooth.gif b/themes/pesterchum7/smooth.gif new file mode 100644 index 0000000..a261759 Binary files /dev/null and b/themes/pesterchum7/smooth.gif differ diff --git a/themes/pesterchum7/style.js b/themes/pesterchum7/style.js new file mode 100644 index 0000000..b43121b --- /dev/null +++ b/themes/pesterchum7/style.js @@ -0,0 +1,259 @@ +{"main": + {"style": "background-repeat: no-repeat;background-color:transparent;", + "background-image": "$path/gbgbig.png", + "size": [400, 348], + "icon": "$path/trayicon.png", + "newmsgicon": "$path/trayicon2.png", + "windowtitle": "PESTERCHUM", + "close": { "image": "$path/x.gif", + "loc": [378, 30]}, + "minimize": { "image": "$path/m.gif", + "loc": [358, 25]}, + "menubar": { "style": "font-family: 'Courier'; font:bold; font-size: 12px;" }, + "menu" : { "style": "font-family: 'Courier'; font: bold; font-size: 12px; background-color: #fdb302;border:2px solid #ffff00", + "menuitem": "margin-right:10px;", + "selected": "background-color: #ffff00", + "loc": [120,25] + }, + "sounds": { "alertsound": "$path/alarm.wav" }, + "menus": {"client": {"_name": "CLIENT", + "options": "OPTIONS", + "memos": "MEMOS", + "userlist": "USERLIST", + "import": "IMPORT", + "exit": "EXIT"}, + "profile": {"_name": "PROFILE", + "switch": "SWITCH", + "color": "COLOR", + "theme": "THEME", + "block": "TROLLSLUM", + "quirks": "QUIRKS"}, + "rclickchumlist": {"pester": "PESTER", + "removechum": "REMOVE CHUM", + "blockchum": "BLOCK", + "addchum": "ADD CHUM", + "unblockchum": "UNBLOCK", + "banuser": "BAN USER" + } + }, + "chums": { "style": "border:2px solid yellow; background-color: black;color: white;font: bold;font-family: 'Courier';selection-background-color:#646464; ", + "loc": [12, 117], + "size": [209, 82], + "userlistcolor": "white", + "moods": { + +"chummy": { "icon": "$path/chummy.gif", "color": "white" }, + +"rancorous": { "icon": "$path/rancorous.gif", "color": "red" }, + +"offline": { "icon": "$path/offline.gif", "color": "#646464"}, + + +"pleasant": { "icon": "$path/pleasant.gif", "color": "white" }, + +"distraught": { "icon": "$path/distraught.gif", "color": "white" }, + +"unruly": { "icon": "$path/unruly.gif", "color": "white" }, + + +"smooth": { "icon": "$path/smooth.gif", "color": "white" }, + + +"ecstatic": { "icon": "$path/ecstatic.gif", "color": "red" }, + +"relaxed": { "icon": "$path/relaxed.gif", "color": "red" }, + +"discontent": { "icon": "$path/discontent.gif", "color": "red" }, + +"devious": { "icon": "$path/devious.gif", "color": "red" }, + +"sleek": { "icon": "$path/sleek.gif", "color": "red" }, + +"detestful": { "icon": "$path/detestful.gif", "color": "red" }, + +"mirthful": { "icon": "$path/mirthful.gif", "color": "red" }, + +"manipulative": { "icon": "$path/manipulative.gif", "color": "red" }, + +"vigorous": { "icon": "$path/vigorous.gif", "color": "red" }, + +"perky": { "icon": "$path/perky.gif", "color": "red" }, + +"acceptant": { "icon": "$path/acceptant.gif", "color": "red" }, + +"protective": { "icon": "$path/protective.gif", "color": "#00ff00" }, + +"blocked": { "icon": "$path/blocked.gif", "color": "black" } + + } + }, + "trollslum": { + "style": "background: #fdb302; border:2px solid yellow; font-family: 'Courier'", + "size": [195, 200], + "label": { "text": "TROLLSLUM", + "style": "color: rgba(0, 0, 0, 100%) ;font:bold; font-family: 'Courier';border:0px;" }, + "chumroll": {"style": "border:2px solid yellow; background-color: black;color: white;font: bold;font-family: 'Courier';selection-background-color:#646464; " } + }, + "mychumhandle": { "label": { "text": "CHUMHANDLE:", + "loc": [19,232], + "style": "color: rgba(255, 255, 0, 0%) ;font:bold; font-family: 'Courier';" }, + "handle": { "style": "background: black; padding: 3px; color:white; font-family:'Courier'; font:bold; text-align:left;", + "loc": [14,246], + "size": [190, 21] }, + "colorswatch": { "loc": [196,246], + "size": [23,21], + "text": "" } + }, + "defaultwindow": { "style": "background: #fdb302; font-family:'Courier';font:bold;selection-background-color:#919191; " + }, + "addchum": { "style": "background: rgba(255, 255, 0, 0%); border:2px solid #c48a00; font: bold; color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [12,202], + "size": [71, 22], + "text": "" + }, + "pester": { "style": "background: rgba(255, 255, 0, 0%); border:2px solid #c48a00; font: bold; color: rgba(255, 255, 0, 0%); font-family:'Courier';", + "loc": [150,202], + "size": [71, 22], + "text": "" + }, + "block": { "style": "background: rgba(255, 255, 0, 0%); border:2px solid #c48a00; font: bold; color: rgba(255, 255, 0, 0%); font-family:'Courier';", + "loc": [1500,202], + "size": [0, 0], + "text": "" + }, + "defaultmood": 0, + "moodlabel": { "style": "", + "loc": [20, 430], + "text": "MOODS" + }, + "moods": [ + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck1.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [12, 288], + "size": [104, 22], + "text": "CHUMMY", + "icon": "$path/chummy.gif", + "mood": 0 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck2.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [12, 308], + "size": [104, 22], + "text": "PALSY", + "icon": "$path/chummy.gif", + "mood": 3 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck3.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [12, 328], + "size": [104, 22], + "text": "CHIPPER", + "icon": "$path/chummy.gif", + "mood": 4 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck2.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [117, 288], + "size": [104, 22], + "text": "BULLY", + "icon": "$path/chummy.gif", + "mood": 5 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck2.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [117, 308], + "size": [104, 22], + "text": "PEPPY", + "icon": "$path/chummy.gif", + "mood": 6 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck4.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [117, 328], + "size": [104, 22], + "text": "RANCOROUS", + "icon": "$path/rancorous.gif", + "mood": 1 + }, + { "style": "text-align:left; border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier'", + "selected": "text-align:left; background-image:url($path/moodcheck5.gif); border:2px solid #c48a00; padding: 5px;color: rgba(0, 0, 0, 0%); font-family:'Courier';", + "loc": [12, 348], + "size": [209, 22], + "text": "ABSCOND", + "icon": "", + "mood": 2 + } + ] + }, + "convo": + {"style": "background-color: #fdb302; background-image:url($path/convobg.png); background-repeat: no-repeat; border:2px solid yellow; font-family: 'Courier'", + "margins": {"top": 0, "bottom": 6, "left": 0, "right": 0 }, + "size": [400, 250], + "chumlabel": { "style": "background: rgb(196, 138, 0); color: white; border:0px; font-size: 12px;", + "align": { "h": "center", "v": "center" }, + "minheight": 26, + "maxheight": 26, + "text" : ":: $handle ::" + }, + "textarea": { + "style": "background: white; font:bold; border:2px solid #c48a00;text-align:center; margin-top:21px; margin-right:10px; margin-left:10px; font-size: 12px;" + }, + "input": { + "style": "background: white; border:2px solid #c48a00;margin-top:3px; margin-right:10px; margin-left:10px; font-size: 12px;" + }, + "tabs": { + "style": "", + "selectedstyle": "", + "newmsgcolor": "#fdb302", + "tabstyle": 0 + }, + "text": { + "beganpester": "began pestering", + "ceasepester": "ceased pestering", + "blocked": "blocked", + "unblocked": "unblocked", + "openmemo": "opened memo on board", + "joinmemo": "responded to memo", + "closememo": "ceased responding to memo", + "kickedmemo": "You have been banned from this memo!" + }, + "systemMsgColor": "#646464" + }, + "memos": + {"memoicon": "$path/memo.png", + "style": "background-color: #fdb302; background-image:url($path/convobg.png); background-repeat: no-repeat; border:2px solid yellow; font-family: 'Courier'; font: bold; selection-background-color:#919191; ", + "size": [450,300], + "tabs": { + "style": "", + "selectedstyle": "", + "newmsgcolor": "#fdb302", + "tabstyle": 0 + }, + "label": { "text": "Bulletin Board: $channel", + "style": "background: rgb(196, 138, 0); color: white; border:0px; font-size: 12px;", + "align": { "h": "center", "v": "center" }, + "minheight": 26, + "maxheight": 26 + }, + "input": { "style": "background: white; border:2px solid #c48a00;margin-top:5px; font-size: 12px; margin-left:10px;" }, + "textarea": { "style": "background: white; font:bold; border:2px solid #c48a00;text-align:center; font-size: 12px; margin-top: 21px; margin-left:10px;" }, + "margins": {"top": 0, "bottom": 6, "left": 0, "right": 0 }, + "userlist": { "width": 150, + "style": "border:2px solid #c48a00; background: white;font: bold;font-family: 'Courier';selection-background-color:#646464; font-size: 12px; margin-left:10px; margin-right:10px; margin-top: 21px;" + }, + "time": { "text": { "width": 75, + "style": " border: 2px solid yellow; background: white; font-size: 12px; margin-top: 5px; margin-right: 5px; margin-left: 5px;" + }, + "slider": { "style": "border: 0px;", + "groove": "", + "handle": "" + }, + "buttons": { "style": "color: black; font: bold; border: 2px solid #c48a00; font: bold; font-size: 12px; background: yellow; margin-top: 5px; margin-right: 5px; margin-left: 5px; padding: 2px; width: 50px;" }, + "arrows": { "left": "$path/leftarrow.png", + "right": "$path/rightarrow.png", + "style": " border:0px; margin-top: 5px; margin-right:10px;" + } + }, + "systemMsgColor": "#646464" + } +} \ No newline at end of file diff --git a/themes/pesterchum7/trayicon.gif b/themes/pesterchum7/trayicon.gif new file mode 100644 index 0000000..926ccc7 Binary files /dev/null and b/themes/pesterchum7/trayicon.gif differ diff --git a/themes/pesterchum7/trayicon.png b/themes/pesterchum7/trayicon.png new file mode 100644 index 0000000..817bf4b Binary files /dev/null and b/themes/pesterchum7/trayicon.png differ diff --git a/themes/pesterchum7/trayicon2.png b/themes/pesterchum7/trayicon2.png new file mode 100644 index 0000000..7b78586 Binary files /dev/null and b/themes/pesterchum7/trayicon2.png differ diff --git a/themes/pesterchum7/vigorous.gif b/themes/pesterchum7/vigorous.gif new file mode 100644 index 0000000..2408814 Binary files /dev/null and b/themes/pesterchum7/vigorous.gif differ diff --git a/themes/pesterchum7/x.gif b/themes/pesterchum7/x.gif new file mode 100644 index 0000000..6f29624 Binary files /dev/null and b/themes/pesterchum7/x.gif differ diff --git a/themes/trollian/style.js b/themes/trollian/style.js index b2f397e..c650963 100644 --- a/themes/trollian/style.js +++ b/themes/trollian/style.js @@ -1,5 +1,6 @@ {"main": - {"style": "background-image:url($path/tnbg2.png);background-color:rgba(0,0,0,0); background-repeat: no-repeat;", + {"style": "background-color:rgba(0,0,0,0); background-repeat: no-repeat;", + "background-image": "$path/tnbg2.png", "size": [650, 450], "icon": "$path/trayicon.png", "newmsgicon": "$path/trayicon2.png", @@ -19,6 +20,7 @@ "options": "Options", "memos": "Memos", "userlist": "Fresh Targets", + "import": "import U2;", "exit": "Abscond"}, "profile": {"_name": "View", "switch": "Trolltag", @@ -31,7 +33,8 @@ "blockchum": "Block", "addchum": "Add Chump", "unblockchum": "Mercy", - "banuser": "BAN USER" } + "banuser": "Ban", + "quirksoff": "Quirks Off" }, "chums": { "style": "font-size: 12px; background: white; border:2px solid #c2c2c2; padding: 5px; font-family: 'Arial';selection-background-color:rgb(200,200,200); ", "loc": [475, 89], @@ -233,6 +236,7 @@ }, "convo": {"style": "background: rgb(190, 19, 4); font-family: 'Arial';", + "scrollbar": { "style" : "", "handle": "" }, "margins": {"top": 22, "bottom": 9, "left": 10, "right": 4 }, "size": [400, 250], "chumlabel": { "style": "background: rgb(255, 38, 18); color: white; padding: 2px; border:1px solid #c2c2c2;",