ttf in lsp malfunction

Steve Voorhees

Usenet Archive
Joined
Feb 6, 2004
Messages
1
Reaction score
0
when I use the "command" to set style in lsp to arial for my style title it gets substituted with my default acad font of romans. When I close out of the drawing and re-open it I have it back. Some where I am loosing my font support when in lsp using the command entry. The code looks like this:

(defun C:gridbub
(setvar "cmdecho" 0)
(setq la (getvar "clayer"))
(command "osnap" "ENDP")
(setq tin (getvar "textstyle"))
(command "style" "TITLE" "" "" "" "" "" "" "")
(setq sc (getvar "userr1")
pa (getpoint "\nPick grid buble centerpoint: ")
tx1 (getstring T "\nEnter grid buble text: ")
ra (* sc 3.00)
hi (* sc 2.25)
)
(command "layer" "s" "S-ANNO-TEXT" ""
"circle" pa ra
"layer" "s" "S-ANNO-TEXT" ""
"text" "m" pa hi "0.0" tx1
)
(command "layer" "s" la "")
(command "style" "STANDARD" "" "" "" "" "" "" "")
(command "osnap" "off")
(princ)
)

any comments??????
 
Have you tried hardcoding your font when
you make your style "Title" instead of using
a return- "". You might get lucky.....
 
Why not (setvar "textstyle" tin) on the end of the functie

I have modified the function, hope that the problem is losted.

(defun C:gridbub ( / la tin pa tx1 ra hi os)
(setvar "cmdecho" 0)
(setq la (getvar "clayer"))
(setq os (getvar "osmode"))
(command "osnap" "ENDP")
(setq tin (getvar "textstyle"))
(if (not (tblsearch "style" "TITLE"))
(command "style" "TITLE" "" "" "" "" "" "" "")
)
(setq sc (if (> (getvar "userr1") 0)(getvar "userr1")(getvar "dimscale")) pa (getpoint "\nPick grid buble centerpoint: ") tx1 (getstring T "\nEnter grid buble text: ") ra (* sc 3.00) hi (* sc 2.25) ) (command "-layer" "m" "S-ANNO-TEXT" "" "circle" pa ra "-layer" "s" "S-ANNO-TEXT" "" "text" "m" pa hi "0.0" tx1 ) (setvar "clayer" la) (setvar "osmode" os) (setvar "textstyle" tin) (princ)
)
 
Steve,
I think you need to 'specify' the Arial font name..e.g.

(command "style" "TITLE" "Arial.ttf" "" "" "" "" "" "")

Bob
 

Latest threads

Back
Top