How can you create a window without caption and border using CreateWindowEx()? And I why do you use ‘|’ OR operator to combine styles instead of ‘&’ And?
How can you create a window without caption and border using CreateWindowEx()? And I
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
If you want a border, you can add WS_BORDER or WS_DLGFRAME (Not both). If you don’t want to show the window in the taskbar, add the WS_EX_TOOLWINDOW extended style.
As to why you need to bitwise OR the styles; OR will combine all the style values, AND is used (by windows) to check which styles are set.
Say we had two styles (WS_FOO=1,WS_BAR=2):
See wikipedia for more info.