diff options
author | RadAd <adamgates84+github@gmail.com> | 2019-05-27 12:40:09 +1000 |
---|---|---|
committer | RadAd <adamgates84+github@gmail.com> | 2019-05-27 12:40:09 +1000 |
commit | f7762daa92f584c34af1a1dcbe8ff400eb9921a0 (patch) | |
tree | cdf9202054c94a8a1c2702e373966966ae2b6c7c /WinUtils.h | |
parent | c8fe70f713e273e14fb998a663e787f320093fae (diff) | |
download | RadTerminal-f7762daa92f584c34af1a1dcbe8ff400eb9921a0.tar.gz RadTerminal-f7762daa92f584c34af1a1dcbe8ff400eb9921a0.zip |
Support scrollbar
Diffstat (limited to 'WinUtils.h')
-rw-r--r-- | WinUtils.h | 18 |
1 files changed, 18 insertions, 0 deletions
@@ -18,6 +18,24 @@ inline BOOL UnadjustWindowRect( return fRc; } +inline BOOL UnadjustWindowRectEx( + LPRECT prc, + DWORD dwStyle, + BOOL fMenu, + DWORD dwExStyle) +{ + RECT rc; + SetRectEmpty(&rc); + BOOL fRc = AdjustWindowRectEx(&rc, dwStyle, fMenu, dwExStyle); + if (fRc) { + prc->left -= rc.left; + prc->top -= rc.top; + prc->right -= rc.right; + prc->bottom -= rc.bottom; + } + return fRc; +} + inline RECT Rect(POINT p1, POINT p2) { return { p1.x, p1.y, p2.x, p2.y }; |