'TI-BASIC library for creating nicer menus and UIs

I've been creating TI-BASIC apps for my calculator, but would love to upgrade the menu and interface from this default style:

To something more like this, that I've seen in other apps:

enter image description here

Other than coding those screens pixel by pixel using Pxl-On(), which will be difficult and also slow to render, what options are available to do this from within TI-BASIC?

I've seen that by installing the DoorsCS library, you get access to a UI library, which is sort of what I'm after, but that seems to be mostly mouse-cursor driven which I find cumbersome for the user. I would be keen to know if there's something closer to the images above. Ideally a library written in assembly but accessible from TI-BASIC.

Does it exist? Or will I need to write one?



Solution 1:[1]

Short answer:

Unless there's an existing library out there that I don't know of... no, there's no functions, but you can draw them faster and easier than setting individual pixels.

Long answer:

I know of no functions in pure basic analogous to Menu() that would do this, and I'm confident I would know about them if they existed. Maybe external libraries exist that you could install, but I don't know anything about those.

However, there are these functions would let you draw the menus much faster and easier than setting individual pixels:

  • 2nd->Draw->0:Text( will draw a string of text on the graph for you, in the same small font as in your pictures.
  • You can use 2nd->Draw->2:Line( to draw the boxes. Making them look as in your pictures with the "shade" behind them would be more work but doable.
  • 2nd->Draw->7:Shade will shade an area in black pixels, though be warned, this takes a long time when running.

The white text on a black background is harder, so I'd recommend just using black text on a white background. But if you really want to: The easiest way in pure basic I can think of is drawing the text, then running Pxl-Change for every pixel in the rectangular area. Another possibility is assembly programs that allow for a faster color inversion option for Text(; I can't remember where but I believe I have seen an assembly program that does this before.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1