[Bf-extensions-cvs] SVN commit: /data/svn/bf-extensions [958] - renamed system_smart_line_break .py -> text_editor_smart_line_break.py

Luca Bonavita mindrones at gmail.com
Sun Aug 29 19:12:09 CEST 2010


Revision: 958
          http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-extensions&revision=958
Author:   mindrones
Date:     2010-08-29 19:12:09 +0200 (Sun, 29 Aug 2010)

Log Message:
-----------
- renamed system_smart_line_break.py -> text_editor_smart_line_break.py
- some conforming

Modified Paths:
--------------
    contrib/py/scripts/addons/text_editor_pasteall.py
    trunk/py/scripts/addons/system_blend_info.py

Added Paths:
-----------
    contrib/py/scripts/addons/text_editor_smart_line_break.py

Removed Paths:
-------------
    contrib/py/scripts/addons/system_smart_line_break.py

Deleted: contrib/py/scripts/addons/system_smart_line_break.py
===================================================================
--- contrib/py/scripts/addons/system_smart_line_break.py	2010-08-29 11:34:58 UTC (rev 957)
+++ contrib/py/scripts/addons/system_smart_line_break.py	2010-08-29 17:12:09 UTC (rev 958)
@@ -1,80 +0,0 @@
-#  ***** GPL LICENSE BLOCK ***** 
-#
-#  This program is free software: you can redistribute it and/or modify
-#  it under the terms of the GNU General Public License as published by
-#  the Free Software Foundation, either version 3 of the License, or
-#  (at your option) any later version.
-#
-#  This program is distributed in the hope that it will be useful,
-#  but WITHOUT ANY WARRANTY; without even the implied warranty of
-#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-#  GNU General Public License for more details.
-#
-#  You should have received a copy of the GNU General Public License
-#  along with this program.  If not, see <http://www.gnu.org/licenses/>.
-#  All rights reserved.
-#  ***** GPL LICENSE BLOCK *****
-
-bl_addon_info={
-    "name":"Text Editor: Smart Line Break",
-    "author":"Chris Foster (Kira Vakaan)",
-    "version":"1.0 2010/5/20",
-    "blender":(2,5,3),
-    "location":"Text Editor",
-    "description":"Enables Smart Tabs (Auto-indents new lines)",
-    'url': 'http://wiki.blender.org/index.php/Extensions:2.5/Py/' \
-        'Scripts/Text/Smart_Tabs',
-    "category":"System"}
-
-#Please send questions or comments to:
-#cdbfoster at gmail.com
-
-import bpy
-from bpy.props import *
-
-class SmartLineBreak(bpy.types.Operator):
-    """Add a new text line using smart tabs"""
-
-    bl_idname="text.smart_line_break"
-    bl_label="Smart Line Break"
-
-    def execute(self,context):
-        #If not using tabs_as_spaces, perform the old functionality
-        if not bpy.context.space_data.text.tabs_as_spaces:
-            bpy.ops.text.line_break()
-            return {"FINISHED"}
-        #Get the current line to break from
-        CurrentLine=bpy.context.space_data.text.current_line.line
-        Whitespace=""
-        #Store each character of whitespace at the beginning of the line in Whitespace
-        for Letter in CurrentLine:
-            if Letter!=" ":
-                break
-            Whitespace+=" "
-        #Get rid of the whitespace
-        CurrentLine=CurrentLine.strip()
-        #Unindent after lines that start with...
-        if CurrentLine.startswith(("return","break","continue")):
-            Whitespace=" "*(bpy.context.space_data.tab_width*((len(Whitespace)//bpy.context.space_data.tab_width)-1))
-        #Indent after lines that end with...
-        if CurrentLine.endswith(":"):
-            Whitespace=" "*(bpy.context.space_data.tab_width*((len(Whitespace)//bpy.context.space_data.tab_width)+1))
-        #Add the new line character and the whitespace
-        bpy.ops.text.insert(text="\n")
-        bpy.ops.text.insert(text=Whitespace)
-        return {"FINISHED"}
-
-def register():
-    
-    #Getting the key item by its index seems like a bit of a hack...
-    #Does anyone know a better way?
-    Item=bpy.context.manager.keyconfigs["Blender"].keymaps["Text"].item_from_id(59)
-    Item.idname="text.smart_line_break"
-
-def unregister():
-    Item=bpy.context.manager.keyconfigs["Blender"].keymaps["Text"].item_from_id(59)
-    Item.idname="text.line_break"
-    
-    
-if __name__=="__main__":
-    register()
\ No newline at end of file

Modified: contrib/py/scripts/addons/text_editor_pasteall.py
===================================================================
--- contrib/py/scripts/addons/text_editor_pasteall.py	2010-08-29 11:34:58 UTC (rev 957)
+++ contrib/py/scripts/addons/text_editor_pasteall.py	2010-08-29 17:12:09 UTC (rev 958)
@@ -44,7 +44,7 @@
     "Scripts/Text_Editor/PasteAll",
     "tracker_url": "https://projects.blender.org/tracker/index.php?"\
 	"func=detail&aid=23493&group_id=153&atid=468",
-    "category": "Text editor"}
+    "category": "Text Editor"}
 
 import bpy
 import urllib
@@ -212,4 +212,4 @@
     bpy.types.Scene.RemoveProperty("use_webbrowser")
 
 if __name__ == "__main__":
-    register()
\ No newline at end of file
+    register()

Copied: contrib/py/scripts/addons/text_editor_smart_line_break.py (from rev 957, contrib/py/scripts/addons/system_smart_line_break.py)
===================================================================
--- contrib/py/scripts/addons/text_editor_smart_line_break.py	                        (rev 0)
+++ contrib/py/scripts/addons/text_editor_smart_line_break.py	2010-08-29 17:12:09 UTC (rev 958)
@@ -0,0 +1,80 @@
+#  ***** GPL LICENSE BLOCK ***** 
+#
+#  This program is free software: you can redistribute it and/or modify
+#  it under the terms of the GNU General Public License as published by
+#  the Free Software Foundation, either version 3 of the License, or
+#  (at your option) any later version.
+#
+#  This program is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY; without even the implied warranty of
+#  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+#  GNU General Public License for more details.
+#
+#  You should have received a copy of the GNU General Public License
+#  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+#  All rights reserved.
+#  ***** GPL LICENSE BLOCK *****
+
+bl_addon_info={
+    "name":"Text Editor: Smart Line Break",
+    "author":"Chris Foster (Kira Vakaan)",
+    "version":"1.0 2010/5/20",
+    "blender":(2,5,3),
+    "location":"Text Editor",
+    "description":"Enables Smart Tabs (Auto-indents new lines)",
+    'url': 'http://wiki.blender.org/index.php/Extensions:2.5/Py/' \
+        'Scripts/Text/Smart_Tabs',
+    "category":"Text Editor"}
+
+#Please send questions or comments to:
+#cdbfoster at gmail.com
+
+import bpy
+from bpy.props import *
+
+class SmartLineBreak(bpy.types.Operator):
+    """Add a new text line using smart tabs"""
+
+    bl_idname="text.smart_line_break"
+    bl_label="Smart Line Break"
+
+    def execute(self,context):
+        #If not using tabs_as_spaces, perform the old functionality
+        if not bpy.context.space_data.text.tabs_as_spaces:
+            bpy.ops.text.line_break()
+            return {"FINISHED"}
+        #Get the current line to break from
+        CurrentLine=bpy.context.space_data.text.current_line.line
+        Whitespace=""
+        #Store each character of whitespace at the beginning of the line in Whitespace
+        for Letter in CurrentLine:
+            if Letter!=" ":
+                break
+            Whitespace+=" "
+        #Get rid of the whitespace
+        CurrentLine=CurrentLine.strip()
+        #Unindent after lines that start with...
+        if CurrentLine.startswith(("return","break","continue")):
+            Whitespace=" "*(bpy.context.space_data.tab_width*((len(Whitespace)//bpy.context.space_data.tab_width)-1))
+        #Indent after lines that end with...
+        if CurrentLine.endswith(":"):
+            Whitespace=" "*(bpy.context.space_data.tab_width*((len(Whitespace)//bpy.context.space_data.tab_width)+1))
+        #Add the new line character and the whitespace
+        bpy.ops.text.insert(text="\n")
+        bpy.ops.text.insert(text=Whitespace)
+        return {"FINISHED"}
+
+def register():
+    
+    #Getting the key item by its index seems like a bit of a hack...
+    #Does anyone know a better way?
+    Item=bpy.context.manager.keyconfigs["Blender"].keymaps["Text"].item_from_id(59)
+    Item.idname="text.smart_line_break"
+
+def unregister():
+    Item=bpy.context.manager.keyconfigs["Blender"].keymaps["Text"].item_from_id(59)
+    Item.idname="text.line_break"
+    
+    
+if __name__=="__main__":
+    register()

Modified: trunk/py/scripts/addons/system_blend_info.py
===================================================================
--- trunk/py/scripts/addons/system_blend_info.py	2010-08-29 11:34:58 UTC (rev 957)
+++ trunk/py/scripts/addons/system_blend_info.py	2010-08-29 17:12:09 UTC (rev 958)
@@ -25,11 +25,11 @@
     "author": "uselessdreamer",
     "version": "0.3",
     "blender": (2, 5, 3),
-    "location": "Object Properties > Scene",
+    "location": "Properties space > Scene tab > Blend Info panel",
     "description": "Show information about the .blend",
     "warning": "",
     "wiki_url": 'http://wiki.blender.org/index.php/Extensions:2.5/Py/' \
-        'Scripts/',
+        'Scripts/System/Blend Info',
     "tracker_url": "https://projects.blender.org/tracker/index.php?" \
         "func=detail&aid=22102&group_id=153&atid=469",
     "category": "System"}




More information about the Bf-extensions-cvs mailing list