功能增强的进度条控件(源码)[17]

[入库:2006年2月23日] [更新:2007年3月24日]

本文简介:

                   string strText = iRate.ToString() + "%" ;

                   int iTextWidth = (int)g.MeasureString(strText,this.Font).Width ;

                   int iStart = rect.Left + (rect.Width - iTextWidth)/2 ;          

                   Point posS = new Point(iStart -10,rect.Top) ;

                   Point posE = new Point(iStart + iTextWidth + 10,rect.Bottom) ;

                   LinearGradientBrush textbrush = new LinearGradientBrush(posS,posE,this.BackColor,this.ForeColor) ;

                   g.DrawString(strText,this.Font,textbrush,iStart ,rect.Top+5) ;

              }            

         }

 

本文关键:功能增强的进度条控件(源码)
  相关方案
Google
 

本站最佳浏览方式为 分辨率 1024x768 IE 6.0(或更高版本的 IE浏览器)

go top