@@ -736,15 +736,15 @@ private void dgvCategories_CellFormatting(object sender, DataGridViewCellFormatt
736736
737737 if ( type == ShpfileType . SHP_POLYGON )
738738 {
739- sdo . DrawRectangle ( g . GetHdc ( ) , 0.0f , 0.0f , img . Width - 1 , img . Height - 1 , true , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
739+ sdo . DrawRectangle ( g . GetHdc ( ) . ToInt32 ( ) , 0.0f , 0.0f , img . Width - 1 , img . Height - 1 , true , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
740740 }
741741 else if ( type == ShpfileType . SHP_POLYLINE )
742742 {
743- sdo . DrawLine ( g . GetHdc ( ) , 0.0f , 0.0f , img . Width - 1 , img . Height - 1 , true , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
743+ sdo . DrawLine ( g . GetHdc ( ) . ToInt32 ( ) , 0.0f , 0.0f , img . Width - 1 , img . Height - 1 , true , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
744744 }
745745 else if ( type == ShpfileType . SHP_POINT )
746746 {
747- sdo . DrawPoint ( g . GetHdc ( ) , 0.0f , 0.0f , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
747+ sdo . DrawPoint ( g . GetHdc ( ) . ToInt32 ( ) , 0.0f , 0.0f , img . Width , img . Height , Colors . ColorToUInteger ( dgvCategories . BackgroundColor ) ) ;
748748 }
749749 g . ReleaseHdc ( ) ;
750750 g . Dispose ( ) ;
0 commit comments