Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
b+ Beginners Corner
#26
(06-24-2023, 07:48 PM)Dimster Wrote: When you factor in the additional menu item choices of 2,3,4 & 5 , the code can become quite lengthy. Using the modern day QB64PE, I would think the _DELAY command would be drop rate control and "reveal" of the submenu items, as the drop progresses, would be better than the sudden appearance.

bplus is trying to help you with a solution, because adding menu items your way is an impossible way to program. It doesn't matter if you're doing a "dropdown" or any kind of menu. The thing is you need to use a string array to keep track of the elements of the menu, so you could use your menu-creating code again in the future. With the example you provided, you will be able to create that one application, and then hesitate to do another one the same way again.

What if you decided you wanted one menu option to open another menu. Ahh, the sub-menus found in many applications like Libreoffice Writer. It becomes tricky then. Have a double-dimensional string array which is each menu with its distinct set of options. This includes any menu-within-a-menu. Then it requires trickery to show the "main" menus and when to show the sub-menus.

I have code that somebody else wrote long ago for QuickBASIC for a simple menu in SCREEN 0, with colors and stuff. However it doesn't restore the screen area under the menu. Basically it clears the screen, puts on the menu, accepts the input and then clears the screen again for the rest of the program execution. I have to go dig into my backups...

EDIT: Read the previous post again. So what you want is animations? The dumbass animations I'm still trying to kill on Linux LOL which slow down my computer.

Well, then it becomes even more important how you organize your menu. You begin drawing the menu with the first item only, and the box around it. Then a very short pause. Then you redraw the menu, overwriting the bottom of the menu with the second option and restoring the whole box. Then another very short pause. And so on until you have all the menu entries. This is just visual trickery which could affect how the user could interact with the program. I don't know about you but I want snappy response in my programs without discussion. I cannot get it, for example from the QB64 IDE on Linux which is the main reason why I don't use it very much except for formatting source code to post on this forum.
Reply


