Print this page
12212 typos in some section 3tecla man pages

Split Close
Expand all
Collapse all
          --- old/usr/src/man/man3tecla/gl_get_line.3tecla.man.txt
          +++ new/usr/src/man/man3tecla/gl_get_line.3tecla.man.txt
↓ open down ↓ 299 lines elided ↑ open up ↑
 300  300  
 301  301  
 302  302         GLR_TIMEOUT
 303  303                        The inactivity timer expired while gl_get_line() was
 304  304                        waiting for input, and the timeout callback function
 305  305                        returned GLTO_ABORT. See gl_inactivity_timeout() for
 306  306                        information about timeouts.
 307  307  
 308  308  
 309  309         GLR_FDABORT
 310      -                      An application I/O callback returned GLFD_ABORT. Ssee
      310 +                      An application I/O callback returned GLFD_ABORT. See
 311  311                        gl_watch_fd().
 312  312  
 313  313  
 314  314         GLR_EOF
 315  315                        End of file reached. This can happen when input is
 316  316                        coming from a file or a pipe, instead of the terminal.
 317  317                        It also occurs if the user invokes the list-or-eof or
 318  318                        del-char-or-list-or-eof actions at the start of a new
 319  319                        line.
 320  320  
↓ open down ↓ 149 lines elided ↑ open up ↑
 470  470  
 471  471  
 472  472  
 473  473         The app_string argument causes the calling application to start in
 474  474         vi(1) edit-mode, instead of the default emacs mode, and turns off the
 475  475         use of the terminal bell by the library. It then attempts to read
 476  476         system-wide configuration commands from an optional file called
 477  477         /usr/share/myapp/teclarc, then finally reads user-specific
 478  478         configuration commands from an optional .teclarc file in the user's
 479  479         home directory.  Note that the arguments are listed in ascending order
 480      -       of priority, with the contents of app_string being potentially over
 481      -       riden by commands in app_file, and commands in app_file potentially
 482      -       being overridden by commands in user_file.
      480 +       of priority, with the contents of app_string being potentially
      481 +       overridden by commands in app_file, and commands in app_file
      482 +       potentially being overridden by commands in user_file.
 483  483  
 484  484  
 485  485         You can call this function as many times as needed, the results being
 486  486         cumulative, but note that copies of any file names specified with the
 487  487         app_file and user_file arguments are recorded internally for subsequent
 488  488         use by the read-init-files key-binding function, so if you plan to call
 489  489         this function multiple times, be sure that the last call specifies the
 490  490         filenames that you want re-read when the user requests that the
 491  491         configuration files be re-read.
 492  492  
↓ open down ↓ 44 lines elided ↑ open up ↑
 537  537         manual page.
 538  538  
 539  539  
 540  540         The callback function is responsible for looking backwards in the input
 541  541         line from the point at which the user pressed TAB, to find the start of
 542  542         the word being completed. It then must lookup possible completions of
 543  543         this word, and record them one by one in the WordCompletion object that
 544  544         is passed to it as an argument, by calling the cpl_add_completion()
 545  545         function. If the callback function wants to provide filename completion
 546  546         in addition to its own specific completions, it has the option of
 547      -       itself calling the builtin filename completion callback. This also is
 548      -       documented on the cpl_complete_word(3TECLA) manual page.
      547 +       itself calling the builtin filename completion callback. This is also
      548 +       documented in the cpl_complete_word(3TECLA) manual page.
 549  549  
 550  550  
 551  551         If you would like gl_get_line() to return the current input line when a
 552      -       successful completion is been made, you can arrange this when you call
      552 +       successful completion has been made, you can arrange this when you call
 553  553         cpl_add_completion() by making the last character of the continuation
 554  554         suffix a newline character. The input line will be updated to display
 555      -       the completion, together with any contiuation suffix up to the newline
      555 +       the completion, together with any continuation suffix up to the newline
 556  556         character, and gl_get_line() will return this input line.
 557  557  
 558  558  
 559  559         If your callback function needs to write something to the terminal, it
 560  560         must call gl_normal_io() before doing so. This will start a new line
 561  561         after the input line that is currently being edited, reinstate normal
 562  562         terminal I/O, and notify gl_get_line() that the input line will need to
 563  563         be redrawn when the callback returns.
 564  564  
 565  565     Adding Completion Actions
