bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Windows with border in panels


From: Sadrul H Chowdhury
Subject: Re: Windows with border in panels
Date: Mon, 7 Aug 2006 19:21:29 -0400


On 8/7/06, JKD <address@hidden> wrote:

For some reason I can't get the desired effect.

Try the following piece of code:

/**** START ****/
#include <ncurses.h>
#include <panel.h>

int main()
{
    WINDOW *one, *sub, *two;
    PANEL *pone, *ptwo;

    initscr();
    noecho();

    30, 1, 1);
    two = newwin(10, 20, 3, 6);

    pone = new_panel(one);
    ptwo = new_panel(two);

    box(one, 0, 0);
    box(two, 0, 0);
    top_panel(ptwo);

    update_panels();
    doupdate();
    getch();

    sub = subwin(one, 8, 28, 2, 2);
    wprintw(sub, "this is a long string %60s",
                      "and this to end the log string.");
    touchwin(one);
    update_panels();
    doupdate();
    getch();

    endwin();

    return 0;
}
/**** END ****/

Sadrul
reply via email to

[Prev in Thread] Current Thread [Next in Thread]