Messages In This Thread
b+ Beginners Corner - by bplus - 05-20-2023, 06:34 PM
RE: b+ Beginners Corner - by vince - 05-20-2023, 06:47 PM
RE: b+ Beginners Corner - by bplus - 05-20-2023, 07:11 PM
RE: b+ Beginners Corner - by PhilOfPerth - 05-26-2023, 12:12 AM
RE: b+ Beginners Corner - by bplus - 05-26-2023, 04:11 PM
RE: b+ Beginners Corner - by PhilOfPerth - 05-26-2023, 11:18 PM
RE: b+ Beginners Corner - by mnrvovrfc - 05-27-2023, 12:15 AM
RE: b+ Beginners Corner - by PhilOfPerth - 05-27-2023, 02:27 AM
RE: b+ Beginners Corner - by bplus - 05-29-2023, 12:07 AM
RE: b+ Beginners Corner - by bplus - 05-29-2023, 01:37 AM
RE: b+ Beginners Corner - by mnrvovrfc - 05-29-2023, 02:29 AM
RE: b+ Beginners Corner - by bplus - 05-30-2023, 04:17 PM
RE: b+ Beginners Corner - by bplus - 06-15-2023, 03:06 PM
RE: b+ Beginners Corner - by GareBear - 06-15-2023, 07:50 PM
RE: b+ Beginners Corner - by bplus - 06-15-2023, 10:42 PM
RE: b+ Beginners Corner - by bplus - 06-23-2023, 02:46 PM
RE: b+ Beginners Corner - by CharlieJV - 06-23-2023, 03:26 PM
RE: b+ Beginners Corner - by bplus - 06-23-2023, 08:28 PM
RE: b+ Beginners Corner - by TerryRitchie - 06-23-2023, 09:45 PM
RE: b+ Beginners Corner - by bplus - 06-23-2023, 09:56 PM
RE: b+ Beginners Corner - by TerryRitchie - 06-24-2023, 02:47 AM
RE: b+ Beginners Corner - by bplus - 06-23-2023, 10:02 PM
RE: b+ Beginners Corner - by Dimster - 06-24-2023, 02:35 PM
RE: b+ Beginners Corner - by bplus - 06-24-2023, 02:52 PM
RE: b+ Beginners Corner - by Dimster - 06-24-2023, 07:48 PM
RE: b+ Beginners Corner - by mnrvovrfc - 06-24-2023, 08:02 PM
RE: b+ Beginners Corner - by bplus - 06-24-2023, 08:40 PM
RE: b+ Beginners Corner - by TerryRitchie - 06-24-2023, 10:07 PM
RE: b+ Beginners Corner - by bplus - 06-24-2023, 09:08 PM
RE: b+ Beginners Corner - by Dimster - 06-24-2023, 09:12 PM
RE: b+ Beginners Corner - by mnrvovrfc - 06-24-2023, 11:44 PM
RE: b+ Beginners Corner - by bplus - 06-25-2023, 02:27 PM
RE: b+ Beginners Corner - by OldMoses - 06-25-2023, 05:49 PM
RE: b+ Beginners Corner - by bplus - 06-25-2023, 06:40 PM
RE: b+ Beginners Corner - by OldMoses - 06-25-2023, 08:03 PM
RE: b+ Beginners Corner - by bplus - 06-26-2023, 01:14 AM
RE: b+ Beginners Corner - by mnrvovrfc - 06-26-2023, 02:26 AM
RE: b+ Beginners Corner - by Ultraman - 06-26-2023, 11:29 AM
RE: b+ Beginners Corner - by bplus - 06-26-2023, 12:17 PM
RE: b+ Beginners Corner - by Ultraman - 06-26-2023, 12:21 PM
RE: b+ Beginners Corner - by Dimster - 06-26-2023, 02:38 PM
RE: b+ Beginners Corner - by bplus - 06-26-2023, 03:32 PM
RE: b+ Beginners Corner - by bplus - 06-26-2023, 04:48 PM
RE: b+ Beginners Corner - by bplus - 06-27-2023, 01:29 AM
RE: b+ Beginners Corner - by OldMoses - 06-27-2023, 11:49 AM
RE: b+ Beginners Corner - by bplus - 06-27-2023, 12:40 PM
RE: b+ Beginners Corner - by mnrvovrfc - 06-27-2023, 02:12 PM
RE: b+ Beginners Corner - by bplus - 06-27-2023, 03:22 PM
RE: b+ Beginners Corner - by mnrvovrfc - 06-27-2023, 05:21 PM
RE: b+ Beginners Corner - by bplus - 06-27-2023, 05:48 PM
RE: b+ Beginners Corner - by bplus - 06-28-2023, 03:20 AM
RE: b+ Beginners Corner - by bplus - 06-28-2023, 02:54 PM
RE: b+ Beginners Corner - by mnrvovrfc - 06-28-2023, 07:07 PM
RE: b+ Beginners Corner - by Dimster - 06-28-2023, 09:50 PM
RE: b+ Beginners Corner - by bplus - 06-28-2023, 10:27 PM
RE: b+ Beginners Corner - by bplus - 06-04-2024, 01:17 AM
RE: b+ Beginners Corner - by PhilOfPerth - 06-04-2024, 11:37 PM
RE: b+ Beginners Corner - by bplus - 06-05-2024, 12:42 AM
RE: b+ Beginners Corner - by gaslouk - 06-05-2024, 02:37 PM
RE: b+ Beginners Corner - by bplus - 06-30-2024, 07:38 PM
RE: b+ Beginners Corner - by bplus - 07-01-2024, 03:42 PM
RE: b+ Beginners Corner - by aurel - 07-01-2024, 06:16 PM
RE: b+ Beginners Corner - by bplus - 07-01-2024, 07:39 PM
RE: b+ Beginners Corner - by bplus - 07-07-2024, 06:42 PM



Users browsing this thread: 10 Guest(s)