Nicer plot

Change-Id: I6f080a4c26ad8ce574661228a4d4b53632d2f870
This commit is contained in:
Felix Raimundo
2016-04-07 12:38:08 +02:00
parent 4e8ee1bf02
commit f334977c6a
8 changed files with 111 additions and 34 deletions

View File

@@ -174,6 +174,12 @@ text_event_t get_text(char* txt) {
} else if (event == DOWN_ARROW) {
text_event.event = DOWN_ARROW;
break;
} else if (event == PLOT) {
text_event.event = PLOT;
input[max] = '\0';
text_event.text = (char*) malloc(sizeof(char) * (index + 1));
memcpy(text_event.text, input, (size_t) (index + 1));
break;
} else {
assert(false); // unreachable.
}