Community
AutoCAD Forum
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Reset font or font style in text styles.

8 REPLIES 8
SOLVED
Reply
Message 1 of 9
Anonymous
6632 Views, 8 Replies

Reset font or font style in text styles.

I am exporting from revit to dwg. When exporting it creates a lot of font styles applied to the appropriate fonts. The problem is that while the font itsself is correct, the font style is set to regular which produces a very light font that does not update by the layers lineweight. I've found that if I open the text style and reselect the font, then use ReGenALL, the fonts will then display correctly. 

 

EX:

 

Before:

 

Text Style: Simplex_B

Font: Simplex.shx

Font Style: Regular

 

After:

 

Text Style: Simplex_B

Font: Simplex.shx

Font Style: blank

 

How can I fix this without changing it manually every time? There will normally be 10-20 fonts in each drawing, and I will have 10-50 drawings. I need a way to change this more effieciently. 

 

8 REPLIES 8
Message 2 of 9
Anonymous
in reply to: Anonymous

I found project standards, and they do not work. The text styles are not consistent from one drawing to the next so project standards will just switch things up that shouldn't be.

Message 3 of 9
pendean
in reply to: Anonymous

May I ask why you all concert REVIT files all the time to dwg?
Message 4 of 9
Anonymous
in reply to: pendean

It is what the customer wants. Our preference is PDF's. 

Message 5 of 9
pendean
in reply to: Anonymous

Ah! You work in REVIT but ship as dwg files when PDF will not do.

I suggest you ask in the REVIT forum about tips to help you with that problem while you wait here: it's a REVIT quirk that I suspect REVIT experts over there might be able to address.
Message 6 of 9
Anonymous
in reply to: pendean

I don't believe this is within my power to change via Revit. I have already explored all availiable export options revit contains. I am almost certain this is an problem that needs to be solved with autocad. Since it cannot be done with project standards I probably need a LISP routine or VBA code. Unfortunately I am unfamiliar with VBA and LISP. What I need is a LISP routing or something that takes the text styles and sets the font to the current count for that text style. I doubt it is particularly complex, and I'm looking in to LISP now to find what I need. Any help with this would be appriciated.

Message 7 of 9
Anonymous
in reply to: pendean

Ok, after some more reading, the problem seems to be that revits TTF's are being mapped to simplex.SHX. This is what I want, but unfortulately after being mapped the font style is regular, rather than just being treated as a SHX font. This doesn't solve my problem, but at least I better understand the cause.

Message 8 of 9
RobDraw
in reply to: Anonymous


@Anonymous wrote:

Ok, after some more reading, the problem seems to be that revits TTF's are being mapped to simplex.SHX. This is what I want


Why not make your life easier and use the TTFs?


Rob

Drafting is a breeze and Revit doesn't always work the way you think it should.
Message 9 of 9
Anonymous
in reply to: RobDraw

This is a client requirement, and truetype gives me less control over appearance than shx.

 

I found a lisp routine elsewhere while searching last night:

 

(vl-load-com)

(defun c:updateTextstyles (/ new)
(setq new (strcat (getenv "systemroot") "\\Fonts\\Arial.ttf"))
(vlax-map-collection
(vla-get-textstyles
(vla-get-activedocument
(vlax-get-acad-object)))
'(lambda (x / font)
(setq font (strcase (vla-get-fontfile x)))
(if (wcmatch font "ROMANS.SHX,SIMPLEX.SHX,TXT.SHX")
(vla-put-fontfile x new)))
)
(princ)
)

 

Additionally it turns out that the font is actually stored in the style table as simplex.ttf but it for some reason it appears in the UI as simplex.shx.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

State of Sustainability Webinar


AutoCAD Inside the Factory