Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 83203 - Focus problems in program with scrollable textbox and scrollable listbox
Summary: Focus problems in program with scrollable textbox and scrollable listbox
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: newt
Version: rawhide
Hardware: i686
OS: Linux
low
medium
Target Milestone: ---
Assignee: Miroslav Lichvar
QA Contact: Jay Turner
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2003-01-31 08:10 UTC by Martin Sjvgren
Modified: 2015-01-08 00:03 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-06-08 15:59:31 UTC


Attachments (Terms of Use)

Description Martin Sjvgren 2003-01-31 08:10:40 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 Galeon/1.2.7 (X11; Linux i686; U;) Gecko/20021226
Debian/1.2.7-6

Description of problem:
The following program demonstrates the behaviour. I can't find a way to scroll
the listbox, only the textbox. I've tried this in mlterm, xterm and a
framebuffer console, same result.

#include <stdio.h>
#include <string.h>
#include <newt.h>

int
main()
{
    int i, width = 75, height = 22;
    newtComponent form, listbox, textbox, bOk;

    newtInit();
    newtCls();
    newtCenteredWindow(width, height, "Test");
    form = newtForm(NULL, NULL, 0);
    textbox = newtTextbox(1, 2, width-4, 10, NEWT_FLAG_WRAP | NEWT_FLAG_SCROLL);
    newtTextboxSetText(textbox, "abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd abcd
abcd abcd abcd abcd abcd abcd abcd abcd");
    listbox = newtListbox(1, 13, 6, NEWT_FLAG_RETURNEXIT);
    for (i = 0; i < 10; i++) {
        char text[256];
        sprintf(text, "Choice %d", i);
        newtListboxAppendEntry(listbox, text, (void *)i);
    }
    bOk = newtCompactButton((width-6)/2, height-2, "OK");
    newtFormAddComponents(form, listbox, textbox, bOk, NULL);
    newtRunForm(form);
    newtPopWindow();
    newtFinished();
    return 0;
}

Version-Release number of selected component (if applicable): 0.51.0

How reproducible: Always

Comment 1 Petr Rockai 2005-10-04 11:06:08 UTC
Confirmed, this is indeed a problem. Apparently, this combination of widgets 
is probably unusual enough to be not a problem for most programs. I will see 
if i can fix this... 

Comment 2 Miroslav Lichvar 2006-06-08 15:59:31 UTC
Fixed in newt-0.52.2-7.


Note You need to log in before you can comment on or make changes to this bug.