Win32 Plus Extra Height of Caption Bar
you set the size of the non-client area by handling the WM_NCCALCSIZE
message. But don't do this unless you plan to do all of the non-client drawing as well by handling WM_NCPAINT
Edit: here are two code fragments, one that handles WM_NCCALCSIZE and provides a simple n pixel border, and another than adds some extra pixels after DefWindowProc has done the default handling.
case WM_NCCALCSIZE:
{
lRet = ;
const int cxBorder = ;
const int cyBorder = ;
InflateRect((LPRECT)lParam, -cxBorder, -cyBorder);
} case WM_NCCALCSIZE:
{
LPNCCALCSIZE_PARAMS pncc = (LPNCCALCSIZE_PARAMS)lParam;
//pncc->rgrc[0] is the new rectangle
//pncc->rgrc[1] is the old rectangle
//pncc->rgrc[2] is the client rectangle lRet = DefWindowProc (hwnd, WM_NCCALCSIZE, wParam, lParam);
pncc->rgrc[].top += ExtraCaptionHeight;
}
You can learn a lot by passing WM_NCCALCSIZE to DefWindowProc and looking at the values of the NCCALCSIZEPARAM before and after.
Win32 Plus Extra Height of Caption Bar的更多相关文章
- Status bar and navigation bar appear over my view's bounds in iOS 7
转自:http://stackoverflow.com/questions/17074365/status-bar-and-navigation-bar-appear-over-my-views-bo ...
- Customizing Navigation Bar and Status Bar
Like many of you, I have been very busy upgrading my apps to make them fit for iOS 7. The latest ver ...
- Using SetWindowRgn
Using SetWindowRgn Home Back To Tips Page Introduction There are lots of interesting reasons for cre ...
- File Input Features
文件输入功能 1.该插件将将一个简单的 HTML 文件输入转换为高级文件选取器控件.将有助于对不支持 JQuery 或 Javascript 的浏览器的正常 HTML 文件输入进行回退. 2.文件输入 ...
- KRBTabControl
This article explains how to make a custom Windows Tab Control in C#. Download demo project - 82.4 K ...
- windows程序设计读书笔记2——字符显示1
本程序使用GetSystemMetrics获取windows各种图像选项,并输出字符到窗口中. #define WINVER 0x0500 #include <windows.h> #in ...
- 《windows程序设计》学习_4:文本输出,加滚动条
//总行数 #define NUMLINES ((int) (sizeof sysmetrics / sizeof sysmetrics [0])) struct { int Index ; TCHA ...
- WTL介绍
WTL简单介绍 关键词: WTL WTL是一个好东东.它开发的程序都很短小精悍.对开发WIN32的应用有很好的优点.它不用MFC开发.但可以高速产生窗体和控件. 以文本方式查看主题 - 温馨小筑 ...
- Installshield停止操作系统进程的代码 --IS6及以上版本适用
原文:Installshield停止操作系统进程的代码 --IS6及以上版本适用 setup.rul的代码 Code;end;///////////////////////////////////// ...
随机推荐
- python解析xml模块封装代码
在python中解析xml文件的模块用法,以及对模块封装的方法.原文转自:http://www.jbxue.com/article/16586.html 有如下的xml文件:<?xml vers ...
- 状态可以通过动画切换的按钮--第三方开源--TickPlusDrawable
Android tickplusdrawable(TickPlusDrawable)在github上的项目主页是:https://github.com/flavienlaurent/tickplusd ...
- DevExpress 关于 GridView 表格编辑中 点击其他按钮里导致 值未取到处理
只需要给添加以下代码 在执行其他按钮前调 用一下 就可以了:主要是用来关闭编辑以及更新当前行编辑内容 this.gridControl1.FocusedView.CloseEditor(); this ...
- STM32F0xx_USART收发配置详细过程
前言 串口对于处理器来说算是一种标配,也是在软件开发中必不可少的,那就是使用串口来调试信息(打印出相应的信息).STM32F0系列的芯片,串口根据型号不同,数量也不同,从1个到8个不等. 今天主要总结 ...
- feel
昨天我大脑中还在盘旋几个关键字:健康 选择 方向 方法今天只有选择了,健康 是你选择了一种生活习惯,你能掌控的也就是好的习惯,选择了一种正确的价值观,选择了一个好的开始方向有很多,你的选择是结果方法 ...
- ED/EP系列3《基本指令》
Ø --APPLICATIONBLOCK(应用锁定): Ø --APPLICATION UNBLOCK(应用解锁): Ø --CARDBLOCK(卡片锁定): Ø --EXTERNAL AUTHENT ...
- EMVTag系列16《AC响应数据》
在一个联机交易中,要传送到发卡行的专有应用数据. 字段 长度(字节) 赋值 说明 长度 1 07 分散密钥索引 1 00 密文版本号 1 01 根据发卡行密钥版本设置 卡片验证结果(CVR) 4 03 ...
- .NET开源工作流RoadFlow-表单设计-文本框
点击表单设计器工具栏上的文本框按钮,会弹出文本框属性对话框: 绑定字段:该文本框与表单属性设置中选择的表的某个字段绑定(该文本框中的值将会保存到该字段中). 默认值:该文本框的初始化值. 宽度:文本框 ...
- SQL注入式攻击
百度百科:http://baike.baidu.com/link?url=GQbJ2amTzTahZA7XJSBDLYYkN3waQ9JCoJ0l--tCWlvKQibe0YaH4hpmgEnLyn0 ...
- hdu 5273 Dylans loves sequence
题目连接 http://acm.hdu.edu.cn/showproblem.php?pid=5273 Dylans loves sequence Description Dylans is give ...