void draw_hips(CCfgtype cfg) { //zt = 0.0; textrotn = 0.0; double dVcl, dK; double dLead = 1.2; // gap between lines if (IPX != last_IPX && IPY != last_IPY) { if (index == false) // Start HIP { xt = xst - xlate_x; yt = yst - xlate_y; plan_form(ref xt, ref yt); textstring = "Start chainage / Level: " + xst.ToString("0.000") + ", " + yst.ToString("0.000") + " m."; textwrite(); } } if (eltype == 3) { xt = IPX - xlate_x; yt = IPY - xlate_y; plan_form(ref xt, ref yt); textstring = "VIP Chainage = " + IPX.ToString("0.000") + " m"; xstor = xt; ystor = yt; textwrite(); xt = xstor; yt = ystor; yt -= textsize / cfg.YMetric * dLead; textstring = "VIP Level = " + IPY.ToString("0.000") + " m"; xstor = xt; ystor = yt; textwrite(); xt = xstor; yt = ystor; yt -= textsize / cfg.YMetric * dLead; dVcl = R + L; if (Math.Abs(R - L) < 0.001) { textstring = "VCL = " + dVcl.ToString("0.000") + " m"; } else { textstring = "VCL1 = " + R.ToString("0.000") + " m, VCL2 = " + L.ToString("0.000") + " m"; } xstor = xt; ystor = yt; textwrite(); xt = xstor; yt = ystor; yt -= textsize / cfg.YMetric * dLead; textstring = "g1 = " + B1.ToString("0.000") + " %, g2 = " + B2.ToString("0.000") + " % "; xstor = xt; ystor = yt; textwrite(); yt = ystor; xt = xstor; yt -= textsize / cfg.YMetric * dLead; if (turn1 == 1) { R = 0.0 - R; } textstring = "Grade Difference = " + DEL.ToString("0.000") + " %"; xstor = xt; ystor = yt; textwrite(); xt = xstor; yt = ystor; yt -= textsize / cfg.YMetric * dLead; dK = Math.Abs(dVcl / (B2 - B1)); if (turn1 == 2) { dK *= -1; } textstring = "K = " + dK.ToString("0.000"); xstor = xt; ystor = yt; textwrite(); xt = xstor; yt = ystor; } last_IPX = IPX; last_IPY = IPY; }