Han*_*ant 11
由一位恼怒的Microsoft程序员(为了适应页面而编辑),TabPage的源代码中留下了一条评论:
//HACK: to ensure that the tabpage draws correctly (the border will get 
//  clipped and gradient fill will match correctly with the tabcontrol).
//  Unfortunately, there is no good way to determine the padding used 
//  on the tabpage.
//  I would like to use the following below, but GetMargins is busted 
//  in the theming API:
//VisualStyleRenderer visualStyleRenderer = new VisualStyleRenderer(VisualStyleElement.Tab.Pane.Normal);
//Padding themePadding = visualStyleRenderer.GetMargins(e.Graphics, MarginProperty.ContentMargins);
Run Code Online (Sandbox Code Playgroud)
Visual Styles是一个主要的bug工厂,特别是TabControl.检查此答案,以便有选择地为TabControl关闭它,这样您就可以获得您习惯的行为.当然它确实改变了外观.
|   归档时间:  |  
           
  |  
        
|   查看次数:  |  
           5533 次  |  
        
|   最近记录:  |