Forráskód Böngészése

修改 样品孔编辑器 坐标显示打开时 生成效果图 无坐标的bug

cxs 1 éve
szülő
commit
9bdfe1dfae

+ 9 - 3
OTSIncAMeasureApp/7-OTSProgMgrInfo/Stage/DlgStageEdit.cs

@@ -433,8 +433,13 @@ namespace OTSMeasureApp._7_OTSProgMgrInfo.Stage
 
             // draw ratio
             stageDisplayHelp.DrawRatio(nBounderyWidth, nWidth, nHeight, pDC, (IntPtr)pWnd, rc);
-            
-            //stageDisplayHelp.DrawXY(pDC, m_ctrlStagePicture.Width, m_ctrlStagePicture.Height, PixSize, coordinateSystemEndpoint);
+
+            if (button_Coordinate.Text == "坐标系关闭")
+            {
+                double coordinateSystemEndpointX = nBounderyWidth / 2;
+                double coordinateSystemEndpointY = nBounderyHeight / 2;
+                stageDisplayHelp.DrawXY(pDC, m_ctrlStagePicture.Width, m_ctrlStagePicture.Height, PixSize, coordinateSystemEndpointX, coordinateSystemEndpointY);
+            }
             pLTGrayBrush.Dispose();
             //pBlackBrush.Dispose();
             //pWriteBrush.Dispose();
@@ -575,6 +580,7 @@ namespace OTSMeasureApp._7_OTSProgMgrInfo.Stage
             }
             else
             {
+                button_Coordinate.Text = "坐标系显示";
                 if(m_pStage != null)
                 {
                     DrawStage();
@@ -583,7 +589,7 @@ namespace OTSMeasureApp._7_OTSProgMgrInfo.Stage
                 {
                     m_ctrlStagePicture.Refresh();
                 }
-                button_Coordinate.Text = "坐标系显示";
+                
             }
         }
     }