× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.


  • Subject: Bug with IC in 0.15.6
  • From: Frank Richter <frichter@xxxxxxxx>
  • Date: Thu, 13 Jan 2000 11:16:47 +0100
  • Mail-Followup-To: LINUX5250@midrange.com

Hallo,

I found a bug, related to the changed handling of IC. You hit it by
WRKSPLF, display (option 5) one item (but not the first one). If you
return, the cursor should be set to the same position. But instead it
moves to the first entry field.

I changed session.c:

    /* If we've gotten an MC or IC order, set the cursor to that
     * position.
     * Otherwise set the cursor to the first non-bypass field, if there
     * is
     * one.  If not, set the cursor position to 0,0. */
+   if (tn5250_display_pending_insert (This->display))
+        tn5250_display_set_cursor_home(This->display);
+   else {
      if (end_y != 0xff && end_x != 0xff)
      .
      .
      .
+   }

That works for me, so far. But I don't know, if that breaks anything
else.

I also changed cursesterm.c in function curses_terminal_update_indicators
to show the cursor position in the indicators line:

    if ((inds & TN5250_DISPLAY_IND_INSERT) != 0) {
       memcpy(ind_buf + 30, "IM", 2);
    }
+   sprintf(ind_buf+72,"%03.3d/%03.3d",tn5250_display_cursor_x(display)+1,
+         tn5250_display_cursor_y(display)+1);
    attrset( (attr_t)COLOR_PAIR(COLOR_WHITE) );

and in function curses_terminal_update:

       This->data->last_width = tn5250_display_width(display);
       This->data->last_height = tn5250_display_height(display);
-      curses_terminal_update_indicators(This, display);
    }
+   curses_terminal_update_indicators(This, display);
    attrset(A_NORMAL);

Then I found another glitch, which is related to the updates of the
xt5250 script. Bescause xterm is started with the -name xt5250 option it
also reports itself as "xt5250" and the code to test, whether we're running
in an xterm should be adopted:

    /* Determine if we're talking to an xterm ;) */
    printf ("\x5");
    fflush (stdout);

    tv.tv_usec = 100;
    tv.tv_sec = 0;
    select (0, NULL, NULL, NULL, &tv);

-  while ((i < 5) && (c = getch ()) != -1) {
+  while ((i < 6) && (c = getch ()) != -1) {
       buf[i++] = (char)c;
    }
    buf[i] = '\0';
    if (c != -1) {
       while (getch () != -1)
          ;
    }
-  This->data->is_xterm = !strcmp (buf, "xterm");
+  This->data->is_xterm = !strcmp (buf, "xt5250");

I'm not shure, if this is also related to the version of xterm, I use
Debian 2.1 with xterm from XFree86 3.3.2.3


--
Esda Feinstrumpffabrik GmbH
Abt. EDV, Frank Richter               frichter@esda.com
Hauptstr. 76, D-09392 Auerbach        IBMMAIL(DEMDK9DK)

+---
| This is the LINUX5250 Mailing List!
| To submit a new message, send your mail to LINUX5250@midrange.com.
| To subscribe to this list send email to LINUX5250-SUB@midrange.com.
| To unsubscribe from this list send email to LINUX5250-UNSUB@midrange.com.
| Questions should be directed to the list owner/operator: david@midrange.com
+---


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.