lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

lynx-dev Command line support for numbered form inputs


From: John Hawkinson
Subject: lynx-dev Command line support for numbered form inputs
Date: Fri, 30 Jul 1999 03:11:16 -0400 (EDT)

[ I am not on lynx-dev, so please cc me on any relevent correspondance ]

I'm quite happy that someone implemented
  keypad_mode = LINKS_AND_FORM_FIELDS_ARE_NUMBERED

I really do not understand why it was not made the default with
-number_links however -- I cannot imagine reasons why interactively you
would want to use -number_links, but would not want to also number form
input fields.

It is all well and good for it to be a settable option with 'o', however
most of the people who might look for such a thing are going to look
for it on the command line, since there is already precedent for it
in -number_links.

I think the best course would be to change the behavior of -number_links
to set LINKS_AND_FORM_FIELDS_ARE_NUMBERED.

But I am assuming there is some reason why that was not done.
So the following patch provides support for -number_links_forms,
a parallel option to -number_links.

This is against lynx 2.8.2rel.1, tested under Solaris 2.6.

If this patch is inadequate, please let me know and I will try
to repair it.

address@hidden
  John Hawkinson

*** 1.1 1999/07/30 06:21:55
--- CHANGES     1999/07/30 07:07:16
***************
*** 1,6 ****
--- 1,9 ----
  Changes since Lynx 2.8 release
  
===============================================================================
  
+ * Add the -number_links_forms command line option (John Hawkinson
+   <address@hidden>).
+ 
  1999-06-01 (2.8.2rel.1)
  -----------------------
  1999-06-01 (2.8.2pre.11)
*** 1.1 1999/07/30 06:56:03
--- src/LYMain.c        1999/07/30 07:05:35
***************
*** 409,414 ****
--- 409,415 ----
  PRIVATE char *terminal = NULL;
  PRIVATE char *pgm;
  PRIVATE BOOLEAN number_links = FALSE;
+ PRIVATE BOOLEAN number_links_forms = FALSE;
  PRIVATE BOOLEAN LYPrependBase = FALSE;
  PRIVATE HTList *LYStdinArgs = NULL;
  
***************
*** 1548,1553 ****
--- 1549,1556 ----
      if (vi_keys)
        set_vi_keys();
  
+     if (number_links_forms && keypad_mode == NUMBERS_AS_ARROWS)
+         keypad_mode = LINKS_AND_FORM_FIELDS_ARE_NUMBERED;
      if (number_links && keypad_mode == NUMBERS_AS_ARROWS)
        keypad_mode = LINKS_ARE_NUMBERED;
      if (keypad_mode == NUMBERS_AS_ARROWS)
***************
*** 1782,1792 ****
         *  Finish setting up and start a
         *  NON-INTERACTIVE session. - FM
         */
!       if (crawl && !number_links) {
            keypad_mode = NUMBERS_AS_ARROWS;
        } else if (!nolist) {
            if (keypad_mode == NUMBERS_AS_ARROWS) {
!               keypad_mode = LINKS_ARE_NUMBERED;
            }
        }
        if (x_display != NULL && *x_display != '\0') {
--- 1785,1798 ----
         *  Finish setting up and start a
         *  NON-INTERACTIVE session. - FM
         */
!       if (crawl && !number_links && !number_links_forms) {
            keypad_mode = NUMBERS_AS_ARROWS;
        } else if (!nolist) {
            if (keypad_mode == NUMBERS_AS_ARROWS) {
!               if (number_links_forms)
!                    keypad_mode = LINKS_AND_FORM_FIELDS_ARE_NUMBERED;
!               else
!                  keypad_mode = LINKS_ARE_NUMBERED;
            }
        }
        if (x_display != NULL && *x_display != '\0') {
***************
*** 2891,2896 ****
--- 2897,2906 ----
     PARSE_SET(
        "number_links", SET_ARG,                &number_links,
        "force numbering of links"
+    ),
+    PARSE_SET(
+       "number_links_forms",   SET_ARG,                &number_links_forms,
+       "\nforce numbering of links as well as form input fields"
     ),
  #ifdef DISP_PARTIAL
     PARSE_SET(

reply via email to

[Prev in Thread] Current Thread [Next in Thread]