Debug Sel geo

From Macros Wiki
Jump to: navigation, search
!      get gibbs geo ref numbers for each selected feature
get_num_feat_selected inum
if inum<1 then stop "No geometry selected"
 
ics = 1  ! world units
 
for i=1 to inum
get_selected_geo_ref i, iref


get_feat_type iref, itype


get_feat_start iref, ics, xs, ys
get_feat_end iref, ics, xe, ye


if itype=3 then get_circle_data iref, ics, rad, xc, yc


a$="feature number %i of %inum is ref %iref"


if itype=1 then a$=a$+"\nPoint"
if itype=1 then a$=a$+" X "+format$(xs, "####0.000")
if itype=1 then a$=a$+" Y "+format$(ys, "####0.000")


if itype=2 then a$=a$+"\nLine"
if itype=2 then a$=a$+"\nXs "+format$(xs, "####0.000")
if itype=2 then a$=a$+" Ys "+format$(ys, "####0.000")
if itype=2 then a$=a$+"\nXe "+format$(xe, "####0.000")
if itype=2 then a$=a$+" Ye "+format$(ye, "####0.000")


if itype=3 then a$=a$+"\nCircle"
if itype=3 then a$=a$+"\nXc "+format$(xc, "####0.000")
if itype=3 then a$=a$+" Yc "+format$(yc, "####0.000")
if itype=3 then a$=a$+" Rad "+format$(rad,"####0.000")



if itype=4 then a$=a$+"\nArc"
if itype=4 then a$=a$+"\nXs "+format$(xs, "####0.000")
if itype=4 then a$=a$+" Ys "+format$(ys, "####0.000")
if itype=4 then a$=a$+"\nXe "+format$(xe, "####0.000")
if itype=4 then a$=a$+" Ye "+format$(ye, "####0.000")



message a$
next i