2023-10-25 08:14 AM - last edited on 2023-10-29 11:11 PM by Karl Ottenstein
Hi, Is there anyway I can make electrical outlet 2D symbol to adjust the size to match drawing scale? I set up 3/4" scale drawings, everything changed accordingly except those MEP symbol. like outlet, switch. it seems like they set up at 1/4" scale and never changed.
a week ago
Hi Barry
Can please I ask how you made your 2D GPO object scalable or are you able to share your script? I have been trying to do something similar for days and cannot work out how to script the scaling aspect.
I also have a 3D object associated with it but that doesn't need to be scaleable (just in case that changes things)
Thanks
a week ago - last edited a week ago
MUL2 GLOB_SCALE, GLOB_SCALE
Put that at the beginning of the 2D script. This will make something placed in a View scale against the drawing scale so that it is always to same size. If the object generates it's 2D via a Project2, you would need to use a GLOB_CONTEXT to limit the scaling to 2D only and add a z to the transformation.
Ling.
AC22-28 AUS 3110 | Help Those Help You - Add a Signature |
Self-taught, bend it till it breaks | Creating a Thread |
Win11 | i9 10850K | 64GB | RX6600 | Win11 | R5 2600 | 16GB | GTX1660 |
a week ago
Thanks @Lingwisyer
That worked perfectly for scaling the object!
Next question - how do I stop the text from scaling?
a week ago
I am not quite sure what you are trying to achieve... I am assuming this object was created by saving from the floor plan? You can Define Style then use a Set Style. Your text would then be defined as AC_TextSize / GLOB_SCALE, but by doing this, going from 1:100 to 1:50, your symbol would double in size but the text would not... and the relevant position change would need to be made.
AC22-28 AUS 3110 | Help Those Help You - Add a Signature |
Self-taught, bend it till it breaks | Creating a Thread |
Win11 | i9 10850K | 64GB | RX6600 | Win11 | R5 2600 | 16GB | GTX1660 |
a week ago
I can't share the object because it is company property.
But simply in the 2D script before you draw the object ...
if scale_sens then
MUL2 GLOB_SCALE/100,GLOB_SCALE/100
endif
Barry.
a week ago
- last edited
a week ago
by
Laszlo Nagy
That's exactly what I was after @Lingwisyer, Thanks!
Basically, I wanted the 2D object to show smaller at 1:50 or 1:20 but the text to remain at 1.5 size for all scales.
Using GLOB_SCALE in the Define Style line as you suggested worked perfectly. I had to use *100/GLOB_SCALE as I had drawn the original object at 1:100 before I learned that it's better to draw them 1:1.
I attached the screenshots of the old and new objects for reference.
Thanks again for your help!
a week ago
Thanks, Barry.
Lingwisyer actually beat you to it with the same suggestion, and I can confirm it worked for me.