Jump to content

Rotating text within symbols


Recommended Posts

I'm sorry, at first I misunderstood the question.

It's not possible to maintain alignment of text when in a symbol and the symbol is rotated.

I suggest duplicating the symbol, edit the symbol, rotate the object and exit the symbol. Then use that as the object in the drawing.

The other option is to use it as a group, rather than a symbol. Edit the group for the rotation, rotate the object and leave the text alone. This may be easier to manage than multiple symbols that are similar.

Link to comment

Can we please add this to the wish list.

I've learnt the hard way with text in symbols. Thought I was being clever at one stage and used a number of symbols with text in them. By mirroring them I obtained the opposite hand. It was fine as a VW drawing. Then I exported it to DWG - wherever I had used mirrored symbols the recipient had text which was either reversed, or upside down. Not good.

Therefore if you can develop the capability for text to rotate in symbols...

Please, as the option of having 4 similar symbols to handle the 4 cardinal orientations is a pain in the butt.

Link to comment
  • 1 month later...

If I understand what you're talking about, you want something that automatically updates the text, keeping it upright, when the overall thing is rotated, correct?

You can do this with a plug-in object that understands what it's rotation value is and can adjust its parts based on that value. Make sure it's set to update on rotate and you're set to go.

Here's a code snippit I used to change the location of a text label based on the object's rotation:

=========================

procedure doTextBlock(TextBoxOffset:REAL; DirBlockLength:REAL; Rotation:REAL);

VAR

RotationINT : INTEGER;

LabelText : STRING;

BEGIN

{NORMALIZE ROTATION VALUE}

RotationINT := Trunc(Rotation) MOD 360;

LabelText := PLABEL;

{TEXT BLOCK}

FillPat(0);

FillFore(0,0,0);

FillBack(0,0,0);

PenSize(0);

PenFore(0,0,0);

PenBack(0,0,0);

TextFont(GetFontID('Helvetica'));

TextSize(8);

TextFace([]);

TextFlip(0);

TextSpace(2);

TextJust(3);

CASE RotationINT OF

-45..45,135..225,-225..-135, 315..360, -360..-315:

BEGIN

TextVerticalAlign(3);

TextOrigin(CutLineLength+0.1mm,-2.2mm);

TextRotate(0);

END;

-134..-46, 226..314:

BEGIN

TextVerticalAlign(4);

TextOrigin(-1.0mm,DirBlockLength+0.1mm);

TextRotate(90);

END;

46..134, -314..-226:

BEGIN

TextVerticalAlign(4);

TextOrigin(-1.5mm,DirBlockLength+0.1mm);

TextRotate(90);

END;

END; {CASE}

BeginText;

LabelText

EndText;

END; {doTextBlock}

==================================

I just started VectorScript two days ago, so hopefully my code works for you. Just call the procedure from inside your main object's code.

  • Like 1
Link to comment

Mike,

Be careful what you ask for... I can see where this would help you for the need you described, but where would you have the text placed? Exactly the same position, or would it move with the rotation?

Are you going to want to adjust its position as a function of rotation? The same goes for flipped symbols, does the position of the text flip from one side to the other when the symbol is flipped, or do you want it on the same side, or do you want to choose?

Lastly, how would you want to control which text behaves this way and which text stays registered with the symbol? I use text as part of symbols all the time and I need it to stay put, so at the very least, I hope you are asking for OPTIONAL control.

The level of control you are asking for would make text objects very difficult to manage in symbols, especially for the novice user. I would suggest using the Group method previously discussed or having 4 symbols tweaked for your needs as you are already doing.

If you go this route a lot, it would be a good place to employ a vectorscript to generate the extra three rotations of a symbol based on the one you create, each with a slightly different name. Or, develop a PIO that contains a user selectable symbol and a text block and adjusts the text accordingly as Zeibin's above script allows.

I don't mean to rain on your parade, but I think there are many solutions already available to achieve what you need. If you'd like to discuss any options further, either here or off line, I would be more than willing to assist you.

Good luck,

Raymond

Link to comment

I think this needs to be an essential new feature for VW12. Autocad 2005 has it, as do a lot of the MCAD 3D apps out there. There are numerous applications for this.

Take, for a example, a company who produce layouts for office furniture. They have a symbol library for every part and configuration of unit. They will assign a code to every item on the plan. If the code is in the symbol the number or text will rotate with the symbol (and we are not just talking 90 or 180 degrees here - it is any angle). The resultant drawing is a mess.

What they do instead is create symbols for the codes and apply these manually to the plan so the codes are all in the same orientation. Trust me, this is a tedious waste of valuable time.

There should be an option in the text box properties to "fix orientation (to whatever it was set at)". This will also require a locus point to apply the rotation around.

When the symbol with text is dropped in and rotated, the text stays horizontal, say. This way the drawing looks clean. Also, this also gives much more power to the linked records in symbols.

Sure there may be concerns about where the text rotates to but if you have a locus point this should be minimised.

By the same score if we could assign this property to graphic elements as well (like a leader and balloon) this would really make symbols much much more useful in tight deadline production environments AND reduce scope for errors!

If nemetschek don't do this then there must be a plug in developer out there who sees the value in this - maybe by also creating automatic links to worksheets as well in some way?

Link to comment
  • 18 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...