Here is the entire 2d script and I sent the entire master script in the last email.
define style "idestyle" fonttype , ROOM_LSIZE , 2, 1
define style "idestyle2" fonttype , ROOM_LSIZE , 8, 1
mul2 A_/1000,A_/1000
style idestyle
rrr=request("Height_of_style","idestyle", shight)
catname = ""
catcode = ""
rrr=request("Zone_category", "", catname, catcode)
Zname = ROOM_NAME
if cn_zn then Zname = catname !*** display Category Name as Zone name
if catcode = "0" then Zname = "Gross Area" !***prints "BGF" to the stamp
area_form=""
rrr=request ("Area_dimension","",area_form)
room_area = str (area_form, ROOM_CALC_AREA)
lin_form=""
rrr=request ("Linear_dimension","",lin_form)
room_height = str (lin_form , ROOM_HEIGHT)
room_perim = str (lin_form , ROOM_PERIM)
unit = ""
area_unit = ""
lin_unit = ""
form = ""
form = lin_form !*** Unit strings
gosub 1001
lin_unit = unit
form = area_form
gosub 1002
area_unit = unit
room_area = room_area + area_unit !*** composite strings
if ceil_h then room_height = "H: typical" else room_height = "H: " + room_height + lin_unit
room_perim = "P: " + room_perim + lin_unit
code_string = basec + " " + wallc + " " + ceilc
!w_roona = (stw (Zname)) * name !*** width of the strings - 0 if not displayed
w_roonu = (stw (ROOM_NUMBER)+3) * num
w_codes = stw (code_string)+3 * code
w_rooar = (stw (room_area)+3) * area
w_peri = (stw (room_perim)+3) * peri
w_roohe = (stw (room_height)+3) * ceil_s
max_len= max (w_roonu, w_codes, w_rooar, w_peri, w_roohe)
max_h = - (name + num + code + area + peri + ceil_s) * shight
middle = max_len/2
vlen = - shight
rot2 w
add2 -max_len/2, vlen - max_h/2
if name then
if KN<>"*" THEN
Text2 middle,-vlen, KN
endif
IF KN="*" THEN
Text2 middle,-vlen, RN
ELSE
Text2 middle,2*(-vlen), RN
ENDIF
ENDIF
if num then
n=n+1
vlen =vlen + shight
Text2 middle,-vlen, ROOM_NUMBER
endif
if area then
n=n+1
vlen =vlen + shight
Text2 middle, -vlen, room_area
endif
if code then
n=n+1
vlen =vlen + shight
Text2 middle,-vlen, code_string
endif
if peri then
n=n+1
vlen =vlen + shight
Text2 middle,-vlen, room_perim
endif
if ceil_s then
n=n+1
vlen =vlen + shight
Text2 middle,-vlen, room_height
endif
vlen = vlen+shight
! hotspot2 0, shight
! hotspot2 max_len, shight
! hotspot2 0, max_h + shight
! hotspot2 max_len, max_h + shight
! hotspot2 max_len/2, max_h/2 + shight
if hspots then
! hotspot2 max_len/2, -shight/2
! hotspot2 max_len/2, -i*shight
! hotspot2 0, max_h/2 + shight
! hotspot2 max_len, max_h/2 + shight
endif
if box_y and n then
pen Pen_Box
line2 0 , 0, 0, -vlen
line2 max_len , 0, max_len , -vlen
for i=0 to n
line2 0,-i*shight, max_len, -i*shight
hotspot2 0, -i*shight
hotspot2 max_len, -i*shight
hotspot2 max_len/2, -i*shight
next i
endif
end
1001: !*** Linear unit strings
if strstr (form, "m") then unit = " m"
if strstr (form, "cm") then unit = " cm"
if strstr (form, "mm") then unit = " mm"
if strstr (form, "i") or strstr (form, "f") then unit = ""
return
1002: !*** Area unit strings
if strstr (form, "sqm") then unit = " m2"
if strstr (form, "sqcm") then unit = " cm2"
if strstr (form, "sqmm") then unit = " mm2"
if strstr (form, "sqmm") then unit = " mm2"
if strstr (form, "sqf") then unit = " SF"
if strstr (form, "sqi") then unit = " sq inch"
return
Thanks,
Michele