NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
lib/47376: libmenu doesn't show menu_mark
>Number: 47376
>Category: lib
>Synopsis: libmenu doesn't show menu_mark
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: lib-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Dec 29 16:30:00 +0000 2012
>Originator: Julian Fagir
>Release: NetBSD 6.0-RELEASE
>Organization:
>Environment:
>Description:
When trying to use the set_menu_mark of libmenu, it does not set the mark, but
displays spaces instead of the set characters.
>How-To-Repeat:
Run this program:
#include <menu.h>
#include <form.h>
#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <stdio.h>
int
main(int arg, char *argv[])
{
int i;
WINDOW *mainwin;
MENU *menu;
ITEM *items[3];
initscr();
mainwin = newwin(20, 70, 2, 2);
box(mainwin, 0, 0);
mvwprintw(mainwin, 1, 1, "Creating window...");
wrefresh(mainwin);
items[0] = new_item("Bla1", NULL);
items[1] = new_item("Bla2", NULL);
items[2] = NULL;
menu = new_menu(items);
set_menu_win(menu, mainwin);
set_menu_sub(menu, derwin(mainwin, 15, 60, 2, 2));
set_menu_mark(menu, ">");
refresh();
post_menu(menu);
wrefresh(mainwin);
while (1) {
menu_driver(menu, REQ_DOWN_ITEM);
wrefresh(mainwin);
sleep(1);
}
endwin();
return 0;
}
>Fix:
Home |
Main Index |
Thread Index |
Old Index