Mtext attributes misaligned after flip - only in added annotation scale.

Mtext attributes misaligned after flip - only in added annotation scale.

jpCADconsulting
Advocate Advocate
846 Views
3 Replies
Message 1 of 4

Mtext attributes misaligned after flip - only in added annotation scale.

jpCADconsulting
Advocate
Advocate

Hi folks. Hoping you can shed some light on this issue that I have been trying to unravel; since 2019.

 

I have attached an example drawing so you can try all this for yourselves.

 

Here is the issue:

 

I have this this block. Fairly simple. Youc an drag the text around and flip the blpock. We can all make them in our sleep.  it looks like this (at annotation scale 1:1):

 

1 to 1 right.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Now, select it and click the flip parameter and you get this:

 

1 to 1 left.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Peachy.

 

Now let's add the annotation scale 1:2 and see what we get.

 

1 to 2 right.png

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

Brilliant. looks great! Now flip it...

 

1 to 2 left.png

 

Sad emoji.

 

The block works fine in whatever annotation scale is current when it's inserted, but in added scales, the problem exists.

 

I can repeat this at different offices, in different versions and verticals of AutoCAD. Existing blocks or made form scratch. I can even construct the block using different combinations of Parameters/Actions... Doesn't matter, it always happens. Infinitely repeatable.

Now... if I make the block using a single line TEXT attribute, I do not get the issue and the block responds as I'd expect.  But I need the MTEXT attribute because I cannot get a background mask (which the clients have requested) using regular TEXT attributes.

Hoping you can shed some light on this... Thanks in advance for your help.

-JP (your friendly neighborhood CAD administrator)

0 Likes
847 Views
3 Replies
Replies (3)
Message 2 of 4

rapidcad
Collaborator
Collaborator

Hi JP. I took a look at your block and I see the issue. You are being frustrated by the unalterable (as long as the text is blocked) justification of the text object. I believe you could build the same block using AutoCAD's built in multileader instead and the text would respect the flip then I believe. It would not be all that hard to do. 

 

However, the more I thought about it, the more I kept coming back to the question, why not just use an annotative multileader style in your drawing template that uses a text style (also in your template) to do the same thing? I understand that sometimes we set up things a certain way so other processes can work with the various entities - so maybe that is your issue, you really want this to be an attribute. Does it need to be? If not I would simply use an annotative multileader style to do this - Autodesk set it up so all the flipping is automatic when you drag the leader around.

 

So I experimented with your drawing and built a test multileader style to see how this would look. Unfortunately, the multileader style definitions built by Autodesk neglected to give you the spot elevation arrowhead that could automatically stay true to the coordinate grit and not "pull back" the leader base from the arrowhead insertion point. So you end up with a not so great solution (see my attachment). 

 

A dynamic block with a flip will always have a problem with the text justification unless you can live with using center justification and move the text over so that it usually stays away from the leader end. I imagine this idea will not work for you unless your text is always 4 characters long - unlikely I think. You could provide a polar move on the text and then it could be manually adjusted to work properly.

 

Here's a link that points to a conversation very similar to yours - maybe it can shed more light on your options. Hope this helps.

 

ADN CAD Developer/Operator
Message 3 of 4

jpCADconsulting
Advocate
Advocate

Thanks rapidcad. Much appreciated.

 

There are a number of reasons it's a block and not a mleader. Office history of course but mainly, I have my tool palette calling LISP routines to insert blocks scaled properly for the current DWG units so they can safely insert them into any file (Feet, Inches, Metric, etc.) and they are the correct size.

I've never been able to do it smoothly with Mleaders. In order for the LISP to work and adjust their "overall scale" value on insertion they come in non-annotative and of course if they are annotative, I cannot adjust their overall scale.

What baffles me is that the blocks works fine in the annotation that is current when inserted but not in subsequently added annotation scales and...

 

If I use plain single line text, it also works fine in all scales.

 

0 Likes
Message 4 of 4

rapidcad
Collaborator
Collaborator

Three things you could do to your block that could ease your pain:

 

First off, delete the 1:2 annotative scale because that is part of the problem - the static definition of the 1:2 scale being already actuated in the flip (off) position encourages the block to not mirror the attribute like it would if AutoCAD has to create it using the definition of the scale it was built in.  (I don't know if that makes sense to you but give it a try and see what you think). 

 

Secondly, once that change has been made the block behaves properly for either direction if you always do one thing first - activate the flip action in the 1:1 scale. You could do this as you insert it using lisp functions (Lee Mac has a wonderful function that I incorporate in a lot of my insertion tools) and create two insertion tools, a left and a right with icons that match the tool.

 

Lastly, the tool still acts up if you change scales after insertion but if it was flipped before the scale change it can be fixed easily by highlighting the block and right-click menu selection RESET THE BLOCK. I encourage you to check out the attached old (right after the annotative property was added in 2008)  handout written by Dan Abbott. He covers the features in depth where later instructionals often assume "everyone knows that".

 

Yes I know none of these completely make this work right but that is the rub if you really want to create a tool that nests an attribute into an annotative leader block that can be flipped.  Here's an alternative idea: use a visibility parameter to hide a right hand version and a left hand version of the attributes, but that also will not be as seamless as the current block works in the annotative scale it was created at.

 

HTH

ADN CAD Developer/Operator
0 Likes