Edited just here… nobody answered yet
Here is something I’m bothered with… possibly bug cos it behaves strange… in 2017 and 2016
So I was testing with making groups… adding entities… I created a group containing simple qube. rotated it to have difference Global vs Local… I go inside…
ents = Sketchup.active_model.entities # All entities in model
group = ents.add_group()
gents = group.entities
face = gents.add_face([0,0,0], [100,0,0], [100,100,0], [0,100,0])
face.pushpull -100
#group.move! [100,100,100]
point = [100,100,100]
vector = [0,0,1]
angle = 90.degrees
movetrans = Geom::Transformation.translation [0,100,100]
rottrans = Geom::Transformation.rotation(point, vector, angle)
trans = movetrans*rottrans
group.transformation= trans
then I go inside…
# then inside of that group run this
# I don't know yet how to change active drawing content
# I know it is not a #.model
gents = Sketchup.active_model.active_entities
n=0; cp0 = gents.add_cpoint [n, n, n]
n=100; cp1 = gents.add_cpoint [n, n, n]
n=200; cp2 = gents.add_cpoint [n, n, n]
n=300; cp3 = gents.add_cpoint [n, n, n]
n=400; cp4 = gents.add_cpoint [n, n, n]
group1 = gents.add_group(cp1,cp2,cp3,cp4)
gents1 = group1.entities
group2 = gents1.add_group(cp2,cp3,cp4)
So when I added a first ‘group’ all went beautifull… it just enclosed 4 cpoints in a that group1 which was created in an active drawing context… BEAUTY…
Then I got #.entities of that group1 and created in exactly the same way ‘group2’ passing it 3 cpoints. I thought - beeing pretty naive obviously - that it will create ‘group2’ inside ot first ‘group’ enclousing thouse 3 cpoints. I mean #.add_cpoint, #.add_edges etc would work inside of the group with Local coordinates… but inside…
Surprise
I got group which i wanted, but created in the active drawing context. The ‘group2’ is created with its axes aligned to the local drawing context but cpoints were taken out of ‘group1’ reading their Local Coordinates pasted in active drawing context as it were Global Coordinates and then it was enclosed in a ‘group2’ and placed based on I don’t know what… these are the same antities as I can still use cp4.erase!
But In the ‘group1’ there still are those (rather not those) 3 cpoints but rearranged in the same manner as cp2, cp3 , cp4 in ‘group2’ but not grouped… (it looks like ‘group2’ was pasted in ‘group1’ at local origin and exploded)…
and if thats not strange… it will start now
if I select those new cpoints in the ‘group1’ they don’t highlight blue. instead other not existing cpoint outside of ‘group’ is highlighted blue and greyed out (thats why i think its outside). those new cpoints will highlight blue if i double click it… and that highlight will not dissapear till i doubleclick somewhere else…
in 2016 I didn’t see the blue grayed out phantoms…
The new cpoints in ‘group1’ will dissapear if I save and reopen, but it will crush sketchup on exiting the model… so I think it is a bug…
GOSH… @eneroth3 … looks like your short answer was actually more acurate than long one…
Is it normal or is it a bug… Should this post be moved to bug section?
i decided not to attach file since it doesnt save what I wanted to show