1. Back to Bitmaps
- Posted by don cole <doncole at pacbell.net> Mar 26, 2006
- 424 views
WS_EX_CLIENTEDGE, --style Ex OR({WS_OVERLAPPED,WS_SYSMENU}), --style WS_SYSMENU=#80000 WS_OVERLAPPED=#0 Since #80000 ORed with #0 = #80000 Why not just put WS_EX_CLIENTEDGE, --style Ex WS_SYSMENU, --style Why is the OR needed at all? Don Cole
2. Re: Back to Bitmaps
- Posted by Al Getz <Xaxo at aol.com> Mar 26, 2006
- 412 views
don cole wrote: > > WS_EX_CLIENTEDGE, --style Ex > OR({WS_OVERLAPPED,WS_SYSMENU}), --style > > WS_SYSMENU=#80000 > WS_OVERLAPPED=#0 > > Since #80000 ORed with #0 = #80000 > > Why not just put > WS_EX_CLIENTEDGE, --style Ex > WS_SYSMENU, --style > > Why is the OR needed at all? > > > Don Cole Hi Don, Yes, that would work too Take care, Al And, good luck with your Euphoria programming! My bumper sticker: "I brake for LED's" From "Black Knight": "I can live with losing the good fight, but i can not live without fighting it". "Well on second thought, maybe not."
3. Re: Back to Bitmaps
- Posted by Jason Gade <jaygade at yahoo.com> Mar 26, 2006
- 446 views
don cole wrote: > > WS_EX_CLIENTEDGE, --style Ex > OR({WS_OVERLAPPED,WS_SYSMENU}), --style > > WS_SYSMENU=#80000 > WS_OVERLAPPED=#0 > > Since #80000 ORed with #0 = #80000 > > Why not just put > WS_EX_CLIENTEDGE, --style Ex > WS_SYSMENU, --style > > Why is the OR needed at all? > > > Don Cole The names are added for clarity. The programmer doesn't necessarily know that WS_OVERLAPPED = 0. Plus when reading the source code someone can see all of the options that the original programmer is intending, whether they are included in some other option or not. If you know what you are doing, you could just put in the hex value you want to use. But you use the names so someone else reading your program can figure out what you are doing. -- "Any programming problem can be solved by adding a level of indirection." --anonymous "Any performance problem can be solved by removing a level of indirection." --M. Haertel "Premature optimization is the root of all evil in programming." --C.A.R. Hoare j.