Bug #10857
Logical FILL-IN initial state: Incorrect handling of unmatched keys
100%
Related issues
History
#1 Updated by Vladimir Tsichevski 8 months ago
Run this simplest possible example in GUI mode:
DEFINE VARIABLE l AS LOGICAL NO-UNDO. DEFINE FRAME f l NO-LABEL. ENABLE ALL WITH FRAME f. WAIT-FOR WINDOW-CLOSE OF FRAME f.
In this example, a frame with a single FILL-IN of LOGICAL type with the default (yes/no) format is displayed and enabled.
As already mentioned in #10856, Issue 1: the initial caret position in FWD is 1 instead of 0.
In this initial state, if the user enters any printable key other than the initial matches (y or n):
In OE: Nothing happens.
In FWD: The FILL-IN displayed value is reset to unknown (?).
#2 Updated by Vladimir Tsichevski 8 months ago
- Related to Bug #10856: Logical FILL-IN: Caret position issues added
#5 Updated by Delia Mitric 7 months ago
If we click on the FILL-IN or use LEFT, RIGHT in the FILL-IN to move the cursor and after that we introduce any printable key different from "y" and "n", the displayed value in FWD is the same like in OE (no value displayed).? is displayed in FWD just if we introduce directly a printable key without changing the cursor position.
#6 Updated by Vladimir Tsichevski 7 months ago
Delia Mitric wrote:
If we click on the FILL-IN or use
LEFT,RIGHTin the FILL-IN to move the cursor and after that we introduce any printable key different from "y" and "n", the displayed value in FWD is the same like in OE (no value displayed).?is displayed in FWD just if we introduce directly a printable key without changing the cursor position.
Yes. I think, the non-zero initial caret position is the key and should be fixed first.
#8 Updated by Delia Mitric 7 months ago
Found why the caret is initially set to 1:FillInGuiImpl.getInitialCursorPos() returns the position of the cursor (which is to the right of the text). We expect FILL-IN SCREEN-VALUE to be "", but in FWD it is "?". The length of this text affects the cursor position.
#10 Updated by Delia Mitric 7 months ago
- % Done changed from 10 to 100
- Status changed from WIP to Review
I've committed a solution to 10857a, rev. 16321.
The caret position is fixed (initially is 0) and if we introduce a printable key different from "y" or "n", nothing happens which is correct.
Vladimir/Hynek, can you review, please?
Thank you!
#13 Updated by Razvan-Nicolae Chichirau 7 months ago
ChUI regression tests passed with 10857a.
#18 Updated by Radu Apetrii 6 months ago
- Status changed from Internal Test to Merge Pending
Seems fair. 10857a can be merged right now.
#20 Updated by Vladimir Tsichevski 6 months ago
- Related to Bug #11078: Unintended VALUE-CHANGED Event Triggering in DECIMAL, INTEGER, and LOGICAL FILL-IN Widgets added