Ian Ward | 5 Nov 2005 22:25
Favicon
Gravatar

ANN: Speedometer 2.1 - bandwidth and download monitor

Announcing Speedometer 2.1
--------------------------

Speedometer home page:
  http://excess.org/speedometer/

Download:
  http://excess.org/speedometer/speedometer.py

New in this release:
====================

  - New simultaneous display of multiple graphs with options for stacking
    graphs vertically or horizontally

  - New labels to differentiate each graph

  - Removed 0-32 B/s from display to make more room for higher speeds

  - Fixed a wait_creation bug

About Speedometer
=================

Speedometer is a console bandwidth and file download progress monitor with
a logarithmic bandwidth display and a simple command-line interface.

Speedometer requires Python 2.1 or later and Urwid 0.8.9 or later for
full-console bar graph display.  Urwid may be downloaded from:
http://excess.org/urwid/
(Continue reading)

antonio araujo | 7 Nov 2005 16:36
Picon

A problem with shift tab

Hello.
Thanks for your interesting work.
I am learning on it, and discover a little problem:
the combination "shift + tab" returns 'meta [z' whith the spanish keyboard.

I am working on a simple interface to a little database called
KirbyBase. I need the tab style navigation for table fields.

Thanks for your help.

Antonio.

Ian Ward | 7 Nov 2005 18:20
Favicon
Gravatar

A problem with shift tab

antonio araujo wrote:

>Hello.
>Thanks for your interesting work.
>I am learning on it, and discover a little problem:
>the combination "shift + tab" returns 'meta [z' whith the spanish keyboard.
>  
>
I get the same with my english keyboard in xterm.  Add the following 
line to the list called "_escape_sequences" in curses_display.py:
        ('[Z','shift tab'),

I'll include this change in the next release.  Be aware that many 
terminals do not send this escape sequence for shift+tab (some just send 
'tab') and provide an alternative keystroke for "tabbing backwards".

>I am working on a simple interface to a little database called
>KirbyBase. I need the tab style navigation for table fields.
>
That's great. Let me know when you've finished your interface.

Ian

antonio araujo | 8 Nov 2005 16:48
Picon

A problem with shift tab

Hello Ian. Thanks for your answer, but after change the line, it dont
works for me.
I will send you the pre-pre-alpha version of my RecordEditor.
I have many problems with urwid, and I need some help.
-I need to navigate the fields with the tab key by default.
-I need a simple component to do a RadioButton, something like:
 x = RadioButton("red", "green", "blue")
-I dont understand (by now) how to make the buttons illuminate
completely when in focus.
-When I return from the record edition, I see some Ctrl+D in the
screen when I move from one button to other. I dont know if my idea of
changing screens is correct in urwid.

Sorry Ian. I am learning python, urwid and KirbyBase, and I come from Java.
Your help will be very apreciatted for me.
Thanks a lot.

Antonio

2005/11/7, Ian Ward <ian <at> excess.org>:
> antonio araujo wrote:
>
> >Hello.
> >Thanks for your interesting work.
> >I am learning on it, and discover a little problem:
> >the combination "shift + tab" returns 'meta [z' whith the spanish keyboard.
> >
> >
> I get the same with my english keyboard in xterm.  Add the following
> line to the list called "_escape_sequences" in curses_display.py:
(Continue reading)

Ian Ward | 9 Nov 2005 21:57
Favicon
Gravatar

Tab focus changing, Radio buttons, Illuminating buttons

antonio araujo wrote:

>Hello Ian. Thanks for your answer, but after change the line, it dont
>works for me.
>I will send you the pre-pre-alpha version of my RecordEditor.
>I have many problems with urwid, and I need some help.
>-I need to navigate the fields with the tab key by default.
>  
>
If you want tab to move through items in a listbox then you need to call
get_focus and set_focus on the listbox when get_input includes 'tab' or
'shift tab'.

In your code that could be done in the same place you are handling 'f1',
'f2' etc.  You are using a simple list as the body of your listbox, so
the positions are just integer values.  You could move to the next field
with code like this:

