Bill Tillman Posted January 6, 2015 Posted January 6, 2015 When I do this (entget (tblobjname "DIMSTYLE" "D12")) I get a list with about 12 of the DXF codes for the dimstyle "D12" in this drawing. But we all know there are many more DXF codes for a dimstyle. I can't seem to find any reference for these except the common DXF section. Same issue for the TextStyles I'm working with. Quote
BIGAL Posted January 7, 2015 Posted January 7, 2015 It may be easier to do with vl if you dump a single dim you get access to all the variables some 40+ and you can change any of them. Select object: ; IAcadDimRotated: AutoCAD Rotated Dimension Interface ; Property values: ; AltRoundDistance = 0.0 ; AltSubUnitsFactor = 100.0 ; AltSubUnitsSuffix = "" ; AltSuppressLeadingZeros = 0 ; AltSuppressTrailingZeros = 0 ; AltSuppressZeroFeet = -1 ; AltSuppressZeroInches = -1 ; AltTextPrefix = "" ; AltTextSuffix = "" ; AltTolerancePrecision = 2 ; AltToleranceSuppressLeadingZeros = 0 ; AltToleranceSuppressTrailingZeros = 0 ; AltToleranceSuppressZeroFeet = -1 ; AltToleranceSuppressZeroInches = -1 ; AltUnits = 0 ; AltUnitsFormat = 2 ; AltUnitsPrecision = 2 ; AltUnitsScale = 25.4 ; Application (RO) = # ; Arrowhead1Block = "" ; Arrowhead1Type = 0 ; Arrowhead2Block = "" ; Arrowhead2Type = 0 ; ArrowheadSize = 2.5 ; DecimalSeparator = "." Quote
Lee Mac Posted January 7, 2015 Posted January 7, 2015 (mapcar 'print (tblsearch "dimstyle" "d12")) Quote
BIGAL Posted January 8, 2015 Posted January 8, 2015 Nice one as usual Lee, only advantage in the VL is it uses lables it may still be confusing what number refers to what. Quote
Bill Tillman Posted March 31, 2015 Author Posted March 31, 2015 Thanks again all. I have run into one more issue with the dimension properties. Remember, these are placed on the fly, no user input or selection allowed. So I could use either entmake or just draw the dimension using command and then setting some properties for it as (entlast) or a variable I've assigned to it temporarily. But I'm stumped on how to format the text in a few dimensions due to space limitations. The image on the left is what I end up with by just drawing the dimension like this: (command "._DIMLINEAR" pt1 pt2 "V" pt3 "") But what I want is what is shown in the image on the right. I think I need to change the property "Text Inside" but not sure how to do this. Quote
BIGAL Posted April 1, 2015 Posted April 1, 2015 Just did the simple -dimstyle and got everything. Just do say (command "DIMTXT" 3.5) etc before your line not sure which DIM Var is the one you want so do as below 1st then change the dimstyle and do again. Almost forgot you may need 0 or 1 for on/off Command: -DIMSTYLE Current dimension style: ISO-7 Annotative: No Enter a dimension style option [ANnotative/Save/Restore/STatus/Variables/Apply/?] <Restore>: V Enter a dimension style name, [?] or <select dimension>: ISO-7 DIMADEC 0 Angular decimal places DIMALT Off Alternate units selected DIMALTD 4 Alternate unit decimal places DIMALTF 0.039 Alternate unit scale factor DIMALTMZF 100.000 Alternate sub-zero factor for metric dimensions DIMALTMZS Alternate sub-zero suffix for metric dimensions DIMALTRND 0.000 Alternate units rounding value DIMALTTD 4 Alternate tolerance decimal places DIMALTTZ 0 Alternate tolerance zero suppression DIMALTU 8 Alternate units DIMALTZ 0 Alternate unit zero suppression DIMAPOST Prefix and suffix for alternate text DIMARCSYM 0 Arc length symbol DIMASZ 7.000 Arrow size DIMATFIT 3 Arrow and text fit DIMAUNIT 0 Angular unit format DIMAZIN 0 Angular zero supression DIMBLK ClosedFilled Arrow block name DIMBLK1 ClosedFilled First arrow block name DIMBLK2 ClosedFilled Second arrow block name DIMCEN 7.000 Center mark size DIMCLRD BYBLOCK Dimension line and leader color DIMCLRE BYBLOCK Extension line color DIMCLRT BYBLOCK Dimension text color DIMDEC 2 Decimal places DIMDLE 0.000 Dimension line extension DIMDLI 10.500 Dimension line spacing DIMDSEP . Decimal separator DIMEXE 3.500 Extension above dimension line DIMEXO 1.750 Extension line origin offset DIMFRAC 0 Fraction format DIMFXL 1.000 Fixed Extension Line DIMFXLON Off Enable Fixed Extension Line DIMGAP 1.750 Gap from dimension line to text DIMJOGANG 45d0'0" Radius dimension jog angle DIMJUST 0 Justification of text on dimension line DIMLDRBLK ClosedFilled Leader block name DIMLFAC 1.000 Linear unit scale factor DIMLIM Off Generate dimension limits DIMLTEX1 BYBLOCK Linetype extension line 1 DIMLTEX2 BYBLOCK Linetype extension line 2 DIMLTYPE BYBLOCK Dimension linetype DIMLUNIT 2 Linear unit format DIMLWD -2 Dimension line and leader lineweight DIMLWE -2 Extension line lineweight DIMMZF 100.000 Sub-zero factor for metric dimensions DIMMZS Sub-zero suffix for metric dimensions DIMPOST Prefix and suffix for dimension text DIMRND 0.000 Rounding value DIMSAH Off Separate arrow blocks DIMSCALE 1.000 Overall scale factor DIMSD1 Off Suppress the first dimension line DIMSD2 Off Suppress the second dimension line DIMSE1 Off Suppress the first extension line DIMSE2 Off Suppress the second extension line DIMSOXD Off Suppress outside dimension lines DIMTAD 1 Place text above the dimension line DIMTDEC 4 Tolerance decimal places DIMTFAC 1.000 Tolerance text height scaling factor DIMTFILL 0 Text background enabled DIMTFILLCLR BYBLOCK Text background color DIMTIH Off Text inside extensions is horizontal DIMTIX Off Place text inside extensions DIMTM 0.000 Minus tolerance DIMTMOVE 0 Text movement DIMTOFL On Force line inside extension lines DIMTOH Off Text outside horizontal DIMTOL Off Tolerance dimensioning DIMTOLJ 1 Tolerance vertical justification DIMTP 0.000 Plus tolerance DIMTSZ 0.000 Tick size DIMTVP 0.000 Text vertical position DIMTXSTY Standard Text style DIMTXT 7.000 Text height DIMTXTDIRECTIONOff Dimension text direction DIMTZIN 0 Tolerance zero suppression DIMUPT Off User positioned text DIMZIN 8 Zero suppression Quote
Bill Tillman Posted April 1, 2015 Author Posted April 1, 2015 (edited) Good Day BIGAL. I think I found it by using the variable "DIMTIX" like this: (setvar "DIMTIX" 0) (command "._DIMLINEAR" (polar (polar gp4 a270 (+ offsetdimV afrmdp1 1.75)) pi 1.4375) (polar (polar gp4 a270 (+ offsetdimV afrmdp1)) pi afrmwd) "V" (polar gp4 pi 9) "") (command "._DIMLINEAR" (polar (polar gp3 a270 (+ offsetdimV afrmdp1)) 0 afrmwd) (polar (polar gp3 a270 (+ offsetdimV afrmdp1 0.75)) 0 1.4375) "V" (polar gp3 0 4) "") (setvar "DIMTIX" 1) The dimensions don't quite end up like I really want but at least I can set the smaller ones outside of the extension lines. Edited April 1, 2015 by Bill Tillman Quote
Bill Tillman Posted April 1, 2015 Author Posted April 1, 2015 (edited) Just ran into one more thing with this issue. I can not control which dimensions are written outside of the extension lines but I need the text to be on the other side of the arrows. I know a lot of this depends on which dimension point gets picked first but the text still ends up on the opposite side of where I want it. See example below. The sketch on the left shows how the LISP code draws the dimension, the sketch on the right shows what I need it to end up looking like. I'm searching through that long list of DIMSTYLE variables and don't seem to find the one for that particular setting. UPDATE: OKAY, many thanks again you guys. I found by playing around with the DIMJUST variable, this too can be controlled, on the fly. Edited April 1, 2015 by Bill Tillman Quote
Recommended Posts
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.