↓ open down ↓ 16 lines elided ↑ open up ↑
 582  582         value of 0, and the latter by specifying a value of 1.  The name
 583  583         argument specifies the name by which configuration files and future
 584  584         invocations of this function should refer to the action. This must
 585  585         either be the name of an existing completion action to be changed, or
 586  586         be a new unused name for a new action. Finally, the keyseq argument
 587  587         specifies the default key sequence to bind the action to. If this is
 588  588         NULL, no new key sequence will be bound to the action.
 589  589  
 590  590  
 591  591         Beware that in order for the user to be able to change the key sequence
 592      -       that is bound to actions that are installed in this manner, you
 593      -       shouldcall gl_completion_action() to install a given action for the
 594      -       first time between calling new_GetLine() and the first call to
 595      -       gl_get_line().  Otherwise, when the user's configuration file is read
 596      -       on the first call to gl_get_line(), the name of the your additional
 597      -       action will not be known, and any reference to it in the configuration
 598      -       file will generate an error.
      592 +       that is bound to actions that are installed in this manner, you should
      593 +       call gl_completion_action() to install a given action for the first
      594 +       time between calling new_GetLine() and the first call to gl_get_line().
      595 +       Otherwise, when the user's configuration file is read on the first call
      596 +       to gl_get_line(), the name of the your additional action will not be
      597 +       known, and any reference to it in the configuration file will generate
      598 +       an error.
 599  599  
 600  600  
 601  601         As discussed for gl_customize_completion(), if your callback function
 602  602         needs to write anything to the terminal, it must call gl_normal_io()
 603  603         before doing so.
 604  604  
 605  605     Defining Custom Actions
 606  606         Although the built-in key-binding actions are sufficient for the needs
 607  607         of most applications, occasionally a specialized application may need
 608  608         to define one or more custom actions, bound to application-specific key
↓ open down ↓ 124 lines elided ↑ open up ↑
 733  733         specify "#" here. Whatever you choose for the comment character, you
 734  734         must specify the same prefix to gl_load_history() that you used when
 735  735         you called gl_save_history() to write the history file.
 736  736  
 737  737  
 738  738         The max_lines argument must be either -1 to specify that all lines in
 739  739         the history list be saved, or a positive number specifying a ceiling on
 740  740         how many of the most recent lines should be saved.
 741  741  
 742  742  
 743      -       Both fuctions return non-zero on error, after writing an error message
      743 +       Both functions return non-zero on error, after writing an error message
 744  744         to stderr. Note that gl_load_history() does not consider the non-
 745  745         existence of a file to be an error.
 746  746  
 747  747     Multiple History Lists
 748  748         If your application uses a single GetLine object for entering many
 749  749         different types of input lines, you might want gl_get_line() to
 750  750         distinguish the different types of lines in the history list, and only
 751  751         recall lines that match the current type of line. To support this
 752  752         requirement, gl_get_line() marks lines being recorded in the history
 753  753         list with an integer identifier chosen by the application. Initially
↓ open down ↓ 675 lines elided ↑ open up ↑
1429 1429         duplicated when nothing had been written to the terminal. Such a signal
1430 1430         handler, when it does write to the terminal, should be sure to start a
1431 1431         new line at the start of its first write, by writing a new line before
1432 1432         returning. If the signal arrives while the user is entering a line that
1433 1433         only occupies a signal terminal line, or if the cursor is on the last
1434 1434         terminal line of a longer input line, this will have the same effect as
1435 1435         GL_SUSPEND_INPUT. Otherwise it will start writing on a line that
1436 1436         already contains part of the displayed input line. This does not do any
1437 1437         harm, but it looks a bit ugly, which is why the GL_SUSPEND_INPUT
1438 1438         combination is better if you know that you are always going to be
1439      -       writting to the terminal.
     1439 +       writing to the terminal.
1440 1440  
1441 1441  
1442 1442         The after argument, which determines what gl_get_line() does after the
1443 1443         application's signal handler returns (if  it returns), can take any one
1444 1444         of the following values:
1445 1445  
1446 1446         GLS_RETURN
1447 1447                         Return the completed input line, just as though the
1448 1448                         user had pressed the return key.
1449 1449  
↓ open down ↓ 452 lines elided ↑ open up ↑
1902 1902         +--------------------+-----------------+
1903 1903         |MT-Level            | MT-Safe         |
1904 1904         +--------------------+-----------------+
1905 1905  
1906 1906  SEE ALSO
1907 1907         cpl_complete_word(3TECLA), ef_expand_file(3TECLA), gl_io_mode(3TECLA),
1908 1908         libtecla(3LIB), pca_lookup_file(3TECLA), attributes(5), tecla(5)
1909 1909  
1910 1910  
1911 1911  
1912      -                                 April 9, 2016             GL_GET_LINE(3TECLA)
     1912 +                               January 18, 2020            GL_GET_LINE(3TECLA)
    
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX