A library to assist with creating GUI on the Vex V5 Brain. Allows creation of included widgets or custom ones that you make yourself. This is not a pros UI library, it is made for use with vexcode pro.
Check out the wiki: https://github.com/RobotMan192/VexV5-CustomUI/wiki
- Button
- Combo Box
- Text Box
- Install the library by creating a new folder called "lib" in your project directory make sure that you only do this in the file explorer not the project editor
- Drag and drop the CustomUI directory into it
- Update your projects makefile by adding the following code
SRC_C += $(wildcard lib/*/*.cpp)
SRC_C += $(wildcard lib/*/*/*.cpp)
SRC_H += $(wildcard lib/*/*.h)
SRC_H += $(wildcard lib/*/*/*.h)
Include the CustomUI header in your file that you are going to use it
#include "../lib/CustomUI/CustomUI.h"
Create a display this is where you will add widgets
CUI::Display display(&Brain);
In the main function add a button
CUI::Button randomButton("Press Me",CUI::ButtonStyle{},CUI::Rect(4,4,100,25),[](){
printf("Button Clicked\n");
});
Connect the button to the display
display.addWidget(&randomButton);
Initialize the display
display.init();
int main() {
// Initializing Robot Configuration. DO NOT REMOVE!
vexcodeInit();
CUI::Display display(&Brain);
CUI::Button randomButton("Press Me",CUI::ButtonStyle{},CUI::Rect(4,4,100,25),[](){
printf("Button Clicked\n");
});
display.addWidget(&randomButton);
display.init();
}