zoukankan      html  css  js  c++  java
  • 当窗体风格为none时,窗体排布

    http://blogs.msdn.com/llobo/archive/2008/02/07/maximizing-borderless-window-using-sysparameter-values.aspx

    Earlier on, I had written a post on maximizing a borderless (WindowStyle=None) window but without covering the taskbar. This solution works well but was not that nice to look at implementation wise :) ... However, theres a simplere solution to achieve the same. I get quite a few queries about the previous post, so I thought it would be a good idea to post this simple solution..

     <Window

          Width="{DynamicResource {x:Static SystemParameters.MaximizedPrimaryScreenWidthKey}}"

          Height="{DynamicResource {x:Static SystemParameters.MaximizedPrimaryScreenHeightKey}}"

          WindowStartupLocation="CenterScreen"

          WindowStyle="None"/>

    SystemParameters to the rescue... for the code behind version,

    win.Height = SystemParameters.MaximizedPrimaryScreenHeight;

    win.Width = SystemParameters.MaximizedPrimaryScreenWidth;

    win.Top = 0;win.Left = 0;

  • 相关阅读:
    mysql注入小测试
    让函数返回指定值实用写法
    源码下载网址
    带宽
    九度oj 题目1080:进制转换
    九度oj 题目1079:手机键盘
    poj 3046 Ant Counting
    整数拆分问题
    poj 2229 Sumsets
    九度oj 题目1411:转圈
  • 原文地址:https://www.cnblogs.com/ningth/p/1151333.html
Copyright © 2011-2022 走看看