Project

General

Profile

Bug #2166

Alert box layout mismatch

Added by Eugenie Lyzenko over 10 years ago. Updated over 10 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
08/19/2013
Due date:
% Done:

0%

billable:
No
vendor_id:
GCD
case_num:
version:

normal-4gl-linux.jpg - Layout issue 4GL Linux (195 KB) Eugenie Lyzenko, 08/19/2013 12:52 PM

normal-4gl-windows.jpg - Layout issue 4GL Windows (118 KB) Eugenie Lyzenko, 08/19/2013 12:52 PM

normal-p2j-linux.jpg - Layout issue P2J Linux (194 KB) Eugenie Lyzenko, 08/19/2013 12:52 PM

normal-p2j-windows.jpg - Layout issue P2J Windows (126 KB) Eugenie Lyzenko, 08/19/2013 12:52 PM

History

#1 Updated by Eugenie Lyzenko over 10 years ago

Consider the following code:

...
message skip
   "This is the normal attribute text. Depending on the" skip(0)
   "current console OS color settings it can be colored" skip(0)
   "or not. The buttons below should have one letter   " skip(0)
   "underligned and button <No> should have reverse    " skip(0)
   "color attribute meaning the current selection. Hit " skip(0)
   "arrow keys to change the current selection, ENTER  " skip(0)
   "to select curent button.                           " skip(0)
    view-as alert-box warning buttons yes-no-cancel update res as log.
...

This converts OK and has the correct color attribute in result. Compare normal-4gl-linux.jpg and normal-4gl-windows.jpg with normal-p2j-linux.jpg and normal-p2j-windows.jpg. However here we see the second issue: in P2J text start coordinate for all lines except last on is different(one more extra " " char inserted before line start). And the alert--box width become different. The converted code is:

...
            messageBox(new Object[]
            {
               new SkipEntity(),
               "This is the normal attribute text. Depending on the",
               new SkipEntity(0),
               "current console OS color settings it can be colored",
               new SkipEntity(0),
               "or not. The buttons below should have one letter   ",
               new SkipEntity(0),
               "underligned and button <No> should have reverse    ",
               new SkipEntity(0),
               "color attribute meaning the current selection. Hit ",
               new SkipEntity(0),
               "arrow keys to change the current selection, ENTER  ",
               new SkipEntity(0),
               "to select curent button.                           ",
               new SkipEntity(0)
            }, false, new AccessorWrapper(res), ALERT_WARNING, BTN_YES_NO_CANCEL, null);
...

It is happening in some rare conditions so in our tests we just can not screens to verify this mismatch. Note this behavior is not depending on conversion OS.

4GL Original for Linux and Windows:

           ┌─────────────────────── Warning ───────────────────────┐
           │                                                       │
           │ This is the normal attribute text. Depending on the   │
           │ current console OS color settings it can be colored   │
           │ or not. The buttons below should have one letter      │
           │ underligned and button <No> should have reverse       │
           │ color attribute meaning the current selection. Hit    │
           │ arrow keys to change the current selection, ENTER     │
           │ to select curent button.                              │
           │ ───────────────────────────────────────────────────── │
           │                  <Yes> <No> <Cancel>                  │
           └───────────────────────────────────────────────────────┘

P2J Linux and Windows:

          ┌─────────────────────── Warning ────────────────────────┐
          │                                                        │
          │  This is the normal attribute text. Depending on the   │
          │  current console OS color settings it can be colored   │
          │  or not. The buttons below should have one letter      │
          │  underligned and button <No> should have reverse       │
          │  color attribute meaning the current selection. Hit    │
          │  arrow keys to change the current selection, ENTER     │
          │ to select curent button.                               │
          │ ────────────────────────────────────────────────────── │
          │                  <Yes> <No> <Cancel>                   │
          └────────────────────────────────────────────────────────┘

The real screenshots are also appended here.

#2 Updated by Eugenie Lyzenko over 10 years ago

  • Description updated (diff)

Also available in: Atom PDF