comparison orpg/gametree/nodehandlers/forms.py @ 191:a3d7e05085da beta

Traipse Beta 'OpenRPG' {100201-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 (Beta) New Features: New Bookmarks Feature New 'boot' command to remote admin New confirmation window for sent nodes Miniatures Layer pop up box allows users to turn off Mini labels, from FlexiRPG New Zoom Mouse plugin added New Images added to Plugin UI Switching to Element Tree New Map efficiency, from FlexiRPG New Status Bar to Update Manager New TrueDebug Class in orpg_log (See documentation for usage) New Portable Mercurial New Tip of the Day, from Core and community New Reference Syntax added for custom PC sheets New Child Reference for gametree New Parent Reference for gametree New Gametree Recursion method, mapping, context sensitivity, and effeciency.. New Features node with bonus nodes and Node Referencing help added New Dieroller structure from Core New DieRoller portability for odd Dice New 7th Sea die roller; ie [7k3] = [7d10.takeHighest(3).open(10)] New 'Mythos' System die roller added New vs. die roller method for WoD; ie [3v3] = [3d10.vs(3)]. Included for Mythos roller also New Warhammer FRPG Die Roller (Special thanks to Puu-san for the support) New EZ_Tree Reference system. Push a button, Traipse the tree, get a reference (Beta!) New Grids act more like Spreadsheets in Use mode, with Auto Calc Fixes: Fix to allow for portability to an OpenSUSE linux OS Fix to mplay_client for Fedora and OpenSUSE Fix to Text based Server Fix to Remote Admin Commands Fix to Pretty Print, from Core Fix to Splitter Nodes not being created Fix to massive amounts of images loading, from Core Fix to Map from gametree not showing to all clients Fix to gametree about menus Fix to Password Manager check on startup Fix to PC Sheets from tool nodes. They now use the tabber_panel Fix to Whiteboard ID to prevent random line or text deleting. Fixes to Server, Remote Server, and Server GUI Fix to Update Manager; cleaner clode for saved repositories Fixes made to Settings Panel and now reactive settings when Ok is pressed Fixes to Alternity roller's attack roll. Uses a simple Tuple instead of a Splice Fix to Use panel of Forms and Tabbers. Now longer enters design mode Fix made Image Fetching. New fetching image and new failed image Fix to whiteboard ID's to prevent non updated clients from ruining the fix. default_manifest.xml renamed to default_upmana.xml
author sirebral
date Mon, 01 Feb 2010 09:57:07 -0600
parents dcae32e219f1
children 13054be69834
comparison
equal deleted inserted replaced
190:15488fe94f52 191:a3d7e05085da
31 from containers import * 31 from containers import *
32 import orpg.minidom as minidom 32 import orpg.minidom as minidom
33 from orpg.orpg_xml import xml 33 from orpg.orpg_xml import xml
34 from wx.lib.scrolledpanel import ScrolledPanel 34 from wx.lib.scrolledpanel import ScrolledPanel
35 from orpg.tools.settings import settings 35 from orpg.tools.settings import settings
36 from orpg.tools.InterParse import Parse
36 37
37 def bool2int(b): 38 def bool2int(b):
38 #in wxPython 2.5+, evt.Checked() returns True or False instead of 1.0 or 0. 39 #in wxPython 2.5+, evt.Checked() returns True or False instead of 1.0 or 0.
39 #by running the results of that through this function, we convert it. 40 #by running the results of that through this function, we convert it.
40 #if it was an int already, nothing changes. The difference between 1.0 41 #if it was an int already, nothing changes. The difference between 1.0
260 #txt = strip_text(txt) ##Does not seem to exist. 261 #txt = strip_text(txt) ##Does not seem to exist.
261 self.handler.text_elem.text = txt 262 self.handler.text_elem.text = txt
262 263
263 def on_send(self, evt): 264 def on_send(self, evt):
264 txt = self.text.GetValue() 265 txt = self.text.GetValue()
265 txt = self.chat.ParseMap(txt, self.handler.xml) 266 txt = Parse.NodeMap(txt, self.handler.xml)
266 txt = self.chat.ParseParent(txt, self.handler.xml.get('map')) 267 txt = Parse.NodeParent(txt, self.handler.xml.get('map'))
267 if not self.handler.is_raw_send(): 268 if not self.handler.is_raw_send():
268 self.chat.ParsePost(self.handler.tohtml(), True, True) 269 Parse.Post(self.handler.tohtml(), True, True)
269 return 1 270 return 1
270 actionlist = txt.split("\n") 271 actionlist = txt.split("\n")
271 for line in actionlist: 272 for line in actionlist:
272 if(line != ""): 273 if(line != ""):
273 if line[0] != "/": ## it's not a slash command 274 if line[0] != "/": ## it's not a slash command
274 self.chat.ParsePost(line, True, True) 275 Parse.Post(line, True, True)
275 else: 276 else:
276 action = line 277 action = line
277 self.chat.chat_cmds.docmd(action) 278 self.chat.chat_cmds.docmd(action)
278 return 1 279 return 1
279 280
593 def get_value(self): 594 def get_value(self):
594 return "\n".join(self.get_selections_text()) 595 return "\n".join(self.get_selections_text())
595 596
596 def on_send_to_chat(self, evt): 597 def on_send_to_chat(self, evt):
597 txt = self.get_selected_text() 598 txt = self.get_selected_text()
598 txt = self.chat.ParseMap(txt, self.xml) 599 txt = Parse.NodeMap(txt, self.xml)
599 txt = self.chat.ParseParent(txt, self.xml.get('map')) 600 txt = Parse.NodeParent(txt, self.xml.get('map'))
600 if not self.is_raw_send(): 601 if not self.is_raw_send():
601 self.chat.ParsePost(self.tohtml(), True, True) 602 Parse.Post(self.tohtml(), True, True)
602 return 1 603 return 1
603 actionlist = self.get_selections_text() 604 actionlist = self.get_selections_text()
604 for line in actionlist: 605 for line in actionlist:
605 line = self.chat.ParseMap(line, self.xml) 606 line = Parse.NodeMap(line, self.xml)
606 line = self.chat.ParseParent(line, self.xml.get('map')) 607 line = Parse.NodeParent(line, self.xml.get('map'))
607 if(line != ""): 608 if(line != ""):
608 if line[0] != "/": ## it's not a slash command 609 if line[0] != "/": ## it's not a slash command
609 self.chat.ParsePost(line, True, True) 610 Parse.Post(line, True, True)
610 else: 611 else:
611 action = line 612 action = line
612 self.chat.chat_cmds.docmd(action) 613 self.chat.chat_cmds.docmd(action)
613 return 1 614 return 1
614 615