Screen 0 Hardware PopUp - Printable Version +- QB64 Phoenix Edition (https://staging.qb64phoenix.com) +-- Forum: QB64 Rising (https://staging.qb64phoenix.com/forumdisplay.php?fid=1) +--- Forum: Code and Stuff (https://staging.qb64phoenix.com/forumdisplay.php?fid=3) +---- Forum: Works in Progress (https://staging.qb64phoenix.com/forumdisplay.php?fid=9) +---- Thread: Screen 0 Hardware PopUp (/showthread.php?tid=1198) |
Screen 0 Hardware PopUp - SMcNeill - 11-28-2022 Code: (Select All) SCR = _NewImage(80, 25, 0) This is one @Pete will probably like. What we're doing here is making a 600x2000 graphic screen... then we're taking a portion of that screen and scaling it so we can display it as a pop-up centered over 80% of our SCREEN 0 screen. We have arrow keys! We have scalable sliders! And... umm.... we resize? umm... We don't really do anything right now, as this is just a work-in-progress, but what we CAN do now, is draw graphics, text, input boxes, or other things inside that popup box, and have them center and display all nice and pretty on our screen 0 text screen. Just place what you'd like to see on the screen where you currently see the code for: Code: (Select All) _Dest OptionScreen RE: Screen 0 Hardware PopUp - mnrvovrfc - 11-28-2022 This is nice. I like it. But there's a small problem. It looks like my computer running Linux (Manjaro MATE) doesn't like "SkyBlue", indicates error #5 with your usage of "CLS" and "COLOR" in a loop. I tested a simple program with the special color names, 32-bit color and using those other two color keywords and a print statement revealing red, green, blue registers of "SkyBlue". It ran perfectly which made me scratch my head. In your program I noticed a few "33" instead of "32" for third parameter to "_NEWIMAGE()" but I don't dare speculate what is the source of the problem. I have to comment out the "CLS" and "COLOR" so it works correctly but with black background for the "list box". Combining the two into one "COLOR" statement didn't do any good neither. Update: I verified in the first time "COLOR" is called, the fake list box gets its background set to "SkyBlue", but then when it's called again it errors. (scratch head) RE: Screen 0 Hardware PopUp - SMcNeill - 11-28-2022 (11-28-2022, 09:58 PM)mnrvovrfc Wrote: This is nice. I like it. But there's a small problem. It looks like my computer running Linux (Manjaro MATE) doesn't like "SkyBlue", indicates error #5 with your usage of "CLS" and "COLOR" in a loop. I tested a simple program with the special color names, 32-bit color and using those other two color keywords and a print statement revealing red, green, blue registers of "SkyBlue". It ran perfectly which made me scratch my head. In your program I noticed a few "33" instead of "32" for third parameter to "_NEWIMAGE()" but I don't dare speculate what is the source of the problem. Edited to fix that issue. Problem was a stray _DEST going back to SCREEN 0 before exiting the function. My apologies. |