home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / bwbasic.zip / src / bwb_mes.h < prev    next >
C/C++ Source or Header  |  1993-04-27  |  12KB  |  243 lines

  1. /***************************************************************
  2.  
  3.         bwb_mes.h       Header File for Natural-Language-Specific
  4.                         Text Messages for Bywater BASIC Interpreter
  5.  
  6.                         Copyright (c) 1992, Ted A. Campbell
  7.  
  8.                         Bywater Software
  9.                         P. O. Box 4023
  10.                         Duke Station
  11.                         Durham, NC  27706
  12.  
  13.                         email: tcamp@acpub.duke.edu
  14.  
  15.         Copyright and Permissions Information:
  16.  
  17.         All U.S. and international copyrights are claimed by the
  18.         author. The author grants permission to use this code
  19.         and software based on it under the following conditions:
  20.         (a) in general, the code and software based upon it may be
  21.         used by individuals and by non-profit organizations; (b) it
  22.         may also be utilized by governmental agencies in any country,
  23.         with the exception of military agencies; (c) the code and/or
  24.         software based upon it may not be sold for a profit without
  25.         an explicit and specific permission from the author, except
  26.         that a minimal fee may be charged for media on which it is
  27.         copied, and for copying and handling; (d) the code must be
  28.         distributed in the form in which it has been released by the
  29.         author; and (e) the code and software based upon it may not
  30.         be used for illegal activities.
  31.  
  32. ***************************************************************/
  33.  
  34.  
  35. #ifndef TRUE
  36. #define TRUE    1
  37. #define FALSE   0
  38. #endif
  39.  
  40. /* Define only one of the following as TRUE: if none is defined,
  41.    standard ENGLISH will be taken as the default */
  42.  
  43. #define ENGLISH         TRUE        /* standard English */
  44. #define POL_ENGLISH     FALSE        /* polite English messages */
  45. #define IMP_ENGLISH    FALSE        /* impolite English messages */
  46. #define LATIN        FALSE        /* Latin language messages */
  47.  
  48. /****************************************************************
  49.  
  50.     The following Latin conventions are used:
  51.  
  52.     LATIN            ENGLISH
  53.  
  54.     acies datorum        array (of data)
  55.         crusta            shell
  56.     litteras        (character) string
  57.     memoria mutabilis    RAM
  58.     organum            device
  59.     ordo            line
  60.     praeceptum        command
  61.       praecepta          program (commands)
  62.       praecepta interna      operating system
  63.       praeceptellum          function
  64.     tabula            file
  65.  
  66. ****************************************************************/
  67.  
  68. #if LATIN
  69. #define MES_SIGNON      "Interpres et Crusta <Super Flumina> ad linguam BASIC, versionis"
  70. #define MES_COPYRIGHT   "Iure proprio scriptoris (c) 1992, Eduardi de Campobello"
  71. #define MES_LANGUAGE    "Cum nuntiis latinis ab ipso E. de C."
  72. #define PROMPT          "bwBASIC:"
  73. #define ERROR_HEADER    "ERRANT praecepta in ordine"
  74. #define MATHERR_HEADER  "ERRANT praecepta"
  75. #define MES_BREAK       "Intermittuntur praecepta in ordine"
  76. #define ERR_OPENFILE    "Non patet tabula quod <%s> vocatur"
  77. #define ERR_GETMEM      "Deest memoria mutabilis"
  78. #define ERR_LINENO      "Non adicitur novus ordo praeceptorum"
  79. #define ERR_LNNOTFOUND  "Non invenitur ordo praeceptorum <%d>"
  80. #define ERR_LOADNOFN    "LOAD requirit nomen ad tabulam"
  81. #define ERR_NOLN        "Non invenitur ordo praeceptorum"
  82. #define ERR_NOFN        "Non invenitur nomen ad tabulam"
  83. #define ERR_RETNOGOSUB  "RETURN sine GOSUB"
  84. #define ERR_INCOMPLETE  "Praeceptum imcompletum"
  85. #define ERR_ONNOGOTO    "ON sine GOTO sive GOSUB"
  86. #define ERR_VALOORANGE  "Numerus in praeceptis excedit fines"
  87. #define ERR_SYNTAX      "Non sequunter praecepta"
  88. #define ERR_DEVNUM      "Numerus ad organum invalidum est"
  89. #define ERR_DEV         "Errat organum"
  90. #define ERR_OPSYS    "Errant praecepta interna"
  91. #define ERR_ARGSTR    "Praeceptum requirit litteras"
  92. #define ERR_DEFCHAR    "ad varium definiendum"
  93. #define ERR_MISMATCH    "Non congruunt typus"
  94. #define ERR_DIMNOTARRAY    "Praeceptum requirit nomen ad aciem datorum"
  95. #define ERR_OD        "Desunt data"
  96. #define ERR_OVERFLOW    "Data excedunt fines"
  97. #define ERR_NF        "NEXT sine FOR"
  98. #define ERR_UF        "Non definitur praeceptellum"
  99. #define ERR_DBZ        "Non licet divisio ab nihilo"
  100. #define ERR_REDIM    "Non licet varium iterum definiendum"
  101. #define ERR_OBDIM    "Debet OPTION BASE procedere DIM"
  102. #define ERR_UC        "Praeceptum incognitum est"
  103. #endif
  104.  
  105. #if POL_ENGLISH
  106. #define MES_SIGNON      "Bywater BASIC Interpreter/Shell, version"
  107. #define MES_COPYRIGHT   "Copyright (c) 1992, Ted A. Campbell"
  108. #define MES_LANGUAGE    "Polite English messages courtesy of t.a.c."
  109. #define PROMPT          "How may we help you?"
  110. #define ERROR_HEADER    "Very sorry. There is a problem in line"
  111. #define MATHERR_HEADER  "We have a small problem"
  112. #define MES_BREAK       "At your request, the program has been interrupted at line"
  113. #define ERR_OPENFILE    "I'm afraid we have failed \nto open file %s."
  114. #define ERR_GETMEM      "I'm afraid we have failed \nto find sufficient memory."
  115. #define ERR_LINENO      "I'm afraid we have failed \nto link line number."
  116. #define ERR_LNNOTFOUND  "I'm afraid that we \ncannot find line number %d."
  117. #define ERR_LOADNOFN    "Could you perhaps specify \nwhich file you wish to be loaded?"
  118. #define ERR_NOLN        "It would help greatly \nif there were a line number here."
  119. #define ERR_NOFN        "It would help greatly \nif there were a file name here."
  120. #define ERR_RETNOGOSUB  "Is it possible \nthat there is a RETURN without a GOSUB here?"
  121. #define ERR_INCOMPLETE  "I'm afraid that the statement\nappears to be incomplete."
  122. #define ERR_ONNOGOTO    "It appears that there is an ON \nwithout a corresponding GOTO or GOSUB statement."
  123. #define ERR_VALOORANGE  "A value given here \nseems to be out of range."
  124. #define ERR_SYNTAX      "Could it be \nthat there is a syntax error at this point?"
  125. #define ERR_DEVNUM      "The device or file \nnumber here does not seem to be correct."
  126. #define ERR_DEV         "There appears \nto have been an error addressing the file or device \nwhich you requested."
  127. #define ERR_OPSYS    "A most unfortunate error \nseems to have been generated by the computer's operating system."
  128. #define ERR_ARGSTR    "Could you perhaps \nsupply a string argument at this point?"
  129. #define ERR_DEFCHAR    "The variable definition \nat this point appears to have an improper argument."
  130. #define ERR_MISMATCH    "It would appear \nthat something in this statement is rather seriously mismatched."
  131. #define ERR_DIMNOTARRAY    "Could you perhaps \nsupply an array name for the argument at this point?"
  132. #define ERR_OD        "Oh dear, we seem to have no more data to read now."
  133. #define ERR_OVERFLOW    "Subhuman devices \ndo have their limits, and we're afraid that at this point \nthe limits of Bywater BASIC have been exceeded."
  134. #define ERR_NF        "There seems to be \na NEXT statement without a corresponding FOR statement. Could you check on it?"
  135. #define ERR_UF        "It would appear \nthat the function named at this point has not been defined."
  136. #define ERR_DBZ        "Unfortunately, \ndivision by zero can cause dreadful problems in a computer."
  137. #define ERR_REDIM    "We're very sorry \nto say that a variable such as this cannot be redimensioned."
  138. #define ERR_OBDIM    "It would be ever so helpful \nif the OPTION BASE statement were to be called prior to the DIM statement."
  139. #define ERR_UC        "I'm afraid that \nwe are unable to recognize the command you have given here."
  140. #endif
  141.  
  142. #if IMP_ENGLISH
  143. #define MES_SIGNON      "Bywater BASIC Interpreter/Shell, version"
  144. #define MES_COPYRIGHT   "Watch it: Copyright (c) 1992, Ted A. Campbell"
  145. #define MES_LANGUAGE    "Impolite English messages courtesy of Oscar the Grouch"
  146. #define PROMPT          "(*sigh) What now?"
  147. #define ERROR_HEADER    "YOU SCREWED UP at line"
  148. #define MATHERR_HEADER  "ANOTHER SCREWUP!"
  149. #define MES_BREAK       "Only a geek like you would interrupt this program at line"
  150. #define ERR_OPENFILE    "Ha ha! I can't open file %s. Too bad, sucker."
  151. #define ERR_GETMEM      "There isn't near enough memory \nfor this lunacy."
  152. #define ERR_LINENO      "You jerk: \nyou entered a non-existent line number."
  153. #define ERR_LNNOTFOUND  "You total idiot.  \nLine number %d isn't there. HA!"
  154. #define ERR_LOADNOFN    "Get out of here. \nNo way to load that file."
  155. #define ERR_NOLN        "Dumb bozo: you need to put \na LINE NUMBER here. Hint: Can you count?"
  156. #define ERR_NOFN        "Nerd of the year. \nYou forgot to enter a file name. \nWhy don't you learn BASIC and come back in a year?"
  157. #define ERR_RETNOGOSUB  "Oh come on, total amateur. \nYou've got a RETURN without a GOSUB"
  158. #define ERR_INCOMPLETE  "Dimwit. Why don't you \ncomplete the statement here for a change."
  159. #define ERR_ONNOGOTO    "You failed again: \nON without a GOTO or GOSUB."
  160. #define ERR_VALOORANGE  "Go home, beginner. \nThe value here is way out of range."
  161. #define ERR_SYNTAX      "Sure sign of a fourth-rate programmer: \nThis makes no sense at all."
  162. #define ERR_DEVNUM      "Way to go, space cadet. \nThe device (or file) number here is totally in orbit."
  163. #define ERR_DEV         "HO! The file or device \n you requested says: DROP DEAD."
  164. #define ERR_OPSYS    "You obviously don't know \nwhat this computer can or can't do."
  165. #define ERR_ARGSTR    "Do you have big ears? \n(Like Dumbo?) You obviously need a string argument at this point."
  166. #define ERR_DEFCHAR    "Amazing. Surely children \nknow how to form a corrent argument here."
  167. #define ERR_MISMATCH    "No way, turkey. \nThe statement here is TOTALLY mismatched."
  168. #define ERR_DIMNOTARRAY    "Incredible. Why don't you \nsuppy an ARRAY NAME where the prograqm calls for an ARRAY NAME? (Or just go home.)"
  169. #define ERR_OD        "Have you ever studied BASIC before? \nYou've run out of data."
  170. #define ERR_OVERFLOW    "Congratulations on writing a program \nthat totally exceeds all limits."
  171. #define ERR_NF        "Go back to kindergarten: \nYou have a NEXT statement FOR."
  172. #define ERR_UF        "Trash. Total trash. \nDefine your stupid functions before calling them."
  173. #define ERR_DBZ        "Obviously, you'll never be a programmer. \nYou've tried division by zero here."
  174. #define ERR_REDIM    "You just don't understand: \nyou cannot redimension this variable."
  175. #define ERR_OBDIM    "Dork. You called OPTION BASE after DIM. \nLeave me alone."
  176. #define ERR_UC        "What do you think this is? \nTry entering a BASIC command here."
  177. #endif
  178.  
  179. /* Standard English is taken as a default: if MES_SIGNON is not defined by
  180.    this time (i.e., by some other language definition), then
  181.    the following standard English definitions are utilized. */
  182.  
  183. #ifndef MES_SIGNON
  184. #define MES_SIGNON      "Bywater BASIC Interpreter/Shell, version"
  185. #define MES_COPYRIGHT   "Copyright (c) 1992, Ted A. Campbell"
  186. #define MES_LANGUAGE    "Default English-Language Messages"
  187. #define PROMPT          "bwBASIC:"
  188. #define ERROR_HEADER    "ERROR in line"
  189. #define MATHERR_HEADER  "ERROR"
  190. #define MES_BREAK       "Program interrupted at line"
  191. #define ERR_OPENFILE    "Failed to open file %s"
  192. #define ERR_GETMEM      "Failed to find memory"
  193. #define ERR_LINENO      "Failed to link line number"
  194. #define ERR_LNNOTFOUND  "Line number %d not found"
  195. #define ERR_LOADNOFN    "LOAD: no filename specified"
  196. #define ERR_NOLN        "No line number"
  197. #define ERR_NOFN        "No file name"
  198. #define ERR_RETNOGOSUB  "RETURN without GOSUB"
  199. #define ERR_INCOMPLETE  "Incomplete statement"
  200. #define ERR_ONNOGOTO    "ON without GOTO or GOSUB"
  201. #define ERR_VALOORANGE  "Value is out of range"
  202. #define ERR_SYNTAX      "Syntax error"
  203. #define ERR_DEVNUM      "Invalid device number"
  204. #define ERR_DEV         "Device error"
  205. #define ERR_OPSYS    "Error in operating system command"
  206. #define ERR_ARGSTR    "Argument must be a string"
  207. #define ERR_DEFCHAR    "Incorrect argument for variable definition"
  208. #define ERR_MISMATCH    "Type mismatch"
  209. #define ERR_DIMNOTARRAY    "Argument is not an array name"
  210. #define ERR_OD        "Out of data"
  211. #define ERR_OVERFLOW    "Overflow"
  212. #define ERR_NF        "NEXT without FOR"
  213. #define ERR_UF        "Undefined function"
  214. #define ERR_DBZ        "Divide by zero"
  215. #define ERR_REDIM    "Variable cannot be redimensioned"
  216. #define ERR_OBDIM    "OPTION BASE must be called prior to DIM"
  217. #define ERR_UC        "Unknown command"
  218. #endif
  219.  
  220. extern char err_openfile[];
  221. extern char err_getmem[];
  222. extern char err_noln[];
  223. extern char err_nofn[];
  224. extern char err_lnnotfound[];
  225. extern char err_incomplete[];
  226. extern char err_valoorange[];
  227. extern char err_syntax[];
  228. extern char err_devnum[];
  229. extern char err_dev[];
  230. extern char err_opsys[]; 
  231. extern char err_argstr[];
  232. extern char err_defchar[];
  233. extern char err_mismatch[];
  234. extern char err_dimnotarray[];
  235. extern char err_od[];
  236. extern char err_overflow[];
  237. extern char err_nf[];
  238. extern char err_uf[];
  239. extern char err_dbz[];
  240. extern char err_redim[];
  241. extern char err_obdim[];
  242. extern char err_uc[];
  243.