50g: Create directory-like GROB for custom menus
|
01-24-2023, 11:17 PM
Post: #1
|
|||
|
|||
50g: Create directory-like GROB for custom menus
Here I would like to share with you a very small program that I use to make my custom menus look more like the default ones in the calculator.
I called it CRDIM, as in CReate Directory IMage. WHAT THE PROGRAM DOES: When you start the program, it will ask for a 0 to 5 letters directory name; after inserting said name, it will convert it to a GROB and then add it to a custom-made GROB of a folder. When it is finished, it will leave the final GROB on the 2st level of the stack (to visually check if the program did what we wanted it to do), and the same GROB converted to string on the 1st level. To use the resulting GROB on a custom menu, copy the string on the 1st level and insert it as the label of custom menu key. EXAMPLE: I want to make a custom menu that has a sub-menu that lets me access the default functions DUP OVER DROP; the sub-menu has to be reachable via the custom menu key "SUBMN". I will start the CRDIM program and, when asked, i will enter the SUBMN string; on the stack I will find the GROB on the second level and the string of said GROB on the first level (in this case, the string is GROB 21 8 E30000FFFFF1359591D55151B59151755551919551FFFFF1). I will then EDIT the string (press the down-arrow) and copy it. Then, I will create the list used for the custom menu: Code: {{GROB 21 8 E30000FFFFF1359591D55151B59151755551919551FFFFF1 \<< {DUP OVER DROP} TMENU \>>}} MENU THE PROGRAM: Code: \<< "Enter 1 to 5-letter name of |
|||
01-25-2023, 03:46 AM
Post: #2
|
|||
|
|||
RE: 50g: Create directory-like GROB for custom menus
Alternative if you don't mind using the SYSEVAL command: Put the desired string (1 to 5 characters long) on level 1 of the stack, then do this:
#2E1EBh SYSEVAL That creates a menu-style label grob containing the desired label. If you also want the grob to be expressed as a string (as Matteo's program does), just follow the above with →STR. <0|ɸ|0> -Joe- |
|||
01-26-2023, 02:20 PM
Post: #3
|
|||
|
|||
RE: 50g: Create directory-like GROB for custom menus
Thank you Joe! I just started learning User RPL, and I barely touched all the references for System RPL (they seems so advanced!). Your solution seems much more "elegant", and it inspires me to start learning about all the other "hidden" commands that maybe can simplify all my other programs.
|
|||
« Next Oldest | Next Newest »
|
User(s) browsing this thread: 1 Guest(s)