Mercurial > traipse
comparison orpg/tools/aliaslib.py @ 36:d02e9197c066 ornery-orc
Traipse 'OpenRPG' {101220-00}
Traipse is a distribution of OpenRPG that is designed to be easy to setup and go. Traipse also makes it easy for developers to work on code without fear of sacrifice. 'Ornery-Orc' continues the trend of 'Grumpy' and adds fixes to the code. 'Ornery-Orc's main goal is to offer more advanced features and enhance the productivity of the user.
Update Summary (Closed)
New Features:
New to Map, can re-order Grid, Miniatures, and Whiteboard layer draw order
New to Server GUI, can now clear log
New Earthdawn Dieroller
New IronClaw roller, sheet, and image
New ShapeShifter PC Sheet
Updates:
Update to Warhammer PC Sheet. Rollers set as macros. Should work with little maintanence.
Update to Browser Server window. Display rooms with ' " & cleaner
Update to Server. Handles ' " & cleaner
Update to Dieroller. Cleaner, more effecient expression system
Update to Hidden Die plugin, allows for non standard dice rolls
Update to location.py, allows for more portable references when starting Traipse
Update to the Features node
Fixes:
Fix to InterParse that was causing an Infernal Loop with Namespace Internal
Fix to XML data, removed old Minidom and switched to Element Tree
Fix to Server that was causing eternal attempt to find a Server ID, in Register Rooms thread
Fix to Server, removing wxPython dependencies where not needed
Fix to metaservers.xml file not being created
Fix to Single and Double quotes in Whiteboard text
Fix to Background images not showing when using the Image Server
Fix to Duplicate chat names appearing
Fix to Server GUI's logging output
Fix to FNB.COLORFUL_TABS bug
Fix to Gametree for XSLT Sheets
Fix to Gametree for locating gametree files
Fix to Send to Chat from Gametree
Fix to Gametree, renaming and remapping operates correctly
Fix to aliaslib, prevents error caused when SafeHTML is sent None
author | sirebral |
---|---|
date | Sun, 19 Dec 2010 22:44:36 -0600 |
parents | fc48380f0c9f |
children |
comparison
equal
deleted
inserted
replaced
35:ee890f424e16 | 36:d02e9197c066 |
---|---|
471 alist.sort() | 471 alist.sort() |
472 self.aliasList = alist | 472 self.aliasList = alist |
473 filters = xml_dom.findall("filter") | 473 filters = xml_dom.findall("filter") |
474 flist = [] | 474 flist = [] |
475 self.regExList = [] | 475 self.regExList = [] |
476 for filter in filters: | 476 for f in filters: |
477 flist.append(filter.get("name")) | 477 flist.append(f.get("name")) |
478 rules = filter.findall("rule") | 478 rules = f.findall("rule") |
479 sub = [] | 479 sub = [] |
480 for rule in rules: sub.append([self.MakeSafeHTML(rule.get("match")), | 480 for rule in rules: |
481 sub.append([self.MakeSafeHTML(rule.get("match")), | |
481 self.MakeSafeHTML(rule.get("sub"))]) | 482 self.MakeSafeHTML(rule.get("sub"))]) |
482 self.regExList.append(sub) | 483 self.regExList.append(sub) |
483 self.filterList = flist | 484 self.filterList = flist |
484 self.alias = 0 | 485 self.alias = 0 |
485 self.filter = 0 | 486 self.filter = 0 |
486 | 487 |
487 def MakeSafeHTML(self, str): | 488 def MakeSafeHTML(self, s): |
488 return str.replace("&", "&").replace("<", "<").replace(""", '"').replace(">", ">").replace("'", "'") | 489 if s == None: return '' |
489 def MakeHTMLSafe(self, str): | 490 return s.replace("&", "&").replace("<", "<").replace(""", '"').replace(">", ">").replace("'", "'") |
490 return str.replace("&", "&").replace("<", "<").replace('"', """).replace(">", ">").replace("'", "'") | 491 |
492 def MakeHTMLSafe(self, s): | |
493 return s.replace("&", "&").replace("<", "<").replace('"', """).replace(">", ">").replace("'", "'") | |
494 | |
491 def ImportFromTree(self, xml_dom): | 495 def ImportFromTree(self, xml_dom): |
492 oldfilename = self.filename | 496 oldfilename = self.filename |
493 if xml_dom.get('name') == 'Alias Library': | 497 if xml_dom.get('name') == 'Alias Library': |
494 dlg = wx.TextEntryDialog(self, "Please Name This Alias Lib", "New Alias Lib") | 498 dlg = wx.TextEntryDialog(self, "Please Name This Alias Lib", "New Alias Lib") |
495 if dlg.ShowModal() == wx.ID_OK: | 499 if dlg.ShowModal() == wx.ID_OK: |