[Urwid] Re: placing buttons and widgets

Fabian Braennstroem f.braennstroem at gmx.de
Fri Oct 6 06:17:36 EDT 2006


Hi,

it's me again :-)

* Fabian Braennstroem <f.braennstroem at gmx.de> wrote:
> Hi to both,
>
> * Rebecca Breu <rebecca at rbreu.de> wrote:
>> Zitat von Ian Ward <ian at excess.org>:
>>
>>> boxwidget = a ListBox or something
>>> buttons = a Pile, Columns or GridFlow widget containing buttons
>>> box_and_buttons = Pile([boxwidget, ('flow', buttons)])
>>>
>>> then box_and_buttons should be treated as a box widget and it will
>>> display buttons at the bottom, leaving the rest of the space for boxwidget.
>>
>> Hey, that answers a question that I posted two weeks ago! Somehow I was
>> confused about the usage of the 'flow' attribute, but now it works! :)
>>
>> When I wrote the filechooser, the Pile widget could only contain flow widgets,
>> that's why the ListBox widgets have a fixed height. I had the same problem in
>> other cases, too, so the new flexible behaviour of the Pile widget is really
>> a great thing to have.
>>
>> Now that I know how I think I will update the filechooser example.
>
> Thanks to both! Maybe, I can 'clone' lfm using your new
> filechooser and urwid one day ... the hardest thing, or
> better the first thing, would be to get the interface a
> similar look :-) From there on it should be possible to use
> the corresponding functions from lfm ...

I got one more question. Is it possible to create a command
prompt like the midnight commander has? It might be a nice
additional feature...

Greetings!
 Fabian





More information about the Urwid mailing list