Revision: 54445
          http://brlcad.svn.sourceforge.net/brlcad/?rev=54445&view=rev
Author:   r_weiss
Date:     2013-02-20 21:23:39 +0000 (Wed, 20 Feb 2013)
Log Message:
-----------
Update to mged grouper (i.e. gr) command. Forced the model orientation to 
remain static when the group, which you are adding to or subtracting from, is 
erased and redrawn.

Modified Paths:
--------------
    brlcad/trunk/src/tclscripts/mged/grouper.tcl

Modified: brlcad/trunk/src/tclscripts/mged/grouper.tcl
===================================================================
--- brlcad/trunk/src/tclscripts/mged/grouper.tcl        2013-02-20 19:51:08 UTC 
(rev 54444)
+++ brlcad/trunk/src/tclscripts/mged/grouper.tcl        2013-02-20 21:23:39 UTC 
(rev 54445)
@@ -34,8 +34,11 @@
 # instead of the primitive. With the '-p' option, if the primitive does
 # not have a parent (i.e. is in the root) it will be ignored.
 #
+# NOTE: This command will not function as expected if a selected object
+#       has matrices applied. The xpush command can resolve this
+#       limitation.
+#
 
-
 namespace eval grouper_v2 {
 
 namespace export gr
@@ -54,6 +57,9 @@
 set objs {}
 set erase_status ""
 set parent_only 0
+set center_orig ""
+set size_orig ""
+set ae_orig ""
 
 proc gr_remdup { GroupName } {
 
@@ -159,6 +165,9 @@
     variable fb_orig
     variable fb_all_orig
     variable listen_orig
+    variable center_orig
+    variable size_orig
+    variable ae_orig
 
     set GroupName ""
     set Boolean ""
@@ -221,6 +230,9 @@
     set fb_orig [rset var fb]
     set fb_all_orig [rset var fb_all]
     set listen_orig [rset var listen]
+    set center_orig [center]
+    set size_orig [size]
+    set ae_orig [ae]
 
     set mged_gui($id,mouse_behavior) p
     set_mouse_behavior $id
@@ -234,6 +246,9 @@
     # highlight in yellow current group
     if { [search -name $GroupName] != "" } {
        e -C255/255/0 $GroupName
+       center $center_orig
+       size $size_orig
+       ae $ae_orig
     }
 }
 
@@ -242,8 +257,14 @@
 
     variable objs
     variable GroupNameGlobal
+    variable center_orig
+    variable size_orig
+    variable ae_orig
 
     set GroupNameGlobal $GroupName
+    set center_orig [center]
+    set size_orig [size]
+    set ae_orig [ae]
 
     # Temporarily erase group from display while getting objects in rectangle"
     after 1 {
@@ -267,6 +288,9 @@
        # highlight in yellow current group
        if { [search -name $GroupName] != "" } {
            e -C255/255/0 $GroupName
+           center $center_orig
+           size $size_orig
+           ae $ae_orig
        }
        return
     }
@@ -276,6 +300,9 @@
        # highlight in yellow current group
        if { [search -name $GroupName] != "" } {
            e -C255/255/0 $GroupName
+           center $center_orig
+           size $size_orig
+           ae $ae_orig
        }
        return
     }
@@ -355,6 +382,9 @@
     # highlight in yellow current group
     if { [search -name $GroupName] != "" } {
        e -C255/255/0 $GroupName
+       center $center_orig
+       size $size_orig
+       ae $ae_orig
     }
 
     puts stdout "Selection complete."

This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.


------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_d2d_feb
_______________________________________________
BRL-CAD Source Commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/brlcad-commits

Reply via email to