Browse Source

formatting

Dave Schuyler 20 years ago
parent
commit
ea53570eef

+ 2 - 2
direct/src/actor/Actor.py

@@ -47,7 +47,7 @@ class Actor(DirectObject, NodePath):
                 # part dictionary
                 # part dictionary
                 {"head":"char/dogMM/dogMM_Shorts-head-mod", \
                 {"head":"char/dogMM/dogMM_Shorts-head-mod", \
                  "torso":"char/dogMM/dogMM_Shorts-torso-mod", \
                  "torso":"char/dogMM/dogMM_Shorts-torso-mod", \
-                 "legs":"char/dogMM/dogMM_Shorts-legs-mod"} , \
+                 "legs":"char/dogMM/dogMM_Shorts-legs-mod"}, \
 
 
                 # dictionary of anim dictionaries
                 # dictionary of anim dictionaries
                 {"head":{"walk":"char/dogMM/dogMM_Shorts-head-walk", \
                 {"head":{"walk":"char/dogMM/dogMM_Shorts-head-walk", \
@@ -1275,7 +1275,7 @@ class Actor(DirectObject, NodePath):
         """
         """
         assert partName not in self.__subpartDict
         assert partName not in self.__subpartDict
 
 
-        Actor.notify.debug("in loadModel: %s , part: %s, lod: %s, copy: %s" % \
+        Actor.notify.debug("in loadModel: %s, part: %s, lod: %s, copy: %s" % \
             (modelPath, partName, lodName, copy))
             (modelPath, partName, lodName, copy))
 
 
         if isinstance(modelPath, NodePath):
         if isinstance(modelPath, NodePath):

+ 31 - 31
direct/src/directscripts/gendocs.py

@@ -601,37 +601,37 @@ class CodeDatabase:
 ########################################################################
 ########################################################################
 
 
 CLASS_RENAME_DICT = {
 CLASS_RENAME_DICT = {
- "Loader"                    : "PandaLoader" ,
- "String"                    : "CString" ,
- "LMatrix4f"                 : "Mat4" ,
- "LMatrix3f"                 : "Mat3" ,
- "LVecBase4f"                : "VBase4" ,
- "LVector4f"                 : "Vec4" ,
- "LPoint4f"                  : "Point4" ,
- "LVecBase3f"                : "VBase3" ,
- "LVector3f"                 : "Vec3" ,
- "LPoint3f"                  : "Point3" ,
- "LVecBase2f"                : "VBase2" ,
- "LVector2f"                 : "Vec2" ,
- "LPoint2f"                  : "Point2" ,
- "LQuaternionf"              : "Quat" ,
- "LMatrix4d"                 : "Mat4D" ,
- "LMatrix3d"                 : "Mat3D" ,
- "LVecBase4d"                : "VBase4D" ,
- "LVector4d"                 : "Vec4D" ,
- "LPoint4d"                  : "Point4D" ,
- "LVecBase3d"                : "VBase3D" ,
- "LVector3d"                 : "Vec3D" ,
- "LPoint3d"                  : "Point3D" ,
- "LVecBase2d"                : "VBase2D" ,
- "LVector2d"                 : "Vec2D" ,
- "LPoint2d"                  : "Point2D" ,
- "LQuaterniond"              : "QuatD" ,
- "Plane"                     : "PlaneBase" ,
- "Planef"                    : "Plane" ,
- "Planed"                    : "PlaneD" ,
- "Frustum"                   : "FrustumBase" ,
- "Frustumf"                  : "Frustum" ,
+ "Loader"                    : "PandaLoader",
+ "String"                    : "CString",
+ "LMatrix4f"                 : "Mat4",
+ "LMatrix3f"                 : "Mat3",
+ "LVecBase4f"                : "VBase4",
+ "LVector4f"                 : "Vec4",
+ "LPoint4f"                  : "Point4",
+ "LVecBase3f"                : "VBase3",
+ "LVector3f"                 : "Vec3",
+ "LPoint3f"                  : "Point3",
+ "LVecBase2f"                : "VBase2",
+ "LVector2f"                 : "Vec2",
+ "LPoint2f"                  : "Point2",
+ "LQuaternionf"              : "Quat",
+ "LMatrix4d"                 : "Mat4D",
+ "LMatrix3d"                 : "Mat3D",
+ "LVecBase4d"                : "VBase4D",
+ "LVector4d"                 : "Vec4D",
+ "LPoint4d"                  : "Point4D",
+ "LVecBase3d"                : "VBase3D",
+ "LVector3d"                 : "Vec3D",
+ "LPoint3d"                  : "Point3D",
+ "LVecBase2d"                : "VBase2D",
+ "LVector2d"                 : "Vec2D",
+ "LPoint2d"                  : "Point2D",
+ "LQuaterniond"              : "QuatD",
+ "Plane"                     : "PlaneBase",
+ "Planef"                    : "Plane",
+ "Planed"                    : "PlaneD",
+ "Frustum"                   : "FrustumBase",
+ "Frustumf"                  : "Frustum",
  "Frustumd"                  : "FrustumD" 
  "Frustumd"                  : "FrustumD" 
 }
 }
 
 

+ 3 - 3
direct/src/fsm/SampleFSM.py

@@ -10,9 +10,9 @@ class ClassicStyle(FSM.FSM):
         FSM.FSM.__init__(self, name)
         FSM.FSM.__init__(self, name)
 
 
         self.defaultTransitions = {
         self.defaultTransitions = {
-            'Red' : ['Green'],
-            'Yellow' : ['Red'],
-            'Green' : ['Yellow'],
+            'Red': ['Green'],
+            'Yellow': ['Red'],
+            'Green': ['Yellow'],
             }
             }
 
 
     def enterRed(self):
     def enterRed(self):

+ 1 - 1
direct/src/gui/DirectCheckButton.py

@@ -43,7 +43,7 @@ class DirectCheckButton(DirectButton):
                                               image_scale = self['boxImageScale'],
                                               image_scale = self['boxImageScale'],
                                               image_color = self['boxImageColor'],
                                               image_color = self['boxImageColor'],
                                               state = 'disabled',
                                               state = 'disabled',
-                                              text = ('X' , 'X'),
+                                              text = ('X', 'X'),
                                               relief = self['boxRelief'],
                                               relief = self['boxRelief'],
                                               )
                                               )
        
        

+ 1 - 1
direct/src/gui/DirectDialog.py

@@ -98,7 +98,7 @@ class DirectDialog(DirectFrame):
             ('button_borderWidth',(.01,.01),     None),
             ('button_borderWidth',(.01,.01),     None),
             ('button_pad',        (.01,.01),     None),
             ('button_pad',        (.01,.01),     None),
             ('button_relief',     RAISED,        None),
             ('button_relief',     RAISED,        None),
-            ('button_text_scale'  , 0.06,        None),
+            ('button_text_scale', 0.06,        None),
             ('buttonSize',        None,          INITOPT),
             ('buttonSize',        None,          INITOPT),
             ('topPad',            0.06,          INITOPT),
             ('topPad',            0.06,          INITOPT),
             ('midPad',            0.12,          INITOPT),
             ('midPad',            0.12,          INITOPT),

+ 2 - 2
direct/src/gui/DirectGuiGlobals.py

@@ -25,8 +25,8 @@ SUNKEN = PGFrameStyle.TBevelIn
 GROOVE = PGFrameStyle.TGroove
 GROOVE = PGFrameStyle.TGroove
 RIDGE = PGFrameStyle.TRidge
 RIDGE = PGFrameStyle.TRidge
 
 
-FrameStyleDict = {'flat' : FLAT, 'raised' : RAISED, 'sunken': SUNKEN,
-                  'groove' : GROOVE, 'ridge' : RIDGE 
+FrameStyleDict = {'flat': FLAT, 'raised': RAISED, 'sunken': SUNKEN,
+                  'groove': GROOVE, 'ridge': RIDGE
                   }
                   }
 
 
 # Orientation of DirectSlider and DirectScrollBar
 # Orientation of DirectSlider and DirectScrollBar

+ 1 - 1
direct/src/gui/DirectOptionMenu.py

@@ -126,7 +126,7 @@ class DirectOptionMenu(DirectButton):
             # So entire extent of item's slot on popup is reactive to mouse
             # So entire extent of item's slot on popup is reactive to mouse
             item['frameSize'] = (self.minX, self.maxX, self.minZ, self.maxZ)
             item['frameSize'] = (self.minX, self.maxX, self.minZ, self.maxZ)
             # Move it to its correct position on the popup
             # Move it to its correct position on the popup
-            item.setPos(-self.minX, 0 , -self.maxZ - i * self.maxHeight)
+            item.setPos(-self.minX, 0, -self.maxZ - i * self.maxHeight)
             item.bind(B1RELEASE, self.hidePopupMenu)
             item.bind(B1RELEASE, self.hidePopupMenu)
             # Highlight background when mouse is in item
             # Highlight background when mouse is in item
             item.bind(WITHIN,
             item.bind(WITHIN,

+ 2 - 2
direct/src/leveleditor/LevelEditor.py

@@ -2833,7 +2833,7 @@ class LevelEditor(NodePath, DirectObject):
         # Draw a line from start to end
         # Draw a line from start to end
         edgeLine = LineNodePath(parent)
         edgeLine = LineNodePath(parent)
         edgeLine.lineNode.setName('suitEdge')
         edgeLine.lineNode.setName('suitEdge')
-        edgeLine.setColor(VBase4(0.0, 0.0, 0.5 ,1))
+        edgeLine.setColor(VBase4(0.0, 0.0, 0.5,1))
         edgeLine.setThickness(1)
         edgeLine.setThickness(1)
         edgeLine.reset()
         edgeLine.reset()
         # We need to draw the arrow relative to the parent, but the
         # We need to draw the arrow relative to the parent, but the
@@ -3388,7 +3388,7 @@ class LevelEditor(NodePath, DirectObject):
         return newGroup
         return newGroup
 
 
     def makeNewBuildingGroup(self, sequenceNum, side, curveName):
     def makeNewBuildingGroup(self, sequenceNum, side, curveName):
-        print "-------------------------- new building group %s  curveName=%s------------------------" % (sequenceNum , curveName)
+        print "-------------------------- new building group %s  curveName=%s------------------------" % (sequenceNum, curveName)
         # Now create a new group with just the buildings
         # Now create a new group with just the buildings
         self.addGroup(self.NPToplevel)
         self.addGroup(self.NPToplevel)
         newGroup = self.NPParent
         newGroup = self.NPParent

+ 6 - 6
direct/src/pyinst/Builder.py

@@ -409,8 +409,8 @@ dispatch = {
                 'CARCHIVE': ArchiveTarget,
                 'CARCHIVE': ArchiveTarget,
                 'COLLECT': CollectTarget,
                 'COLLECT': CollectTarget,
                 'STANDALONE': ExeTarget,
                 'STANDALONE': ExeTarget,
-                'INSTALL' : InstallTarget,
-                'FULLEXE' : FullExeTarget,
+                'INSTALL': InstallTarget,
+                'FULLEXE': FullExeTarget,
 }
 }
 
 
         
         
@@ -428,13 +428,13 @@ optdefaults = { 'type':'PYZ',
                 'directories':'',       # PYZ
                 'directories':'',       # PYZ
                 'excludes':'',          # PYZ, INSTALL, COLLECT
                 'excludes':'',          # PYZ, INSTALL, COLLECT
                 'expatterns': '',
                 'expatterns': '',
-                'exstdlib' : '0',
-                'extypes' : '',
+                'exstdlib': '0',
+                'extypes': '',
                 'includes':'',          # PYZ 
                 'includes':'',          # PYZ 
                 'packages':'',          # PYZ
                 'packages':'',          # PYZ
                 'destdir':'',           # COLLECT
                 'destdir':'',           # COLLECT
-                'pathprefix' : '',
-                'trees' : '',
+                'pathprefix': '',
+                'trees': '',
                 'debug' : '0',
                 'debug' : '0',
                 'support' : '1', # include python20.dll & exceptons.pyc at a minimum
                 'support' : '1', # include python20.dll & exceptons.pyc at a minimum
                 'icon': '',
                 'icon': '',

+ 1 - 1
direct/src/tkpanels/AnimPanel.py

@@ -413,7 +413,7 @@ class ActorControl(Pmw.MegaWidget):
         animMenu.pack(side = 'left', padx = 5, expand = 0)
         animMenu.pack(side = 'left', padx = 5, expand = 0)
 
 
         # Combo box to select frame rate
         # Combo box to select frame rate
-        playRateList = ['1/24.0', '0.1', '0.5', '1.0', '2.0', '5.0' , '10.0']
+        playRateList = ['1/24.0', '0.1', '0.5', '1.0', '2.0', '5.0', '10.0']
         playRate = '%0.1f' % self['actor'].getPlayRate(self['active'])
         playRate = '%0.1f' % self['actor'].getPlayRate(self['active'])
         if playRate not in playRateList:
         if playRate not in playRateList:
             def strCmp(a, b):
             def strCmp(a, b):

+ 1 - 1
direct/src/tkpanels/MopathRecorder.py

@@ -1838,7 +1838,7 @@ class MopathRecorder(AppShell, DirectObject):
                          command = None, **kw):
                          command = None, **kw):
         # Set label's text
         # Set label's text
         kw['text'] = text
         kw['text'] = text
-        widget = apply(VectorWidgets.ColorEntry, (parent,) ,kw)
+        widget = apply(VectorWidgets.ColorEntry, (parent,),kw)
         # Do this after the widget so command isn't called on creation
         # Do this after the widget so command isn't called on creation
         widget['command'] = command
         widget['command'] = command
         widget.pack(fill = X)
         widget.pack(fill = X)

+ 1 - 1
direct/src/tkpanels/NotifyPanel.py

@@ -9,7 +9,7 @@ class NotifyPanel:
         notify levels for all available DIRECT and PANDA notify categories
         notify levels for all available DIRECT and PANDA notify categories
         """
         """
         # Make sure TK mainloop is running
         # Make sure TK mainloop is running
-        from direct.showbase.TkGlobal import Pmw, Toplevel, Frame, Label , Radiobutton
+        from direct.showbase.TkGlobal import Pmw, Toplevel, Frame, Label, Radiobutton
         from direct.showbase.TkGlobal import HORIZONTAL, X, W, NW, BOTH, LEFT, RIGHT, IntVar
         from direct.showbase.TkGlobal import HORIZONTAL, X, W, NW, BOTH, LEFT, RIGHT, IntVar
         # To get severity levels
         # To get severity levels
         from pandac.PandaModules import NSFatal, NSError, NSWarning, NSInfo
         from pandac.PandaModules import NSFatal, NSError, NSWarning, NSInfo

+ 1 - 1
direct/src/tkpanels/ParticlePanel.py

@@ -970,7 +970,7 @@ class ParticlePanel(AppShell):
                          command = None, **kw):
                          command = None, **kw):
         # Set label's text
         # Set label's text
         kw['text'] = text
         kw['text'] = text
-        widget = apply(VectorWidgets.ColorEntry, (parent,) ,kw)
+        widget = apply(VectorWidgets.ColorEntry, (parent,),kw)
         # Do this after the widget so command isn't called on creation
         # Do this after the widget so command isn't called on creation
         widget['command'] = command
         widget['command'] = command
         widget.pack(fill = X)
         widget.pack(fill = X)