Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Try to fix bad caption area detection. #230

Merged
merged 5 commits into from
Jul 26, 2022
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Add info in the identify window option
RamonUnch authored Jul 23, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
commit 0db85a723cd976f4afb6048e212e84cd61233052
6 changes: 6 additions & 0 deletions config.c
Original file line number Diff line number Diff line change
@@ -1102,12 +1102,18 @@ LRESULT CALLBACK FindWindowProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lPara
}
SetDlgItemText(page, IDC_GWLSTYLE, _itow(GetWindowLongPtr(window, GWL_STYLE), txt, 16));
SetDlgItemText(page, IDC_GWLEXSTYLE, _itow(GetWindowLongPtr(window, GWL_EXSTYLE), txt, 16));
// WM_NCHITTEST messages info at current pt
_itow(HitTestTimeout(nwindow, pt.x, pt.y), txt, 10);
wchar_t tt[8];
_itow(HitTestTimeout(window, pt.x, pt.y), tt, 10);
wcscat(txt, L"/");wcscat(txt, tt);
SetDlgItemText(page, IDC_NCHITTEST, txt);
// IDC_DWMCAPBUTTON
RECT rc;
SetDlgItemText(page, IDC_DWMCAPBUTTON
, (GetCaptionButtonsRect(window, &rc) && PtInRect(&rc, pt))?L"Yes":L"No");

// Window rectangle info
if (GetWindowRectL(window, &rc)) {
SetDlgItemText(page, IDC_RECT, RectToStr(&rc, txt));
}
1 change: 1 addition & 0 deletions resource.h
Original file line number Diff line number Diff line change
@@ -162,3 +162,4 @@

#define IDC_OUTTB 2083
#define IDC_UNIKEYHOLDMENU 2084
#define IDC_DWMCAPBUTTON 2085
6 changes: 4 additions & 2 deletions window.rc
Original file line number Diff line number Diff line change
@@ -51,10 +51,12 @@ BEGIN
EDITTEXT IDC_GWLSTYLE, 160,165,50,12,ES_AUTOHSCROLL

RTEXT "WM_NCHITTEST:", 0, 10,182,60,8
EDITTEXT IDC_NCHITTEST, 72,180,30,12,ES_AUTOHSCROLL
EDITTEXT IDC_NCHITTEST, 72,180,25,12,ES_AUTOHSCROLL
RTEXT "In DWM Buttons:", 0, 10,197,60,8
EDITTEXT IDC_DWMCAPBUTTON, 72,195,25,12,ES_AUTOHSCROLL
RTEXT "EXSTYLE:", 0, 115,182,42,8
EDITTEXT IDC_GWLEXSTYLE, 160,180,50,12,ES_AUTOHSCROLL
RTEXT "RECT:", 0, 97,197,25,8
LTEXT "RECT:", 0, 102,197,22,8
EDITTEXT IDC_RECT, 125,195,85,12,ES_AUTOHSCROLL
END