old_widget, old_position = self.listbox.get_focus()
self.listbox.set_focus( (old_position +1) % len(self.listbox_contents) )

in the above code listbox_contents is the list that you pass into the
ListBox class. It is a good idea to assign this list to a variable so
that you can edit it later, with code like this when you construct the
list box:

self.listbox_contents = CONTENTS
self.listbox = urwid.ListBox(self.listbox_contents)

>-I need a simple component to do a RadioButton, something like:
(Continue reading)

antonio araujo | 15 Nov 2005 06:32
Picon

Tab focus changing, Radio buttons, Illuminating buttons

Hello Ian.
Thanks for your response.
I have another problem with urwid:
Making in a Edit set_edit_text('') the edit_text is None, and you
have some asserts like:
 assert pos >= 0 and pos <= len(self.edit_text)

and len(None) is an error.

There is any correct form to clear a field or is this a bug?

Thanks.
Antonio.

antonio araujo | 15 Nov 2005 06:54
Picon

Tab focus changing, Radio buttons, Illuminating buttons

Hey, sorry, sorry. The problem is mine.
Sorry for my stupid "" = None.
Learning python.
I will catch my bug.
Antonio

2005/11/15, antonio araujo <antoniovazquezaraujo <at> gmail.com>:
> Hello Ian.
> Thanks for your response.
> I have another problem with urwid:
> Making in a Edit set_edit_text('') the edit_text is None, and you
> have some asserts like:
>  assert pos >= 0 and pos <= len(self.edit_text)
>
> and len(None) is an error.
>
> There is any correct form to clear a field or is this a bug?
>
> Thanks.
> Antonio.
>

antonio araujo | 15 Nov 2005 18:11
Picon

Tab focus changing, Radio buttons, Illuminating buttons

Hello.
Here Antonio.
I send you a working version of RecordEditor, my urwid-based database editor.
Now, I need some help to achieve more funcionality, and to resolve
various problems with the interface.
I think urwid is very nice, but very dificult and very "low level" api.
My questions:
- Can I do a floating dialog to alert the user with messages?
- There is any method to include a non editable component in a list of
editable components and achieve the focus for the rest?
- Can I do a select of the field data when the field gain the focus?

Ok for now.
Thank you very mutch for urwid.
Antonio.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: RecordEditor.tar.gz
Type: application/x-gzip
Size: 62845 bytes
Desc: not available
Url : http://lists.excess.org/pipermail/urwid/attachments/20051115/8a77b092/RecordEditor.tar-0001.bin

Ian Ward | 15 Nov 2005 18:36
Favicon
Gravatar

Tab focus changing, Radio buttons, Illuminating buttons

antonio araujo wrote:

>Hello.
>Here Antonio.
>I send you a working version of RecordEditor, my urwid-based database editor.
>Now, I need some help to achieve more funcionality, and to resolve
>various problems with the interface.
>I think urwid is very nice, but very dificult and very "low level" api.
>  
>
You're right, Urwid is very low level compared to most user interface 
libraries. I have tried to focus on carefully designing the low level 
elements so that almost any console interface can be built on top of it.

One person has requested that I make the dialog.py example program part 
of the library itself, and I will look at doing something like that, so 
that everyone won't have to write their own version of the same "message 
box" function.

Also, I might make 'tab' and 'shift tab' move between widgets by 
default, as this would be unsurprising to most users.

>My questions:
>- Can I do a floating dialog to alert the user with messages?
>  
>
Yes, Urwid 0.8.9 has an Overlay class that you can use to create a 
dialog that floats above other screen content.  I wrote the dialog.py 
example before the Overlay class, so it doesn't use it, but you can see 
which widgets dialog.py uses to build a message box, then use Overlay to 
(Continue reading)

antonio araujo | 17 Nov 2005 08:27
Picon

Tab focus changing, Radio buttons, Illuminating buttons

Hello Ian.
My RecordEditor change his name.
Now is called Deckard, and is a new open source project at
http://deckard.sourceforge.net
Take a look.
Thanks.
Antonio.


Gmane