HXLD hXLD = new HXLD();
//取高宽比与宽度
hXLD.HeightWidthRatioXld(out HTuple width, out HTuple ratio);
//取区域中点
hXLD.AreaCenterPointsXld(out HTuple row, out HTuple col);
//生成矩形左上与右下角坐标
HTuple Row1 = row - width / 2;
HTuple Col1 = col - width * ratio / 2;
HTuple Row2 = col + width / 2;
HTuple Col2 = col + width * ratio / 2;
HRegion hRegion = new HRegion();
//创建矩形
hRegion.GenRectangle1(Row1, Col1, Row2, Col2);