From: Paraic O'C. <poc...@fe...> - 2017-01-03 13:37:28
|
Hi I have a question around the widget for buildlist in pythondialog. I have it running and using space to select but the way in which it selects is strange. I assumed that it would select the items in the left side one by one and place them in the same order on the right side but that is not the case. It actually does this if I use just the space bar, but if I use the arrow key to select a different item that the one highlighted it inserts it out of order but I can't quite make out what the order is. I thought it might be alphabetical but it doesn't seem to be. Is there a way I can guarantee that the order selected will be the same when moved to the right side? My code is to select a bunch of currencies for a rateboard which is read into a list from a txt file. The code works fine and I get the order it was selected in as expected, its just the way the buildlist widget works which is confusing. Any help appreciated. Pythondialog 3.5, dialog 1.3-20160828 on Debian code, tag = d.buildlist(text="Please Select correct order for your Buy Rateboard. SPACE moves an item from one column to the other.", items=[(lines[9], "EUR", 1), (lines[22], "USD", 1), (lines[1], "AUD", 0), (lines[4], "CAD", 0), (lines[2], "BGN", 0), (lines[21], "TRY", 0), (lines[8], "DKK", 0), (lines[18], "SEK", 0), (lines[0], "AED", 0), (lines[23], "ZAR", 0), (lines[5], "CHF", 0), (lines[17], "PLN", 0), (lines[19], "SGD", 0), (lines[16], "NZD",0)],visit_items=True) [cid:image001.png@01D265C4.0F54D960] This email, including any attachments, is confidential. If you are not the named recipient, please contact the sender and delete all copies of this email from your computer system(s). |