home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / misc / volume20 / notation / part02 / notation.doc < prev    next >
Encoding:
Text File  |  1991-06-18  |  14.8 KB  |  529 lines

  1.  
  2.  
  3.  
  4. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  5.  
  6.  
  7.  
  8. NAME
  9.      notation - transform chess notation
  10.  
  11.  
  12. SYNOPSYS
  13.      notation [input file] [-o output file] [-options...]
  14.  
  15.  
  16. DESCRIPTION
  17.      This program reads chess games,  either  full  algebraic  or
  18.      shortened (ie Nf1-g3 or Ng3) and is able to ouptut the board
  19.      after any move, in either ascii , postscript, nroff,  latex,
  20.      xboard  or  gnuan  save  format. This program is also multi-
  21.      lingual:  it  handles  english,  french,  spanish,   german,
  22.      italian, dutch, romanian etc... symbols. So nearly all euro-
  23.      peans languages are understood (except  greek  and  russian,
  24.      but  I  can't  handle  greek or cyrillic on ascii computers,
  25.      eh).
  26.  
  27.  
  28. OPTIONS
  29.      Command line options:
  30.  
  31.  
  32.      -a
  33.              algebraic move notation output
  34.  
  35.  
  36.      -s
  37.              shortened move notation output
  38.  
  39.  
  40.      -f <language>
  41.              specifies  the  chess  symbol  input  language.  The
  42.              language  can  be  any  of french, english, italian,
  43.              spanish, german, dutch,  czech,  hungarian,  polish,
  44.              romanian, FIDE.
  45.  
  46.  
  47.      -t <language>
  48.              specifies the chess  symbol  output  language.  Same
  49.              options as input language.
  50.  
  51.  
  52.      <inputfile>
  53.              specifies the  input  file.  If  none,  keyboard  is
  54.              assumed.
  55.  
  56.  
  57.      -o <outputfile>
  58.              specifies  the  output  file.  If  none,  screen  is
  59.              assumed.
  60.  
  61.  
  62.  
  63. Sun Release 4.1   Last change: 10 December 1990                 1
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  71.  
  72.  
  73.  
  74.      -c <number>[,<number]
  75.              specifies the number  of  the  moves  at  which   to
  76.              display  the  board.  If none, board is displayed at
  77.              end of file. Several numbers may be specified, as  a
  78.              comma-separated list.
  79.  
  80.  
  81.      -e <number>
  82.              display the board at the move number and then stops
  83.  
  84.  
  85.      -b
  86.              display only the board, not the moves
  87.  
  88.  
  89.      -d <drivername>
  90.              specifies the output driver. It can be  any  of  the
  91.              following:  ascii,  postscript,  tex,  roff,  xchess
  92.              (xchess or xboard save  format),  gnu  (gnuan  input
  93.              format).
  94.  
  95.  
  96.      -i
  97.              suppress headers/footers printing.  This  is  useful
  98.              with  tex  or ps drivers, if you want to include the
  99.              output in a larger file.
  100.  
  101.  
  102.      -v
  103.              displays version number and exits
  104.  
  105.  
  106.      -h
  107.              displays help screen
  108.  
  109.  
  110. INPUT LANGUAGE
  111.            The input language has four  types  of  input:  moves,
  112.      move numbers, comments and keywords. All these are separated
  113.      by blanks, TAB, CR, commas and semi-columns.
  114.  
  115.  
  116.      move format:
  117.               The moves are accepted in  algebraic  or  shortened
  118.              algebraic  notation.   That means that the following
  119.              are equivalent and accepted  Nf1-g3  N-f1xg3,  Nxg3,
  120.              Ng3,  Nfg3.  The  ugly  english notation P-K4 is not
  121.              understood, neither by the program nor me.  The pro-
  122.              gram allows and parse variations.
  123.  
  124.              Nota: provided you  remove  the  three  first  line,
  125.              xchess save format is accepted.
  126.  
  127.  
  128.  
  129. Sun Release 4.1   Last change: 10 December 1990                 2
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  137.  
  138.  
  139.  
  140.               Also you can have move comments.  So  Kg4!!,  Ra5++
  141.              are  correct, as Kg4 !!, Ra5 ++.  Castling is recog-
  142.              nized with the following 0-0 O-O o-o 0-0-0 O-O-O  o-
  143.              o-o.   "En  passant" and promotion are now correctly
  144.              handled. For "en passant", you  just  indicate  them
  145.              move  and  it is correctly parsed ex: "d5-d7 e5xd6".
  146.              Promotion is indicated with the "=" sign followed by
  147.              the  new  piece name. So you just write "a7-a8=Q" or
  148.              "d8=K".
  149.  
  150.              For   example,   see   the   files    algebraic.txt,
  151.              shortened.txt and boudy.txt
  152.  
  153.  
  154.      move numbers:
  155.               move numbers are in the form 23. or  36.  The  full
  156.              point  is optional. Move numbers are checked against
  157.              internal move counter.
  158.  
  159.  
  160.      comments:
  161.                chess codified comments can be put in  the  input.
  162.              There  are two ways or doing so. The first one is to
  163.              use the usual chess notation !?, !, ,+, ++,  #,  ep,
  164.              etc  ...  However,  international magazine use other
  165.              no-ascii symbols : triangles, squares, infinity  and
  166.              so  on. You can have these symbols  on LaTeX output.
  167.              This is the second  way.  I  defined  three  letters
  168.              abbreviations  for  such  symbols  (look at the file
  169.              chesssymb.txt for an extensive  description).  These
  170.              abbreviations  are  following a $ sign. For instance
  171.              $wsb means "white slightly better".  This is,  IMHO,
  172.              a very interesting feature of the program.
  173.  
  174.  
  175.      text:    plain text, such as  explanations  etc...  must  be
  176.              enclosed  in  brackets  or  parenthesis [Here Karpov
  177.              made a very bright move ...] (this is  also  a  com-
  178.              ment).   Comments   are  not  parsed,  but  directly
  179.              inserted in the output, for  the  ascii  ,nroff  and
  180.              latex drivers. The closing characters (ie "]" or ")"
  181.              depending of the opening characters may be placed in
  182.              the  text,  provided it is escaped by a "\" ( so you
  183.              input "\]" or "\)" ).
  184.  
  185.  
  186.      variations:
  187.               You can have variations in  the  source.  Variation
  188.              are  in  enclosing  {  }  . You can have up to three
  189.              level of variation. It would  be  enough  for  human
  190.              players.  A  variation always follows the move. Here
  191.              is an exemple of variation : 25. Rb2 {  Ce4  de4  26
  192.  
  193.  
  194.  
  195. Sun Release 4.1   Last change: 10 December 1990                 3
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  203.  
  204.  
  205.  
  206.              Fc3 Fa3! 27. Ff6 Tb3 } Fa3!
  207.  
  208.  
  209.      keywords:
  210.               You can insert keywords in the input text  to  pre-
  211.              cisely  define  what you want: displaying the board,
  212.              configuring it... Keywords are detailled in the next
  213.              section.
  214.  
  215.  
  216. KEYWORDS
  217.      all keywords are prefixed with @
  218.  
  219.      @startplay
  220.               begins the play. Obligatory after a @configxxx key-
  221.              word.
  222.  
  223.      @clearboard
  224.              clears the board. Used prior to any @configxxx.
  225.  
  226.      @showboard
  227.              displays the board. Can be used anywhere
  228.  
  229.      @whitesmove
  230.              tells the program that is the white's turn of  play.
  231.              Useful after a @configxxx and @startplay
  232.  
  233.      @blacksmove
  234.              tells the program that it is black's turn
  235.  
  236.      @configwhite
  237.              initializes configuration of white side. Pieces  are
  238.              then  expected, in form of (optional for Pawn) name,
  239.              the position. Example @configwhite Ke3 Rg8 e4.
  240.  
  241.      @configblack
  242.              initializes configuration of black side. Pieces  are
  243.              then  expected, in form of (optional for Pawn) name,
  244.              the position. Example: @configblack Ka8 Nf6 e6.
  245.  
  246.              Note that black pieces are given in uppercase!
  247.  
  248.  
  249.      @default
  250.              resets the board to the default start configuration.
  251.  
  252.              @special all following text up to the  next  cariage
  253.              return is not processed, but instead directly print.
  254.              This allows to insert comments in  ascii  files,  or
  255.              tex commands when tex output is selected.
  256.  
  257.      @null   null keyword. Does nothing. Used for convenience  in
  258.  
  259.  
  260.  
  261. Sun Release 4.1   Last change: 10 December 1990                 4
  262.  
  263.  
  264.  
  265.  
  266.  
  267.  
  268. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  269.  
  270.  
  271.  
  272.              programming.
  273.  
  274.  
  275.              See the file keywords.txt for an example of keywords
  276.              use.
  277.  
  278.  
  279. NATIONAL LANGUAGES
  280.      Here are the symbols used in the  differents  languages.  ()
  281.      mean optional in the input.
  282.  
  283.  
  284.      english-name   King Queen     Rook Bishop    Knight    Pawn
  285.      english        K    Q    R    B    N    (P)
  286.      french         R    D    T    F    C    (P)
  287.      italian        R    D    T    A    C    (P)
  288.      spanish        R    D    T    A    C    (P)
  289.      german         K    D    T    L    S    (B)
  290.      dutch          K    D    T    L    P    (O)
  291.      czech          K    D    V    S    J    (P)
  292.      hungarian K    V    B    F    H    (G)
  293.      polish         K    H    W    G    S    (P)
  294.      romanian  R    D    T    N    C    (P)
  295.      FIDE      K    D    T    S    N    (P)
  296.  
  297.  
  298. DRIVERS
  299.      ascii    this is the default driver,  it  outputs  move  and
  300.              boards.
  301.  
  302.  
  303.      postscript
  304.                It generates a  file  using  the  font  file  Cheq
  305.              licensed  for  free  by  Adobe.  It  is only able to
  306.              display one board per run. Move are  not  displayed.
  307.              You  need  the  font  "Cheq",  freely distributed by
  308.              Adobe.  Send a  mail  to  "ps-file-server@adobe.com"
  309.              with the body "send Programs chessfont.ps".
  310.  
  311.  
  312.      tex       This is a latex  driver.  It  uses  the  TeX/LaTeX
  313.              chess    macros    designed    by   Piet   Tutalaers
  314.              "rcpt@urc.tue.nl".  The  complete  distribution   is
  315.              available  on sol.cs.ruu.nl (131.211.80.5) with path
  316.              TEX/chess.tar.Z. Refer to your local latex  guru  to
  317.              install it.
  318.  
  319.  
  320.      roff      This is a driver for nroff output.  It  is  crude,
  321.              but it works. Moves and boards are displayed.
  322.  
  323.  
  324.  
  325.  
  326.  
  327. Sun Release 4.1   Last change: 10 December 1990                 5
  328.  
  329.  
  330.  
  331.  
  332.  
  333.  
  334. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  335.  
  336.  
  337.  
  338.      xchess    This  driver  generates  compatible  xchess/xboard
  339.              save  files, thus allowing you to replay a game with
  340.              xchess.
  341.  
  342.  
  343.      gnu       This driver generates "bare" output, with only the
  344.              algebraic  move.   It  is suitable for any low-level
  345.              analyser, such as gnuan.
  346.  
  347.  
  348. EXAMPLES
  349.           Try the following commands:
  350.  
  351.      notation algebraic.txt
  352.              this will read the  Karpov-Kasparov  game  13  (Lyon
  353.              1990)  in  algebraic form, display move in shortened
  354.              algebraic and display board at end of game.
  355.  
  356.      notation algebraic.txt -s
  357.              this will do the same thing, as -a stands for  alge-
  358.              braic output.
  359.  
  360.      notation algebraic.txt -a
  361.              the game will now be output in full-length algebraic
  362.  
  363.      notation shortened.txt
  364.              there is no problem to read shortened algebraic.
  365.  
  366.      notation shortened -s -o result
  367.              the moves and board will be directed to file result
  368.  
  369.      notation shortened.txt -s -t french
  370.              output will use french notation
  371.  
  372.      notation a_dutch_file -f dutch -t spanish
  373.              game will be translated form dutch to spanish
  374.  
  375.      notation shortened -c 2
  376.              board after move 2 will  be  displayed,  along  with
  377.              moves and end-of-game board
  378.  
  379.      notation shortened.txt -e 2
  380.              board after move 2 will  be  displayed,  along  with
  381.              moves. The program will then stops
  382.  
  383.      notation shortened.txt -c 2,5,20
  384.              board after moves 2, 5 and  20  will  be  displayed,
  385.              along with moves and end-of-game board
  386.  
  387.      notation shortened.txt -c 2,5,20 -b
  388.              board after moves 2, 5 and  20  will  be  displayed,
  389.              with end-of-game board, but no moves.
  390.  
  391.  
  392.  
  393. Sun Release 4.1   Last change: 10 December 1990                 6
  394.  
  395.  
  396.  
  397.  
  398.  
  399.  
  400. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  401.  
  402.  
  403.  
  404.      notation shortened.txt -c 2,5,20 -d tex
  405.              the output will be formatted to use with latex.  You
  406.              can directly latex the output file.
  407.  
  408.      notation shortened.txt -c 2,5,20 -d gnu
  409.              you can now replay  the  game  by  using  xchess  -r
  410.              out.gnu.
  411.  
  412.      notation shortened.txt -e 5 -d postscript
  413.              Now issue cat lib/Cheq out.ps | lpr to display on  a
  414.              Laser  Printer  the  board  at  move 5. You can also
  415.              issue sh print-ps out-ps.  The postcript driver does
  416.              not support the -c option.
  417.  
  418.      notation boudy.txt -d tex -o boudy.tex
  419.              This is the all-star, all-singing  demonstration  of
  420.              the  notation  program.  Runs latex on boudy.tex and
  421.              print result.
  422.  
  423.  
  424. FILES
  425.      algebraic.txt shortened.txt keywords.txt boudy.txt
  426.              these are examples of input files
  427.  
  428.  
  429.      chesssymb.tex
  430.               this is the LaTeX file containing  the  definitions
  431.              of  the codified comment. You can include it in your
  432.              own LaTeX files: you will be able to use  the  chess
  433.              comments. The file is stand-alone. To iclude comment
  434.              in LaTeX, just type  \COM<three  letter  name>.  For
  435.              instance  \COMwsb  inserts  the  symbol  for "whites
  436.              stands lightly better".
  437.  
  438.  
  439.      chesssymb.txt
  440.              explanation of codified comments
  441.  
  442.  
  443.      convsymb.txt
  444.              used to prduce chesssymb.txt
  445.  
  446.  
  447.      ($LIBDIR/)HELPFILE
  448.              this is the on-line helpfile
  449.  
  450.  
  451.      ($LIBDIR/) Cheq Header.ps Footer.ps
  452.              these files are needed by the postscript driver
  453.  
  454.  
  455.      ($LIBDIR/)Header.tex
  456.  
  457.  
  458.  
  459. Sun Release 4.1   Last change: 10 December 1990                 7
  460.  
  461.  
  462.  
  463.  
  464.  
  465.  
  466. notation(n)       MISC. REFERENCE MANUAL PAGES        notation(n)
  467.  
  468.  
  469.  
  470.              these file is needed by the (la)tex driver
  471.  
  472.  
  473. SEE ALSO
  474.      xchess(1), chess(6), gnuchess(1), latex(1), nroff(1), lpr(1)
  475.  
  476.  
  477. DIAGNOSTICS
  478.      Errors messages are hoped to be self-explanative.
  479.  
  480.  
  481. COMMENTS
  482.      The program is quite large, due  to  the  extensive  use  of
  483.      tables  and variables to control its features. The advantage
  484.      is you only need the modify these tables  to  customize  it:
  485.      for instance adding a new language or tuning the output for-
  486.      mat to your own needs.
  487.  
  488.  
  489. BUGS
  490.      Too many. Report them to Henry.Thomas@irisa.fr.
  491.  
  492.      The postscript driver *might* fail if you try to display the
  493.      board  two times. Anyway, it is not designed to do this. Use
  494.      -e option to specify the move at which you want  to  display
  495.      board.
  496.  
  497.      Do not enter  two  levels  of  variation  without  any  move
  498.      between  them.  It  will cause the crash of the program. For
  499.      instance, { { is wrong, but  { Qd1 { is correct.
  500.  
  501.  
  502.  
  503. AUTHOR
  504.      Henry    Thomas    IRISA-Rennes,    FRANCE.    E-mail     to
  505.      Henry.Thomas@irisa.fr or hthomas@irisa.fr.
  506.  
  507. THANKS
  508.      Thanks to Jacques Schuurman for the piece  names  in  Dutch,
  509.      Philippe  Louarn for explaining me some TeX tricks, Lael for
  510.      czech, hungarian, polish, romanian and FIDE piece names,  to
  511.      Steven  Young.  Most of all, thank to Jean-Luc Scharbarg for
  512.      introducing me to chess.
  513.  
  514.  
  515.  
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525. Sun Release 4.1   Last change: 10 December 1990                 8
  526.  
  527.  
  528.  
  529.