View previous topic :: View next topic |
Author |
Message |
Ralf
Joined: 30 Aug 2007 Posts: 50 Location: munich
|
Posted: Mon Mar 15, 2021 7:56 am Post subject: width of list box |
|
|
With the latest compiler version (8.70) I have the following problem with %`ls list boxes with drop down combo box:
If at least one of the entries in the character-array exceeds the predefined width of the listbox, the listbox is automatically extended and hides controls which are placed on the right side of the listbox or extends over the rim of the dialog box.
In former versions the character strings in the list are simply cutted off, which was ok for my purposes.
Is there a way to force the 'old' behaviour?
The best solution would be, if there is a way to realize a similar behaviour as in other programs, where the listboxes are resizable as long as the drop down box is closed. |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7933 Location: Salford, UK
|
Posted: Mon Mar 15, 2021 8:56 am Post subject: |
|
|
Ralf
It is possible that this is an issue that has been fixed so I will send you a link to a new set of DLLs via a personal message.
If not then please supply a short sample program that illustrates how %`ls is used. |
|
Back to top |
|
|
Ralf
Joined: 30 Aug 2007 Posts: 50 Location: munich
|
Posted: Mon Mar 15, 2021 10:53 am Post subject: |
|
|
Paul,
I still get the same results.
But I am not sure, if I updated the compiler correctly. I copied the new dlls into my FTN95 folder. Is it correct, that the prompted compiler version is still v8.70.0?
here is a simple program, that shows the problem:
Code: |
Program test_ls
integer :: winio@, iw, i, n_items, isel
character(len=20),dimension(10) :: item_list
do i=1,10
write(item_list(i),'(a,i5)')'Entry',i
enddo
write(item_list(5),'(a,i5)')'ABCDEFGHIJKLM',i
n_items = 10
isel = 1
iw = winio@ ('%`10.3ls[no_border] %bt[Close]&',item_list, n_items, isel)
iw = winio@ ('%nl%10rs',item_list(1))
stop
end
|
If I delete the line with extending the length of the 5th array entry, everything works fine. |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7933 Location: Salford, UK
|
Posted: Mon Mar 15, 2021 3:31 pm Post subject: |
|
|
Ralf
There is a new feature for %`ls that has been added to avoid a situation where the dropdown chevron on the right overwrites the text in the box.
I don't think that we can backtrack on this so I have added a new option for you for %`ls that restores the former behaviour. It is %`ls[fixed_width].
I will send you a personal message with a link for a new set of DLLs.
As before, this does not affect the version number for FTN95. |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7933 Location: Salford, UK
|
Posted: Tue Mar 16, 2021 9:26 am Post subject: |
|
|
Ralf
I realised this morning that there is another issue that is revealed by your sample program. The close button should appear to the right of the combobox and not under it.
This will not affect you if you want to keep the width of the combobox the same as before. You will still need to use the new option to fix it.
I have now fixed this secondary issue. If you need the fix then please let me know and I will send you a link to a new set of DLLs. |
|
Back to top |
|
|
Ralf
Joined: 30 Aug 2007 Posts: 50 Location: munich
|
Posted: Thu Mar 18, 2021 12:06 pm Post subject: |
|
|
Paul,
thanks for the bugfix, this solves the main issue with the comboboxin my application. Nevertheless I would like to see, if the fix of the second issue improves the usage of the combobox.
Do you think that it would be possible to add the resize-feature also for the drop-down feature (%`ls) if the resize is suppressed as long as the drop-down box is open (like the behaviour of the list of recent files in the standard file open dialog)?
Ralf |
|
Back to top |
|
|
PaulLaidler Site Admin
Joined: 21 Feb 2005 Posts: 7933 Location: Salford, UK
|
Posted: Thu Mar 18, 2021 12:26 pm Post subject: |
|
|
Ralf
I will send you a link to a new set of DLLs via a personal message.
The width of the dropdown part of a combobox is always the same as the initial width. |
|
Back to top |
|
|
|