home *** CD-ROM | disk | FTP | other *** search
/ Archive Magazine 1996 / ARCHIVE_96.iso / text / hints / volume_4 < prev    next >
Text File  |  1995-06-25  |  179KB  |  4,391 lines

  1. Å 160k ADFS discs for the Archimedes?  If you have upgraded to the
  2. Archimedes from a Master, or even a Beeb with ADFS, you might have some
  3. 5.25ö discs you want to transfer.  According to the manuals, the
  4. Archimedes will only read and write to 640k (L) format, Arthur 800k (D)
  5. format, or the RISC-OS 800k (E) format using either 3.5ò or 5.25ö discs
  6. (80T).  However, the Master could read and write 40T 160k (S) format,
  7. 80T 320k (M) format, or 80T 640k (L) format discs.  I discovered by
  8. accident that the Archimedes will quite happily read 5.25ò 160k (S)
  9. discs in 40T mode, and in fact save them Ö I have not been able to try
  10. out 320k discs since I do not have any.  You cannot, however, format
  11. discs at either 160k or 320k on the Archimedes but then why would you
  12. want to anyway? Chris Hughes (Wakefield BBC Micro User Group).
  13. 4.01
  14. Å Apocalypse Tips Ö Progressing from planet to planet is really simple. 
  15. At the start of the game, a map of your selected planet is displayed. 
  16. All the objects on the planetæs surface are represented by coloured
  17. dots, about 80% of which must be destroyed for your craft to be
  18. withdrawn and for you to be allocated another planet.
  19. 4.01
  20. As you progress through the game and return to the ÉGuild of Spacingsæ
  21. you will be given various add-ons for your ship.  These include a super-
  22. cooler for your laser-canon and better shielding.  It is vital that you
  23. have these if you intend to progress at a reasonable pace, so it is
  24. advisable to get them as soon as possible.  Remember, you can only
  25. return a maximum of five times before being rejected by the Guild.  When
  26. you have destroyed your 80% or so, you will automatically be withdrawn
  27. by the Guild Ö this may take some time so donæt give up too quickly!
  28. 4.01
  29. If you prefer rather more action and less running away, the following
  30. lines of the BASIC file É!Apocalyps.Apocalypseæ can be changed.
  31. 4.01
  32. Line 290 is your starting score.
  33. 4.01
  34. Replace line 330 with:  330 !shieldcharge=16 :
  35. !rapidturnF=1:!guntempcooler=0
  36. 4.01
  37. Now delete lines 340 to 380 inclusive for all the extra features and
  38. (very) strong shields.
  39. 4.01
  40. Replace line 770 with: UNTIL 0 for infinite lives.  At line 1970
  41. !impcounter is the number of objects you have shot, which determines how
  42. many you have to go before advancing to the next planet.  For instant
  43. withdrawal, replace 1970 with: 1970 !impcounter=10000.
  44. 4.01
  45. Line 6910 is how many times you can return to the guild before rejection
  46. (this is normally 5).
  47. 4.01
  48. Å HFORM v1.72 bug or feature?  If you try to format an ST506 hard disc
  49. that has had a different profile (e.g. it was used on  a PC beforehand)
  50. with the Acorn HFORM program supplied on the RISC-OS Supplement Disc,
  51. the new disc shape option will not be acknowledged and so the full
  52. capacity of the drive may not be realised.  This can be overcome by
  53. removing the line that reads:
  54. 4.01
  55.    2130 IF cyl%=0 IF head%=0 IF Formatted% GOTO 2180
  56. 4.01
  57. Brian Oliver.
  58. 4.01
  59. Å Hostages cheat mode Ö If you hold down the <R>, <U>, <T> and <H> keys
  60. once the title screen has loaded and press <return>, you will enter into
  61. the cheat mode.  This allows you to jump to either section two or three
  62. of the game with three hostages and seven terrorists.
  63. 4.01
  64. Å RAM discs for the PC Emulator Ö It is possible to create a hard disc
  65. partition in any filing system.  For example, by altering the !PC.!Run2
  66. file so that the path for Drive D is ÉRAM:$.RamDiscæ and using the FDISK
  67. program to create a RAMFS hard disc partition, you can obtain any size
  68. RAM disc you require _ memory and pages sizes permitting.  Michael Ben-
  69. Gershon.
  70. 4.01
  71. Å Reading a system variable from BASIC Ö The question was, öIæve got a
  72. system variable being set in the !Run obey file:
  73. 4.01
  74.    Set MaxNumberOfFonts 32
  75. 4.01
  76. and I want to be able to read this value into a BASIC variable but when
  77. I use:
  78. 4.01
  79.    value% = VAL (ö<MaxNumberOfFonts>ò)
  80. 4.01
  81. it produces the error ÉVariable not foundæ, because it takes the É<æ
  82. character as meaning Éless thanæ rather than Éstart of system variableæ. 
  83. Using the BASIC keyword EVAL has the same effect.
  84. 4.01
  85. The first thing we need to do is to extract the value of the system
  86. variable into a string that we can manipulate.  After searching through
  87. the PRM volume II, I eventually found OS_ReadVarVal (SWI&23) on page
  88. 750.  On entry, R0 points to the name of the system variable to be read,
  89. R1 points to a suitable buffer to store the string in, R2 is the maximum
  90. length of this buffer, R3 is set to 0 to use the first occurance of the
  91. named system variable, and R4 is set to 3 so that an expanded string is
  92. returned in the buffer.
  93. 4.01
  94. On exit, we should now have the value of the system variable in the form
  95. of a string.  The next task is to convert this string into an integer,
  96. and this is easily performed by using OS_ReadUnsigned (SWI &21) on page
  97. 585.  On entry, R0 is set to 0 so that the base number used is assumed
  98. to be 10 unless the string indicates otherwise, R1 is the pointer to the
  99. string (note that this is the same as R1 for OS_ReadVarVal, which is
  100. preserved on exit).  On exit R2 contains the value of the system
  101. variable as an integer, using only two SWI calls.
  102. 4.01
  103. This is easily implemented in both BASIC and ARM assembler.
  104. 4.01
  105. In BASIC this can be achieved with 4 instructions:
  106. 4.01
  107.    MaxBufferLength = 16
  108. 4.01
  109.    DIM BufferPtr MaxBufferLength
  110. 4.01
  111.    SYS öOS_ReadVarValò, öMaxNumberOfFontsò, BufferPtr,
  112. MaxBufferLength,0,3
  113. 4.01
  114.    SYS öOS_ReadUnsignedò,0,BufferPtr TO ,,value%
  115. 4.01
  116. and if you want to do in Arm assembler, then only eight instructions are
  117. necessary:
  118. 4.01
  119.    ...
  120. 4.01
  121.    ADR R0, SystemVariablePtr ; point to system variable
  122. 4.01
  123.    ADR R1, BufferPtr; point to buffer
  124. 4.01
  125.    MOV R2, #MaxBufferLength ; length of buffer
  126. 4.01
  127.    MOV R3, #0 ; use first one found
  128. 4.01
  129.    MOV R4, #3 ; expand fully
  130. 4.01
  131.    SWI XOS_ReadVarVal ; R1 preserved
  132. 4.01
  133.    MOV R0, #0 ; use default base
  134. 4.01
  135.    SWI XOS_ReadUnsigned ; R2 = value%
  136. 4.01
  137.    SystemVariablePTr = öMaxNumberOfFontsò, 0 ; note no É<æ or É>æ are
  138. used
  139. 4.01
  140.    ALIGN
  141. 4.01
  142.    MaxBufferLength * 16
  143. 4.01
  144.    BufferPtr % MaxBufferLength ; reserve MaxBufferLength
  145. 4.01
  146.    ALIGN ; bytes of workspace
  147. 4.01
  148. To give a quick example of its use.  ÉSetMaxNumberOfFonts 16æ gives
  149. value% = 16.  ÉSetMaxNumberOfFonts &20 gives value% = 32.
  150. 4.01
  151. This may be of use to programmers, as it allows constants to be set up
  152. in the !Run obey file and users can modify them to fit their require
  153. ments, without having to modify the program itself.  John ÉLoftyæ
  154. Wallace.
  155. 4.01
  156. Å System Variables for the Filer Module (Archive 3.11 p7) Ö The problem
  157. with the Filer module not allowing you to include system variables can
  158. be solved a lot easier (and without taking up any valuable RMA space).
  159. 4.01
  160. I like to use icons for the directories which contain the third party
  161. applications, demos, utilities, etc.  This meant using an application
  162. directory and I wanted a general purpose !Run obey file to open the
  163. directory viewer (using Filer_OpenDir).  However, I came across the same
  164. problem as Simon Callan.  The solution I present here was passed on to
  165. me by Paul Fellows (who wrote ÉArchimedes Basic Compileræ amongst other
  166. things) and so I donæt wish to take the credit for such a neat idea.
  167. 4.01
  168. So that I donæt have the !Run, !Sprites, etc with the actual programs I
  169. want to view, I create a directory É_æ inside that application directory
  170. to hold them.  Thus my !Run obey file reads as follows:
  171. 4.01
  172.    |!Run obey file
  173. 4.01
  174.    |
  175. 4.01
  176.    IconSprites <Obey$Dir>.!Sprites
  177. 4.01
  178.    Set Alias$OpenDir Filer_OpenDir <Obey$Dir>._
  179. 4.01
  180.    OpenDir
  181. 4.01
  182. Setting a command string as an ÉAliasæ will expand any system variables
  183. within that command string.  This gets around the problem which Simon
  184. describes, and also means that you donæt need to run a program every
  185. time you switch the machine on.  John ÉLoftyæ Wallace.
  186. 4.01
  187.  
  188. Å 160k ADFS Discs (continued from Archive 4.1 p9) Ö It is certainly true
  189. that the Archimedes can be made to read and write 160k or 320k ADFS
  190. discs correctly.  I think, however, that the Archimedes Éseesæ these as
  191. 640k L format discs and if a read or write operation directs it to a
  192. track beyond 39 (160k) it will try to push the disc head off the edge of
  193. the disc searching for tracks that arenæt there.  Fine if you know what
  194. youære doing.  Lorcan Mongey.
  195. 4.02
  196. Å Am I in the desktop?  You can use the Wimp_ReadSysInfo SWI command to
  197. see if your program is running in the desktop or not.  The command
  198. returns the number of active tasks, which will be zero if the program is
  199. running outside of the desktop environment.  The example program below
  200. will sense whether it has been run from the desktop environment and if
  201. not, it will start up the desktop before running another application (in
  202. this case !Edit).
  203. 4.02
  204.    program segment missing
  205. 4.02
  206. Adrian Look.
  207. 4.02
  208. Å Apocalypse hints & tips Ö If you shoot the green T-shaped buildings
  209. with a triangular roof using a mega photon your shield will be replen
  210. ished.  If you shoot a purple and green mushroom, your shield will go
  211. into override but your points are decreased for anything you hit with
  212. the photons you are allocated.  If you shoot a rectangular brown
  213. building they leave a shallow pyramid and if you shoot this, a Rakon
  214. Gomjabba will appear and you will get a few more points for destroying
  215. this.  If you shoot a Snail Rider with a mega photon, your energy banks
  216. are recharged.  If you shoot a green mushroom, your score will decrease
  217. for everything you hit with the mega photons allocated.
  218. 4.02
  219. If you type in and run the following program with disc two in drive 0
  220. you will then be able to access all of Apocalypseæs nine worlds.
  221. 4.02
  222.    program segment missing
  223. 4.02
  224. Paul Bedford.
  225. 4.02
  226. Å Bug in the Debugger Module Ö Some of you may be aware of a problem
  227. with the Debugger module failing to disassemble certain instructions
  228. correctly if they contain an immediate constant.  An immediate constant
  229. is stored as an eight-bit value with a 4-bit shift applied, and the
  230. debugger normally expands this format to its correct value, but
  231. occasionally fails, e.g.
  232. 4.02
  233.    E28F0C01 ADD R0,PC, #&0100 correctly expanded
  234. 4.02
  235.    E28F0D01 ADD R0,PC, #&01,26 failed to expand (should be #&40)
  236. 4.02
  237. I have disassembled the debugger module and found the offending piece of
  238. code.  It doesnæt seem to be a bug, rather a deliberate move to expand
  239. constants differently under certain circumstances but for no obvious
  240. reason.  Anyway, the fix is to change the word at offset &920 in the
  241. module from &1A000028 to &FA000028, effectively changing a BNE to a BNV. 
  242. This seems to solve the problem, although I havenæt tested this fix
  243. exhaustively, so proceed with caution.  Lorcan Mongey.
  244. 4.02
  245. Å BUILDing !Run files Ö If you write a !Run file using *BUILD and want
  246. to include a line such as:
  247. 4.02
  248.    Run <Obey$Dir> .!RunImage
  249. 4.02
  250. then, instead, you should type:
  251. 4.02
  252.    Run |<Obey$Dir>.!RunImage
  253. 4.02
  254. to prevent RISC-OS from inserting the value of Obey$Dir into the file. 
  255. It may be obvious but until now I have been using !Edit to write a two
  256. line Obey file!  Elliott Hughes.
  257. 4.02
  258. Å Copy Options Ö öConfirmò and öVerboseò Ö I think this is probably one
  259. of those hints which would be classed as öobviousò by those who know it: 
  260. The Archimedes User Guide and the PRM both describe, at some length, the
  261. use of the system variable Copy$Options which sets default options for
  262. the *Copy command.  However, neither make if clear that the desktop
  263. filer has its own öConfirmò and öVerboseò options which are quite
  264. independent of those which are stored in the system variable.  Thus no
  265. amount of modification of Copy$Options in boot files or elsewhere will
  266. affect the way the desktop behaves.
  267. 4.02
  268. The filer options can be read and changed by clicking the menu button
  269. over any directory window and choosing the Options option.  The options
  270. selected by this route differ in one significant way from the
  271. Copy$Options in that they are stored in battery-backed RAM and thus are
  272. preserved when the machine is switched off or reset.  They are stored in
  273. byte 198 of the CMOS RAM (not byte 195 as my copy of the PRM says) along
  274. with various other desktop options:
  275. 4.02
  276.    program segment missing
  277. 4.02
  278. Having these options stored in CMOS RAM can sometimes be an advantage
  279. but on the whole I find it rather inconvenient.  For instance, I often
  280. change temporarily from an icon display to öFull Infoò and would like
  281. icons to be restored after a reset.  Luckily this sort of preference can
  282. easily be dealt with by a few lines in the boot routine.  For instance,
  283. the following lines of BASIC will reset the Display mode to small icons
  284. while preserving the other options:
  285. 4.02
  286.    program segment missing
  287. 4.02
  288. Hugh Eagle.
  289. 4.02
  290. Å Cut and paste clip board Ö Many RISC-OS applications have a Écut and
  291. pasteæ option.  If these applications can also edit more than one
  292. document at a time then you can use the Écut and pasteæ option as a clip
  293. board to transfer data from one document to another.  For example, you
  294. can select a block of text in one !Edit document, move to another
  295. document and then use the <ctrl><c> option to copy the block into that
  296. document.  This method will also work with applications such as
  297. PipeDream but not Ovation or Impression, etc as they use the Éclip
  298. boardæ method.  Steve Drain.
  299. 4.02
  300. Å Deskjet Plus Ink Cartridges, Recharging Ö You may have discovered the
  301. same problem as me when trying to recharge these cartridges, namely that
  302. the ink wonæt go in the hole!
  303. 4.02
  304. A bit of reverse engineering, with the aid of a hacksaw, has revealed
  305. the cause.  The container is filled with a dense spongy material which
  306. holds the ink, but this does not enter the cavity formed by the raised
  307. green portion with the central vent hole.  If a syringe needle is
  308. entered through this hole it must be long enough to reach into the
  309. sponge.  At least 20mm is required.  If this is not the case then the
  310. inserted ink charge is held on top of the sponge by surface tension, and
  311. quickly overflows through the charge hole.
  312. 4.02
  313. The only syringes which I can get hold of are intended for diabetics and
  314. have a needle which is too short to reach the sponge through the top
  315. hole.  The solution is to fill the sponge through the top hole.  The
  316. solution is to fill through a second hole, drilled as small as possible,
  317. on the 3mm wide land to the side of the raised portion.  In this
  318. location there is a small internal cavity not filled with sponge.  This
  319. prevents capillary leakage after recharging.
  320. 4.02
  321. Archive readers may be interested in the following program which will
  322. draw a sketch showing the location of the hole.  It should be made as
  323. close to the vertical wall of the raised portion as is possible.
  324. 4.02
  325.    program segment missing
  326. 4.02
  327. With regard to inks I have excellent results with Rotring Art Pen Ink
  328. which comes in many colours.  Bill Graham.
  329. 4.02
  330. Å MEMC DMA control register Ö With reference to Sean Kellyæs tip in June
  331. É90 for gaining extra speed from the Archimedes by disabling the VIDCæs
  332. DMA access.  Although the technique normally works without any trouble,
  333. occasionally the machine crashes or has its memory contents corrupted. 
  334. As Sean correctly stated, bit 10 of the MEMC register controls VIDC DMA,
  335. however, as the dynamic RAM (DRAM) in the machine is no longer being
  336. read by the VIDC it is also no longer being refreshed properly.  Bits 8
  337. & 9 of the MEMC come to the rescue, they are the DRAM refresh control
  338. bits.
  339. 4.02
  340. There are three available modes of refresh:-
  341. 4.02
  342.             bit 8   bit 9
  343. 4.02
  344. a) no refresh         1   0
  345. 4.02
  346.     (not used by the Archimedes)
  347. 4.02
  348. b) refresh during video flyback      0   1
  349. 4.02
  350. c) continuous refresh         1   1
  351. 4.02
  352. Flyback time during standard modes (0-16 & 24) is greater than the DRAM
  353. holding time and as such requires refresh during flyback.  In multi-sync
  354. modes the flyback time is much faster and the memory does not need to be
  355. refreshed by the MEMC.
  356. 4.02
  357. The codes for the various modes are:-SYSöOS_UpdateMEMCÉ,768,1792 to turn
  358. off the VIDC DMA and invoke continuous refresh and
  359. SYSöOS_UpdateMEMCÉ,1536,1792 to return to normal for standard modes.
  360. 4.02
  361. It should be pointed out that the continuous refresh mode uses the DMA
  362. video pointer as the refresh address source, incrementing the pointer
  363. after use.  As such this should be used with care if the pointer is used
  364. as an active part of your program whilst the screen is blanked.  (But
  365. why would you want to move the pointer if you canæt see it??)
  366. 4.02
  367. There is also a sound DMA control bit in the MEMC but as this does not
  368. affect memory refresh bits 8 and 9 which do not need to be altered.
  369. 4.02
  370. Bit 11 Ö 0 Sound DMA disable
  371. 4.02
  372.               1 Sound DMA enable
  373. 4.02
  374. Rob Swain.
  375. 4.02
  376. Å Modifying the RISC-OS dot matrix printer driver Ö To add a new dot
  377. matrix printer configuration to the RISC-OS printer driver you will need
  378. to alter the ÉPrDataæ file in the É!PrinterDMæ directory (on you
  379. Applications Disc One or RISC-OS Extras Disc = Shareware 17):
  380. 4.02
  381. 1)  Make sure you have made a back up copy
  382. 4.02
  383. 2)  Run the !Edit program on Applications Disc One
  384. 4.02
  385. 3)  Double click on the copy of !PrinterDM that you wish to alter,
  386. whilst holding the <shift> key down Ö a filer window will then open with
  387. the contents of the !PrinterDM application inside
  388. 4.02
  389. 4)  Double click on the ÉPrDataæ file in the !PrinterDM filer window Ö a
  390. text window will then open
  391. 4.02
  392. 5)  Use the arrow keys to position the caret (red vertical text cursor)
  393. just before the ÉConfigured optionsæ heading and after the row of full
  394. stops
  395. 4.02
  396. 6)  Add the following text changing the information to match your
  397. printer (the example below adds a Shinwa CP80/Lucas LX80 option to the
  398. RISC-OS printer driver):
  399. 4.02
  400.    program segment missing
  401. 4.02
  402. Alan Dawes
  403. 4.02
  404. Å Nevryon hints & tips Ö Nevryon passwords for level three, five and
  405. seven are given at the foot of this column, the letters being reversed
  406. for the benefit of those who prefer to ignore them.
  407. 4.02
  408. The following Nevryon cheat allows the ship to be upgraded to have any
  409. weapons desired and energy/credits/lives may also be altered.
  410. 4.02
  411. Load the É!Nevryon.Multiæ file on the Nevryon disc 1 and insert the
  412. following at line 211.
  413. 4.02
  414.    211 Dump=PAGE-&3F800:Dump?n=value
  415. 4.02
  416. where n is:
  417. 4.02
  418. n=27:   Ship speed, 4 recommended
  419. 4.02
  420. n=28:   Shield orb (top), 1=ON 0=Off
  421. 4.02
  422. n=29:   Shield orb (bottom), 1=ON 0=OFF
  423. 4.02
  424. n=30:   RAM, 1=ON, 0=OFF
  425. 4.02
  426. n=32:   Gun droids, 0-2
  427. 4.02
  428. n=33   Lasers, 0-2
  429. 4.02
  430. n=35:   Number of credits (default 3)
  431. 4.02
  432. n=36:   Number of lives (default 4)
  433. 4.02
  434. n=37:   Starting secondary weapons status, 0=Off, 1=flamer, etc
  435. 4.02
  436. n=38:   Gold bar status, 0=OFF, 1=flamer, 2=mines, etc
  437. 4.02
  438. n=43:   Amount of energy (default 12)
  439. 4.02
  440. Change as many of these values as you want and save altered program and
  441. repeat the process for the $.Multi file on the Nevryon 2 disc.  Jeremy
  442. Mears.
  443. 4.02
  444.    upside down words missing!
  445. 4.02
  446. Å Printing a full path name Ö This is a reply to the cry of help in
  447. February 1990 from Richard Skemp about how to get the printer driver to
  448. include the full pathname.  If you add the following line to the Library
  449. program in the !PrinterDM directory, the printer driver will print the
  450. full file pathname of any text file you print.
  451. 4.02
  452.    3281 BPUT#outfile%, CHR$13+CHR$10 +öPrinting file ò+filenam$
  453. +CHR$13+CHR10+CHR$10
  454. 4.02
  455. Lorcan Mongey.
  456. 4.02
  457. Å Reinstating the filer module Ö An item on system variables mentions
  458. that if you *RMFaster the filer module from the desktop, you lose the
  459. filer icons and canæt get them back (Archive 3.11 p7).  To retrieve
  460. them, try:
  461. 4.02
  462.    <F12>
  463. 4.02
  464.    Desktop
  465. 4.02
  466.    <Return>
  467. 4.02
  468. this doesnæt interfere with anything already in the desktop but re-
  469. starts any of the default tasks that have been lost, namely Filer,
  470. PaletteUtil an TaskManager.  Note, however, that if you *RMKill or
  471. *RMFaster the Task Manager, you canæt get a *prompt by pressing F12!  To
  472. get around this, make up an Obey file containing the command
  473. 4.02
  474.    *Desktop
  475. 4.02
  476. and this will do the trick.  Itæs quite interesting to see the Task and
  477. Palette icons in the öwrongò place on the icon bar!  However, I feel
  478. that you should not deliberately interfere with desktop modules and this
  479. method should really be regarded as a Éget-you-homeæ technique in case
  480. of problems.  Lorcan Mongey.
  481. 4.02
  482. ÅREMming your programs Ö When writing a program, in any language, it is
  483. good practice to put plenty of comments in to remind oneself what each
  484. particular section of code does.  However, in BASIC, there are two
  485. things which tend to deter one from following this practice.  The first
  486. is that the interpreter has to recognise a REM statement before it knows
  487. to ignore it.  This takes time, which may be undesirable in procedures
  488. and loops.  The second deterrent is the amount of space taken by the
  489. text of the comment, which is stored verbatim in the program.
  490. 4.02
  491. I have a practice, when commenting procedures and functions, of placing
  492. explanatory comments outside the procedure/function block.  For
  493. instance:
  494. 4.02
  495.    program segment missing
  496. 4.02
  497. Clearly, the above practice prevents the REM statements from impacting
  498. the performance of the procedure/function, as they are in section of the
  499. code which the interpreter will never see.
  500. 4.02
  501. This last observation leads to an additional possibility for interpreted
  502. code (but not for compiled BASIC).  Since the interpreter never sees
  503. these lines between procedure/function blocks, the normal syntax rules
  504. can be broken without an error being generated.  Thus, we can save some
  505. space, as well as execution time, by omitting the REM key words.  Note
  506. that this will only work if the comments are where the interpreter
  507. cannot see them.  If you are in the habit of using GOTO statements
  508. (sometimes a handy way of removing umpteen layers of IF... THEN... ELSE
  509. statements if you are checking for exceptions and, despite common
  510. Éwisdomæ, still used frequently by professional programmers), this
  511. placing of syntactically incorrect code beyond the bounds of a procedure
  512. block might allow the trapping of such errors as omitting the ENDPROC or
  513. = statements.  David Hazel.
  514. 4.02
  515. Å Star LC10 Ö An undocumented feature on a Star LC10 Colour Printer, is
  516. that if you open out a file to the printer and try and print characters
  517. 27 and 102 to it, it prints out the current dip switch setting:
  518. 4.02
  519.    program segment missing
  520. 4.02
  521. Jason Ede.
  522. 4.02
  523. Å System Variables (continued from 4.1 p9 & 4.1 p10) Ö I had had similar
  524. problems and came up with a different solution which can solve both
  525. problems, i.e. reading system variables to BASIC and passing system
  526. variables to the Filer module.  I use a call to OS_EvaluateExpression,
  527. which can return a numeric or string value, as follows:
  528. 4.02
  529.    program segment missing
  530. 4.02
  531. This is an artificial example; in practice you would know whether you
  532. were expecting a numeric value or a string, such as Obey$Dir.  Lorcan
  533. Mongey.
  534. 4.02
  535.  
  536. Å Basic Text File Type Ö Acorn have specified field type &FD1 for BASIC
  537. ASCII text.  This is very useful for BASIC programs which are kept in
  538. !Edit format as it allows the user to define a RunType for them.  For
  539. example, the following command will cause a BASIC text file to be run
  540. just like a normal BASIC file:
  541. 4.03
  542.    *Set Alias$@RunType_FD1 Basic-quit |ö%0|ò %*1
  543. 4.03
  544. Jim Markland, Cirencester.
  545. 4.03
  546. Å Converting old Arthur programs to RISC OS Ö Before the days of RISC-
  547. OS, programs running under the old Arthur used a form of reconfigure
  548. system to adjust the CMOS RAM settings.  Now that RISC-OS is available,
  549. those programs are out of date, and are a pain, as in most cases they
  550. donæt öBoot-Upò from the desktop.
  551. 4.03
  552. RISC-OS uses a different form of reconfiguring.  Two in fact Ö one is
  553. the WimpSlot command, which tells the computer the minimum and maximum
  554. amount of memory the program is going to need and the other uses the
  555. module MemAlloc, found in the !Lander directory on Application disc 2.
  556. 4.03
  557. These two things are quite easy to use.  The only problem is how to find
  558. out how much room the program is going to use.  This can be discovered
  559. fairly easily.
  560. 4.03
  561. Load up the !Boot file and examine it using the BASIC Editor.  What you
  562. are looking for are a set of commands/variables, which tell the computer
  563. the amount of SpriteSize/Screensize, etc it is going to need to run.  To
  564. convert this, all you need is the MemAlloc module, and in a run file,
  565. use MemAlloc to allocate the memory needed for the application.
  566. 4.03
  567. Here are some examples:
  568. 4.03
  569. Holed Out
  570. 4.03
  571. 1. Format a fresh new disc
  572. 4.03
  573. 2. Create a new directory called !HoledOut
  574. 4.03
  575. 3. Copy all the files on the original Holed Out disc, except the !Boot
  576. file into the new directory.
  577. 4.03
  578. 4. Copy MemAlloc into the !HoledOut directory.
  579. 4.03
  580. 5. Use !Edit to create the following Obey file:
  581. 4.03
  582.    program segment missing
  583. 4.03
  584. 6. Load HoledOut 2 into the BASIC Editor and, where the program loads a
  585. particular file, change it to
  586. 4.03
  587.    (LoadCommand) <HoledOut$Dir>. (File to be loaded)
  588. 4.03
  589. for example
  590. 4.03
  591.    70 *RMLOAD BELL
  592. 4.03
  593. change to
  594. 4.03
  595.    70 *RMLOAD <HoledOut$Dir>.Bell
  596. 4.03
  597. and
  598. 4.03
  599.    610 CHAIN öHOLEDOUT3ò
  600. 4.03
  601. change to
  602. 4.03
  603.    610 CHAIN  ö<HoledOut$Dir>.HOLEDOUT3ò
  604. 4.03
  605. etc, etc.
  606. 4.03
  607. 7. Do the same as above to the file HOLEDOUT3, wherever the program
  608. loads a particular file, put the command<HoledOut$Dir>. in front of the
  609. filename.
  610. 4.03
  611. 8. Create a !Sprite file for the application icon and away you go!
  612. 4.03
  613. Then HoledOut should run as a RISC-OS application, and will also run off
  614. a Hard Drive (N.B. I used Holed Out Extra Courses 1)
  615. 4.03
  616. Explanation of !Run File:
  617. 4.03
  618. Line 1:  Tells the computer to set a directory, and to enter it without
  619. changing the root directory whenever the <HoledOut$Dir> command is used.
  620. 4.03
  621. Line 2:  Allocates the minimum and maximum amount of memory needed to
  622. run the application.
  623. 4.03
  624. Line 3:  Tells the computer to look for the module MemAlloc in memory,
  625. if it isnæt found then it tells the computer where to find it and loads
  626. it.
  627. 4.03
  628. Lines 4-9:  Tell the computer the memory settings the program needs.
  629. 4.03
  630. Line 10:  Kills the module MemAlloc for more memory.
  631. 4.03
  632. Line 11:  Runs the actual program.
  633. 4.03
  634. Pacmania:
  635. 4.03
  636. In this case, things are a little different.  So do the following:
  637. 4.03
  638. 1.  Format a new disc.
  639. 4.03
  640. 2.  Create a new directory called !PacMania.
  641. 4.03
  642. 3.  Copy all the files except !Boot into the new directory.
  643. 4.03
  644. 4.  Use !Edit to create an Obey file containing the following...
  645. 4.03
  646.    Set PacMania$Dir <Obey$Dir>
  647. 4.03
  648.    Run <PacMania$Dir>.!RunLoad
  649. 4.03
  650. 5.  Use the BASIC Editor to create a file called !RunLoad...
  651. 4.03
  652.    10 *Load <PacMania$Dir>.PacMania 10000
  653. 4.03
  654.    20 CALL &100000
  655. 4.03
  656. 6.  Create an application !Sprite file.
  657. 4.03
  658. PacMania should then run as a RISC-OS application.
  659. 4.03
  660. So there we are, Iæve also used another command to help with the loading
  661. process.  <Obey$Dir> and <(Application name)$Dir>.  These two commands
  662. tell the computer where to find certain files, no matter where they are. 
  663. (Hidden in directories on a hard drive for example.)  Duncan Burbidge.
  664. 4.03
  665. Å Getting Taxan 795 to work with Archimedes.  The Taxan 795 is an
  666. excellent multi-sync colour monitor, but it was a bit unnerving, on
  667. unpacking and assembling my new A440 with VIDC Enhancer and 795 monitor,
  668. to be confronted with a screen which just would not synchronize!  But,
  669. with help from Paul and from Atomwide, and with a lot of exploration, I
  670. think that I now know what screen modes it will support and how to get
  671. them.
  672. 4.03
  673. Initially, the trick is to set *CONFIGURE MONITORTYPE 1 and *CONFIGURE
  674. WIMPMODE20.  Then the machine wakes up in the desktop in mode 20 whether
  675. or not the VIDC enhancer software (VIDCmodes for the 795) is installed,
  676. provided that (if it is not installed) the VIDC switch is Éoffæ. 
  677. However, if VIDCmodes is not installed, loading an application which
  678. changes the mode to one of the basic Archimedes modes (0-17) plunges you
  679. back into an unsynchronized screen.  Therefore, my initial explorations
  680. were done with an ordinary monchrome monitor connected to the sync BNC
  681. socket, after changing two links on the circuit board Ö as explained on
  682. page 434 of the RISC-OS user guide.  Options for all Acorn and Atomwide
  683. modes (except the high-resolution mono mode 23) are listed in the
  684. accompanying table.  (See opposite.)  Bill Mapleson.
  685. 4.03
  686. Å Keywords in BASIC Ö I have found that PRINT ÉSHIFT F1æ showed a lower
  687. case underline Éaæ.  From BASIC on pressing return to ÉPRINTæ the result
  688. I found a number that looked just like TIME.  It was.  SHIFT F2 gives
  689. HIMEM and SHIFT F3 = LOWMEM.  No other Fkey gives a number, but they all
  690. act as quick entry keys for use in BASIC program writing within ARMB
  691. edit.  They must be programmed with BASIC keyword token values.
  692. 4.03
  693. I expect this is widely known but here is the list for completeness.
  694. 4.03
  695.    program segment missing
  696. 4.03
  697. Simon Anthony, Nottingham.
  698. 4.03
  699. Å Locating screen coordinates Ö When writing wimp programs (out of
  700. desktop) itæs often hard to plot things because youære not sure what the
  701. coordinates of the screen are.  Using the program below, it is possible
  702. to do this.
  703. 4.03
  704.    program segment missing
  705. 4.03
  706. I hope the program is of some use to wimp programmers.  Duncan Burbidge.
  707. 4.03
  708. Å MSDOS installation on hard disc Ö Here is a summary of the steps for
  709. getting an MSDOS partition installed onto a hard disc.
  710. 4.03
  711. 1. (This step applies only if you have an old PCEmulator, e.g. V1.20,
  712. and a V1.33 upgrade disc)
  713. 4.03
  714. (a) Read ÉReadMe2æ on the V1.33 disc.
  715. 4.03
  716. (b) Run ÉMakePCæ on the V1.33 disc.  (This copies the file !PC.Rom from
  717. the 1.20 disc to the 1.33 disc.  Although the desktop displays this as a
  718. Étextæ file, I reckon that in fact it is the emulator itself and that
  719. all the other files are concerned with preparing the Archimedes to run
  720. the Emulator.)
  721. 4.03
  722. 2.  Read ÉReadMeæ on V1.33 but donæt take too much notice of it Ö it
  723. confused me a lot!
  724. 4.03
  725. 3.  Examine the files !PC.GenBoot.! Config and !PC.GenBoot.!Modules.  If
  726. you have more than 1M of RAM, it may be worth changing some of the ÉYæs
  727. to æNæs in !Config.  When I first tried it, without any changes, my
  728. screen went blank because my Taxan 795 monitor requires the VIDC
  729. Enhancer and the VIDCmodes software installed in order to synchronize
  730. when not in modes 18-21.  With a 4M machines, I decided to make all the
  731. response ÉNæ and everything seemed OK.
  732. 4.03
  733. 4.  If you have a SCSI hard disc (as I have), run !SCSIDisk.  This
  734. renames !PC.SCSIRun2 to !PC.!Run2 and !PC.!Run2 to !PC.!ADSF[sic]Run2. 
  735. That is, it makes !Run2 the file that defines where the MSDOS partition
  736. is to be placed Ö on a SCSI hard disc not on an ADFS one.  !SCSIDisk
  737. then creates a file ÉPC.Drive_Cæ on the SCSI disc of the size you
  738. request (1 to 32M).  This file can be *TYPEd from the Archimedes command
  739. line Ö but donæt do it until everything is complete because its contents
  740. misled me!  The screen then displays information for running two MSDOS
  741. commands:  FDISK and HDINSTAL.  It also displays the injunction ÉPress
  742. ESCæ to stop:  Press RETURN to continueÉ.
  743. 4.03
  744. 5.  If you press <return>, the instructions are cleared from the screen;
  745. the PC Emulator is loaded, and you are invited to put the MSDOS boot
  746. disk into ÉDriveAæ (Drive0).  Doing so, and pressing <return>, loads
  747. MSDOS which asks for date and time Ö but pressing <return> in response
  748. to each request supplies the information from the system clock.  When
  749. the ÉA>æ prompt appears, you need to carry out the instructions that
  750. were recently wiped off the screen:  Type ÉFDISKæ, then É1æ to create a
  751. DOS partition, then ÉYæ to assign all of file Drive_C to DOS: then
  752. ÉHDINSTALæ which formats the hard disc and transfers the MSDOS system
  753. files from the floppy MSDOS boot disc to the hard disc.
  754. 4.03
  755. 6.  If you press ESC (at the ÉESC to stop, <return> to continueæ
  756. injunction) and need to run !SCSIDisk again, beware that this will re-
  757. rename the !Run2 files.  I avoided this by ÉRemmingæ the *rename
  758. statements in !SCSIDisk.!RunImage.  (This is a BASIC program from which
  759. it would appear that the procedure for installing MSDOS on an ADFS hard
  760. disc would be the same without the complication of renaming the !Run2
  761. files.)
  762. 4.03
  763. 7.  Once MSDOS is safely on the hard disc, the !PC application can be
  764. transferred from the V1.33 disk to the PC directory on the hard disk.
  765. 4.03
  766. 8.  One last complication fo me was that when I type ÉHDINSTALæ I go the
  767. quaint message Éinsert new diskette in drive Cæ and, on pressing
  768. <return>, Édrive not read Ö format failureæ.  Eventually, after many
  769. hours and several phone calls, the explanation turned out to be that I
  770. have two external 5.1/4ö drives and MSDOS was seeing the second of these
  771. as Drive C and the SCSI hard disc as Drive D.  To avoid amending
  772. HDINSTAL (which is a simple batch file) I told RISC-OS that it had only
  773. two floppy drives (*CONFIGURE FLOPPIES 2, followed by <ctrl-break>) and
  774. all went smoothly.  Subsequently I reconfigured to three floppies and
  775. now MSDOS wakes up with a ÉD>æ prompt ready to run from the hard disc. 
  776. The most useful tool for finding out what MSDOS thinks it has is to type
  777. CHKDSKA:.CHKDSKB: etc,
  778. 4.03
  779. 9.  Finally, in RISC-OS, lock the ÉDrive_Cæ file.  Iæm astonished that
  780. this is not done by the PCEmulator programs.  Without it, a careless
  781. click in RISC-OS might destroy all your MSDOS files!  Bill Mapleson.
  782. 4.03
  783. Å Saving your configuration settings Ö I recently needed to change the
  784. batteries in my Archimedes but this meant that I would lose the
  785. configuration settings stored in the CMOS RAM.  I managed to solve the
  786. problem by writing two small programs that saved and then restored the
  787. CMOS RAM settings to and from a file.
  788. 4.03
  789.    program segment missing
  790. 4.03
  791. Sham Gardner, Karlsruhe (Germany).
  792. 4.03
  793. (The other way of doing it is to open the computer, switch the computer
  794. on, change the batteries, switch off and then put the computer back
  795. together again Ö but I dare not suggest that you should do that because
  796. someone might stick a screwdriver into the heavily protected p.s.u. and
  797. Iæd get blames Ö so I didnæt suggest it, OK? Ed.)
  798. 4.03
  799. Å Wimpslotting warning.  Always give the maximum amount of memory your
  800. program is going to use.  Otherwise, the computer will eat up all the
  801. available memory and use it for the program and you canæt get the memory
  802. back unless you quit the application!  This happens in FormEd (All
  803. versions, I would assume).  The FormEd !Run file contains the line:
  804. 4.03
  805.    WimpSlot -min 288k
  806. 4.03
  807. Using !Edit, change this line to...
  808. 4.03
  809.    WimpSlot -min 288k -max 288k
  810. 4.03
  811. The program will then run, using up less memory, meaning that both
  812. !FormEd and !Paint can run at the same time on a 1M machine.  You have
  813. been warned.  Duncan Burbidge.
  814. 4.03
  815.  
  816. Å Cheats Ö Here are some cheats for various games.  (I suggest that if
  817. you do any of these, you do not use the original disc, but rather work
  818. on a copy.  Ed.)
  819. 4.04
  820. Cheat for Minervaæs BattleTank  If you run the following program you
  821. will have however many lives you specified at line 20:
  822. 4.04
  823.    program segment missing
  824. 4.04
  825. Cheat for 4th Dimensionæs Inertia - Type in the following and then each
  826. time you lose a life, you wonæt!
  827. 4.04
  828.    program segment missing
  829. 4.04
  830. Cheat for 4th Dimensionæs Man-At-Arms Ö The passwords for the 3 stages
  831. are: INCUBUS, STRANGE and PULSARS
  832. 4.04
  833.    progam segment missing
  834. 4.04
  835. When you run this program, it will allow you loads of lives, punches and
  836. lots of energy.  Be careful not to set any of the variables at &FF
  837. because it does tend to make the program crash!
  838. 4.04
  839. Cheat for Minervaæs RedShift Ö Once the game has loaded, type the
  840. following:
  841. 4.04
  842.    PHASING GERALD
  843. 4.04
  844. Note:  When you pressed <11>, the screen will change to the Help screen. 
  845. Take no notice of this and keep typing the rest of the words in. 
  846. Remember that there is a space between the two words!
  847. 4.04
  848. If you have entered this correctly, you will hear a bleep.  Then just
  849. press <1> or <2> to play the game and when your Energy is low just press
  850. <E> and youæll see the energy level is full again!  Also, when your
  851. TurboEnergy is low press <T> and you will be back to full strength!
  852. 4.04
  853. Cheat for 4th Dimensionæs E-Type Ö The following will give you as many
  854. minutes as you like to get round each track:
  855. 4.04
  856.    program segment missing
  857. 4.04
  858. Type in the above and youæll have all the time you want to round each
  859. track!  Mark Faulkner.
  860. 4.04
  861. Å DOS RAM Disc Ö In DOS, it is possible to set up a RAM disc and indeed,
  862. for many applications, it is vital to do so if one does not have the
  863. luxury of a hard disc.  Regular DOS supports a maximum of 640 kbytes of
  864. RAM, although we did learn about Extended Memory in last monthæs
  865. Archive.  The problem with a DOS RAM disc is that the memory is actually
  866. taken from the 640k system RAM.  At least it certainly is with current
  867. versions of the PC Emulator.
  868. 4.04
  869. A few months ago, an application appeared on the magazine disc called
  870. !PCRamDisc.  This made use of the fact that the PC emulator can support
  871. up to two öhard discò partitions and that one of these could be in the
  872. Archimedes RAM disc filing system.  (In fact one of these can be on an
  873. ADFS floppy!).  In this way, a large RAM disc can be used within DOS
  874. which does not take anything from the regulation DOS 640k.  This seemed
  875. a really good idea and I was eager to try it out.
  876. 4.04
  877. The program which produced the DOS partition is a variation of the Acorn
  878. program to construct a hard disc partition but with the filing system
  879. and paths changed and with the allowed partition sizes also changed to
  880. more convenient values.  Having created such a partition, the !Run2 file
  881. must be modified to tell the machine where the partitions are.
  882. 4.04
  883. Then, when the emulator is run, the new ödriveò must be initialised
  884. using FDISK and then formatted using FORMAT.  This part really annoyed
  885. me as I had to do it each time I used the emulator, and I kept for
  886. getting what to do.
  887. 4.04
  888. It seemed a good idea to create a ready-formatted and initialised
  889. partition before entering the emulator.  I am sure someone could write a
  890. program to do this, but not me.  Obviously, it would be silly to store,
  891. say, a 2 megabyte partition in readiness; this is just a waste of space. 
  892. However, I discovered that an initialised, formatted, but otherwise
  893. empty DOS partition of one megabyte capacity could be compressed to just
  894. over a kilobyte using Archimedes ARC, a Public Domain file compression/
  895. decompression program written by David Pilling.
  896. 4.04
  897. On the magazine disc there is an application called !PCRamDisk (note the
  898. different spelling).  This contains a compressed but empty DOS partition
  899. which is decompressed into the RAMFS before invoking the PC emulator. 
  900. Please read the !Help file before using it as the !Run2 file of the
  901. emulator is overwritten when the application is run.  Brian Cowan.
  902. 4.04
  903.  
  904. Hints and Tips
  905. 4.5
  906. Å   ANSI C v3 on a SCSI Hard  Disc ù After some trial an error, I finally
  907. managed to install ANSI C v3 correctly on my new Oak SCSI card with 45Mb
  908. hard disc drive.  Hereæs what I had to do:
  909. 4.5
  910. First change line 3390 in the ÉInstallNetæ program which is on all three
  911. of the ANSI C discs so that it reads:
  912. 4.5
  913. 3390 DATA öADFS::0.$ò,öNET:$ò,öSCSI::SCSIDisc4.$ò
  914. 4.5
  915. Then run the öInstallHDò program from each disc and always answer ÉYæ on
  916. the overwrite options (otherwise, the back up program would stop).
  917. 4.5
  918. If you use the included !Cstart obey file, you should not É*Set 
  919. Run$Pathæ in your !boot file and you should remember to modify the
  920. !Cstart file to work with SCSI and not ADFS i.e. c$loc SCSI::4.$
  921. 4.5
  922. Atle Baardholt, Norway
  923. 4.5
  924. Å   Deskjet Plus ink cartridges, recharging Ö Further to Bill Grahamæs
  925. note in Archive 4.2 p8, Iæve found that Quinx Permanent Black works well
  926. and is probably cheaper than Art Pen Ink. You do need to be careful that
  927. you donæt inject more ink than the sponge will absorb, otherwise the
  928. mess is dreadful!  Stuart Bell, Brighton.
  929. 4.5
  930. Å   DropShip passwords Ö Passwords for DropShip are Dahlia, Gaggle, Kaunda
  931. and Nautch.
  932. 4.5
  933. Å   ExAllPlus Ö This is a non-Wimp program which was written in an attempt
  934. to catalogue my discs. It was designed for use with a single ADFS Floppy
  935. drive and a SCSI Hard disc together with a Star LC10 printer using
  936. continuous paper. Other printers may require some alteration to the
  937. coding.
  938. 4.5
  939. Most existing öExAllò and öCatAllò programs invoke the *EX and *CAT
  940. calls (!) which produce a lot of unnecessary and confusing duplication
  941. of libraries, directories etc. (I have memories of the reams of paper
  942. produced by an  öExAllò print-out of the original Archimedes Welcome
  943. disc.) To avoid this, these calls have been re-written so that, in
  944. addition to other changes, the directory headings have been reduced to
  945. path descriptions.
  946. 4.5
  947. The program will produce both screen and printed listings of either the
  948. full disc or the root directory. The various options are selected by a
  949. series of key-strokes and a default screen öExAllò routine has been set-
  950. up which can be easily customised.
  951. 4.5
  952. Use can be made of the condensed print option to produce catalogue
  953. listings eight entries wide as against the usual five. This rather
  954. spoils the screen display in this mode but it was thought useful to
  955. maintain a check on the output to the printer. When using this option to
  956. produce öEXò listings the screen display is OK and the reverse feed
  957. facility of the Star LC10 enables double column print-outs to be
  958. obtained.
  959. 4.5
  960. The öGetTypeò program is loaded in by the main öExAllPlusò code and
  961. contains all the FileType codes I have been able to find but it can
  962. easily be updated.
  963. 4.5
  964. (The listing is far too long to put in the magazine. I have put it on
  965. the monthly program disc. Ed.)
  966. 4.5
  967. Doug Tuddenham
  968. 4.5
  969. Å   First Word Plus embedded commands Ö If you switch off the Word
  970. Processor mode of FWP you can enter printer commands directly into the
  971. text.  Double bracket command codes e.g. ((n))n1 can be entered to
  972. change the printer font and style. For example, with a Star LC24-200 in
  973. the following effects can be achieved:
  974. 4.5
  975. Font   ((F))0   Times Roman
  976. 4.5
  977.       ((F))1   Sans Serif
  978. 4.5
  979.       ((F))2   Courier
  980. 4.5
  981.       ((F))3   Prestige
  982. 4.5
  983.       ((F))4   Script
  984. 4.5
  985.       ((F))5   Draft
  986. 4.5
  987. Size   ((S))0   Standard
  988. 4.5
  989.       ((S))1   Double Width
  990. 4.5
  991.       ((S))2   Double Height
  992. 4.5
  993.       ((S))3   Double Width and Height
  994. 4.5
  995. Colour   ((C))0   Black
  996. 4.5
  997.       ((C))1   Red
  998. 4.5
  999.       ((C))2   Blue
  1000. 4.5
  1001.       ((C))3   Violet
  1002. 4.5
  1003.       ((C))4   Yellow
  1004. 4.5
  1005.       ((C))5   Orange
  1006. 4.5
  1007.       ((C))6   Green
  1008. 4.5
  1009. Peter Thomas, Leics
  1010. 4.5
  1011. Å   FWP Cut and Paste Ö It is possible to cut a marked block of text in a
  1012. First Word Plus document and then paste it into another document.  Both
  1013. documents must be loaded first.  This may be obvious but I have only
  1014. just found out ù the hard way.  Dave Livsey, Devon
  1015. 4.5
  1016. Å   Impression hints & tips Ö Now that I am using Impression for the
  1017. magazine, there are likely to be a number of hints & tips forthcoming.
  1018. Some of these may be obvious to the more experienced Impression users,
  1019. but bear with me because some of us are only just beginning and, in
  1020. fact, the experiences of someone just starting to use an application can
  1021. often be very helpful to others going through the same hoop. Also, when
  1022. you have been using an application for a while, you build up the feeling
  1023. that you know how it works and there may be facilities which you never
  1024. realised were available which new users pick up. Anyway, here are the
  1025. first few...
  1026. 4.5
  1027. Adding styles to titles Ö If you want to add a style to a title, be sure
  1028. to select the whole line including the carriage return. In other words
  1029. either put the cursor by the left hand margin and drag down to the next
  1030. line or triple-click somewhere on the line. (Iæm sure you all know that
  1031. double-click selects a word, triple-click selects a line and quadruple-
  1032. click (or <ctrl-@>) selects a whole paragraph.) The reason for selecting
  1033. in this way is that if you only select by dragging across the line, you
  1034. omit the carriage return which remains in the base style. The problem
  1035. with this is that if, as in the title lines in Archive, the added style
  1036. says öreduce the space after the paragraph to zeroò, the carriage return
  1037. still has the full space-after-paragraph so the paragraph spacing
  1038. remains unchanged.
  1039. 4.5
  1040. Entering point sizes Ö If you want to change the size of some text, you
  1041. mark it and press <shift-ctrl-S>. If the dialogue box is empty, you can
  1042. type in a number, say 18, and it will assume you mean 18 point. If you
  1043. decide that you want it a bit bigger and press <shift-ctrl-S> again, it
  1044. comes up with ö18ptò in the box. If you then type in, say, 2 <return> it
  1045. will interpret the ö18pt2ò as (18+2)pt and will give you 20pt! (Well, it
  1046. works in version 2.05.) Unfortunately, if you press <-> to try to put,
  1047. say, -2, it seems to interpret it as an escape and closes the box.
  1048. 4.5
  1049. Marking, deleting and re-typing Ö (This is something that is obvious to
  1050. people coming to Impression via the Mac but may have been missed by
  1051. people brought up through RISC-OS.) If some text is marked, by any
  1052. means, and you want to replace it by some text you are about to type in,
  1053. there is no need to delete the marked text first. As soon as you start
  1054. to type, the marked text is deleted and transferred to the scrap-pad and
  1055. your typing appears in place of it. The deleted text can be used
  1056. elsewhere by pasting it in with <ctrl-V>.
  1057. 4.5
  1058. Quick searching Ö If you want to find something quickly, find/replace is
  1059. a good way to do it. Call it up with <ctrl-f4> and then, to delete the
  1060. text already in the dialogue box, press <ctrl-U>, then type in the word
  1061. you are looking for and press <return>. (This use of <ctrl-U> applies to
  1062. all dialogue boxes Ö useful when saving a document under a new name.)
  1063. Remember though that it searches from the cursor downwards, so add a
  1064. <ctrl-uparrow> before calling up the find/replace box. (In the version I
  1065. have, 2.05, the cursor is sometimes not re-displayed in its new position
  1066. after a find/replace has been executed. In other words, it appears to be
  1067. still where you left it but it may actually be further down the document
  1068. so itæs worth getting into the habit of using <ctrl-uparrow> anyway.)
  1069. Also, donæt get tripped up, as I just did. If you set the öcase
  1070. sensitiveò option, it stays set until you switch it off again. So, if
  1071. you canæt find a word that you know is in there somewhere, check that
  1072. you have not left it in the case-sensitive mode from the last time you
  1073. used it.
  1074. 4.5
  1075. Replacing double spaces Ö I was trying to do a selective search and
  1076. replace to remove double spaces and replace them with single spaces.
  1077. When I told it to find the next one, it sometimes didnæt appear to mark
  1078. anything. Most peculiar!  Eventually, I realised what was happening. The
  1079. text was fully justified and the double spaces (the same would apply to
  1080. finding single spaces) were between the last word on one line and the
  1081. first on the next line. Thus Impression was marking the infinitesimally
  1082. small space at the end of the line, i.e. was marking nothing at all.
  1083. Thereæs nothing you can do about it (apart from removing the full
  1084. justification) but at least if you are aware of the problem, you wonæt
  1085. be so baffled when it happens.
  1086. 4.5
  1087. Searching for hyphens Ö In some versions of Impression, it is not
  1088. possible to search and replace hyphens. I discovered this because, for
  1089. ease of typing, I was using a double hyphen where I wanted a dash in the
  1090. text, the idea being to replace them later. Impression refused to find
  1091. any occurrences of hyphen-hyphen. Consultation with CC revealed that
  1092. improvements in automatic hyphenation have resulted in this problem. The
  1093. way round it is to search for ÿ and replace it with Ö. Note the spaces
  1094. after the backslash and before the 45.
  1095. 4.5
  1096. Smart quotes Ö If you want smart quotes in a text, i.e. the curly ones
  1097. instead of the straight ones on the key next to the return key, you can
  1098. type them in using <ctrl-]> and <ctrl-\> for single quotes and <shift-
  1099. ctrl-]> and <shift-ctrl-\> for double quotes. However, if you think
  1100. thatæs a bit of a fag to remember, use the normal quotes and then,
  1101. before printing, save the file (just in case of operator error!), save
  1102. the text with styles (perhaps to a ram disc as itæs only temporary),
  1103. select the whole text (<ctrl-T>), delete it and finally drop the saved
  1104. text back into the document. As the text is re-loaded, quotes are
  1105. automatically Ésmartenedæ.
  1106. 4.5
  1107. Switching styles on and off Ö Those of you brought up in the Mac world
  1108. may not have realised, as I didnæt until today(!) that if you want
  1109. something in, say, bold, all you have to do is press <f4> to switch it
  1110. on, type in the bit that is to be in bold and then press <f4> again. 
  1111. Obvious? Yes, it may be to those who come new to Impression but for
  1112. those of us steeped in Mac techniques, it comes as a welcome surprise.
  1113. 4.5
  1114. If there are things about using Impression that Écame as a surpriseæ to
  1115. you, send them in to us (preferably on disc) and weæll share them with
  1116. other Impression users. We may even need an Impression Column.
  1117. 4.5
  1118. Å   Rotor and other gamesæ passwords Ö One way to obtain the Rotor
  1119. passwords (and possibly other games) is to load each of the gameæs files
  1120. into !Edit and use the ÉFindæ option to look for the first password. 
  1121. When the password is found, the remaining passwords should be in the
  1122. next couple of lines.  Andrew Campbell, Devon
  1123. 4.5
  1124. Å   Sony TV / Monitor Ö I was told by Beebug that I couldnæt use my Sony
  1125. TV as a monitor with the A3000, but in fact this is quite easy to do. 
  1126. The sony TV requires a signal on pin 16 (blanking input) of the Scart
  1127. plug, which can simply be connected to pin 20 (video input).  Keith
  1128. Raven, Slough
  1129. 4.5
  1130. Å   Z88 file transfer Ö Here is a little utility for people who wish to
  1131. transfer files from the Archimedes straight into suspended memory on the
  1132. Z88.  It saves having to break a file into smaller sections first and,
  1133. of course, there is always a memory overhead in having at least part of
  1134. the file held in the Z88 Filer.  With this BASIC program, the filer is
  1135. by-passed altogether.
  1136. 4.5
  1137.  10 REM >Suspender
  1138. 4.5
  1139.  20 REM Transfer file from Arc to Z88 suspended memory
  1140. 4.5
  1141.  30 REM ** IMPORTANT: Set z88 receive baud rate at 2400 (in panel) **
  1142. 4.5
  1143.  40 *CAT
  1144. 4.5
  1145.  50 *FX 8,5
  1146. 4.5
  1147.  60 INPUT öSend file? òfile$
  1148. 4.5
  1149.  70 *FX 3,119
  1150. 4.5
  1151.  80 OSCLI(öType ò+file$)
  1152. 4.5
  1153.  90 FOR i%=1 TO 350
  1154. 4.5
  1155. 100 PRINT ö#ò
  1156. 4.5
  1157. 110 NEXT i% : REM these pad chars are need for certain types of file
  1158. 4.5
  1159. 120 *FX 3,0
  1160. 4.5
  1161. To load a file into PipeDream, enter ö:COMò as the öName of file to
  1162. loadò in the files menu.  Then run öSuspenderò and immediately press
  1163. <return> on the Z88.  Finally, when the BASIC prompt reappears on the
  1164. Archimedes screen, press <esc> on the Z88.
  1165. 4.5
  1166. It is kinder to your disc drive to copy the target file into the
  1167. Archimedesæ RAM filing system first.
  1168. 4.5
  1169. Jonathan Barnes, Watford
  1170. 4.5
  1171. The following Hints and Tips come from Hugh Eagle of the West Sussex
  1172. Archimedes User Group.
  1173. 4.5
  1174. Å   Disappearing paragraph spaces in FWP ù If, at the end of a paragraph,
  1175. you type a space immediately before the carriage return, the carriage
  1176. return will be deleted when you subsequently reformat the paragraph.
  1177. Believe it or not, this is a öfeatureò of First Word Plus (documented in
  1178. the version 1 manual on page 110)!
  1179. 4.5
  1180. Å   Loading sprite files ù When you double click on a sprite file icon,
  1181. sometimes it is displayed at the bottom left-hand corner of a blank
  1182. screen and sometimes in a !Paint window.  This is because the action the
  1183. computer takes when you try to örunò a sprite file depends on the
  1184. contents of the system variable Alias$@RunType_FF9.  This variable is
  1185. defined by default, when the Archimedes is switched on, as öScreenLoad
  1186. %0ò.  The effect of this is that when you double click on a sprite file
  1187. (type &FF9) icon, the operating system executes the instruction
  1188. *ScreenLoad [filename]; this clears the screen and then displays the
  1189. first sprite in the file at the graphics origin. However, when the
  1190. Desktop Filer öseesò the !Paint application (i.e. when a directory
  1191. window is opened in which !Paint is included) it runs the !Paint.!Boot
  1192. file which, amongst other things, redefines Alias$@RunType_FF9  in such
  1193. a way that when a sprite file is örunò the !Paint application is started
  1194. up (that is if it is not already running) and the file is loaded in.
  1195. 4.5
  1196. Å   Listing the contents of your (hard) disk ù The operating system
  1197. command ö*Count :4.$.* RVò will catalogue the contents of the root
  1198. directory and every sub-directory.  As explained on pages 279/280 of the
  1199. User Guide, the output from this command can be redirected to the
  1200. printer by adapting the command to ö*Count :4.$.* RV {printer: } ò
  1201. 4.5
  1202. Note: the spaces around the curly brackets and the > sign are important.
  1203. 4.5
  1204. This method will redirect the output to the printer without displaying
  1205. it on the screen. An alternative method will send all text that is
  1206. displayed on the screen to the printer as well: first press <ctrl-B>
  1207. (i.e. hold down the ctrl key and simultaneously type B), then issue the
  1208. command ö*Count :4.$.* RVò then, when the listing has finished, press
  1209. <ctrl-C>.
  1210. 4.5
  1211. Å   Removing PC Access ù  The menu which appears when you click the menu
  1212. button over any of the PC Access icons on the icon bar has no Quit
  1213. option and the application doesnæt seem to appear in the Task Manager
  1214. window.  In fact, the application does appear in the Task Manager window
  1215. ... in the öModule Tasksò section. Clicking the menu button over the
  1216. applicationæs name there and moving to the Task ÉPC Accessæ sub-menu
  1217. gives a öQuitò option.
  1218. 4.5
  1219. Å   Printing via a PC ù For some time I have been perplexed to find that
  1220. when I try to print a file created by the Archimedes !PrinterLJ printer
  1221. driver to a LaserJet printer attached to a PC, the printout stops part
  1222. way down the page. At first I thought it must be because of  limited
  1223. memory in the printer so I tried creating the file at a lower print
  1224. density but this made no difference to how much of the page was printed.
  1225. 4.5
  1226. I think I have now hit on the answer, namely that, when using the MS-DOS
  1227. Copy command to print a file which includes control codes, it is a good
  1228. idea to use the /b öswitchò, using the syntax:
  1229. 4.5
  1230. copy [filename]/b LPT1
  1231. 4.5
  1232. The insertion of /b after the filename causes MS-DOS to copy in öbinaryò
  1233. mode: i.e. it copies as many bytes as there are in the file. Otherwise,
  1234. in text mode, copying will continue only until the first end-of-file
  1235. marker (Ctrl-Z or ASCII character 26) is reached whereupon it will stop.
  1236. It is of course highly likely that a graphic printfile of many thousands
  1237. of bytes will contain this character several times, so it is not
  1238. surprising that only part of the page is printed!
  1239. 4.5
  1240. Å   Viewing !Draw files ù The standard way to view a draw file is to load
  1241. it into !Draw. However, this has an irritating tendency to place the
  1242. part of the picture you want to see outside the visible window. There
  1243. are (at least) two convenient ways of avoiding this problem:
  1244. 4.5
  1245. One is to load the file into the !Display application from Shareware 26.
  1246. The other is to load it into an Impression frame (or, presumably, a
  1247. frame in one of the other DTP applications). In either case, the drawing
  1248. is scaled to fit the frame (the aspect ratio is preserved, so the
  1249. picture fills either the height of the frame or the width). One
  1250. advantage of Impression is that the frame can very easily be resized and
  1251. the drawing thereby magnified; another is that it makes it very simple
  1252. to display a number of drawings on a page and create an illustrated
  1253. catalogue.
  1254. 4.5
  1255. Å   Floppy disc E format ù So far as I know, the detailed format of ADFS
  1256. discs has not been published either in any of the manuals or in Archive.
  1257. Having recently deleted some files by mistake and been forced into some
  1258. detective work in order to recover them, I thought it might be helpful
  1259. to write down what I have found out about öEò format floppy discs:ù
  1260. 4.5
  1261. With two sides, 80 tracks on each side, 5 sectors on each track, the
  1262. disc has 800 sectors of 1024 (&400) bytes each. The sectors can be
  1263. thought of as being numbered from 0 to 799 in the following order:
  1264. 4.5
  1265.    Track   Head   Sector
  1266. 4.5
  1267.        0       0       0
  1268. 4.5
  1269.        0       0       1
  1270. 4.5
  1271.        0       0       2
  1272. 4.5
  1273.        0       0       3
  1274. 4.5
  1275.        0       0       4
  1276. 4.5
  1277.        0       1       0
  1278. 4.5
  1279.        .       .       .
  1280. 4.5
  1281.        0       1       4
  1282. 4.5
  1283.        1       0       0
  1284. 4.5
  1285.        .       .       .
  1286. 4.5
  1287.        .       .       .
  1288. 4.5
  1289.       79       1       4
  1290. 4.5
  1291. Each byte on the disc has a ödisc addressò equal to the sector number,
  1292. as defined above, times &400 plus the number of bytes into the sector.
  1293. Put it another way:
  1294. 4.5
  1295. the disc address    =   (((( track * 2 ) + head ) * 5 ) + sector ) *
  1296. &400 + bytes into sector
  1297. 4.5
  1298. Map format Ö The first two sectors on the disc contain duplicate copies
  1299. of the disc map. The first 64 bytes of the map contain the following
  1300. information:
  1301. 4.5
  1302. byte  0   a checksum byte
  1303. 4.5
  1304. bytes 1/2   the number of bits to the place in the map which marks the
  1305. first free space on the disc, counting from the beginning of byte 1 (if
  1306. there is no free space this number will be zero); the top bit of the 16
  1307. is always set, so, for instance, the value &8310 in these two bytes
  1308. would indicate that the first free space in the map could be found &310
  1309. bits or &310 DIV 8 bytes from byte 1, i.e. at byte &63
  1310. 4.5
  1311. byte  3   &FF
  1312. 4.5
  1313. bytes 4-35   the ödisc recordò as described on pages 1012/3 of the PRM
  1314. containing various details about the disc size, etc. which are the same
  1315. on all öEò format discs, ending with the Disc ID at bytes 24/5 and the
  1316. disc name from byte 26 to byte 35.
  1317. 4.5
  1318. bytes 36-63   reserved (all zero)
  1319. 4.5
  1320. bytes 64-863 (800 bytes) ù the actual disc map.
  1321. 4.5
  1322. Each byte in the map represents one disc sector and the contents of the
  1323. map indicate how the disc is divided up between the various objects
  1324. (directories and files) on it. Each portion of the map is at least 2
  1325. bytes long, it begins with an identifying number (max. 15 bits), ends
  1326. with a 1 in the top bit of the last byte and all the bits in between are
  1327. zero. Thus, for instance, if the file with the identifying number 7
  1328. occupies 3 sectors the relevant portion of the map reads as follows:
  1329. 4.5
  1330. first byte   &07
  1331. 4.5
  1332. next byte   &00
  1333. 4.5
  1334. last byte   &80  (1 in the top bit)
  1335. 4.5
  1336. The lowest identifying number is 2 and is reserved for the four sectors
  1337. which are initialised when the disc is formatted and which comprise the
  1338. two map sectors followed by the two sectors containing the root
  1339. directory. Identifying numbers are then allocated, in order, as new
  1340. objects are created.
  1341. 4.5
  1342. A file may be fragmented into several pieces, in which case several
  1343. portions of the map will contain the same identifying number.
  1344. 4.5
  1345. The portions of the map indicating free space on the disc are linked
  1346. together by a chain of pointers. As mentioned above, bytes 1 and 2, at
  1347. the start of the map sector, point to the first free space in the map.
  1348. At that point there is a similar pointer to the next free space (if any)
  1349. and so on until the last free space is reached, where the pointer is
  1350. zero.
  1351. 4.5
  1352. A defective sector on the disc is identified in the map by number 1.
  1353. 4.5
  1354. Directory structure Ö Each directory takes up two sectors. As mentioned
  1355. above, the root directory occupies the third and fourth sectors on the
  1356. disc (from disc address &800 to &FFF). Any sub-directory can be located
  1357. by looking up the relevant entry in its parent directory, finding the
  1358. identifying number (in the manner described below) and looking up the
  1359. number in the disc map.
  1360. 4.5
  1361. The first five bytes in a directory contain a checksum byte followed by
  1362. the string öNickò. Then there are up to 77 entries of 26 bytes each
  1363. representing the various objects (files and sub-directories) in the
  1364. directory.
  1365. 4.5
  1366. The format of each of these entries is:
  1367. 4.5
  1368. bytes  0-9   name of file or sub-directory
  1369. 4.5
  1370. bytes 10-13   load address
  1371. 4.5
  1372. bytes 14-17   execution address
  1373. 4.5
  1374. bytes 18-21   file length
  1375. 4.5
  1376. byte  22   sector offset (see below)
  1377. 4.5
  1378. bytes 23-24   identifying number as used in the map
  1379. 4.5
  1380. byte  25   file attributes.
  1381. 4.5
  1382. If the top 12 bits of the load address are all set (i.e. are &FFF) this
  1383. means that the file is östampedò and the remainder of the load and
  1384. execution address fields are used to record the file type and date stamp
  1385. as follows:
  1386. 4.5
  1387. load address      FFFtttdd
  1388. 4.5
  1389. execution addressdddddddd
  1390. 4.5
  1391. (the bottom byte of the load address field being used for the top byte
  1392. of the 5-byte format date and time record).
  1393. 4.5
  1394. Note: in a disc sector editor which shows the bytes in order with the
  1395. lowest byte of each word first, these 8 bytes will appear as   ödd tt Ft
  1396. FF dd dd dd ddò.
  1397. 4.5
  1398. If not all the top 12 bits are set, the load and execution addresses
  1399. will (as their names suggest) determine what the computer does when the
  1400. file is *LOADed or *RUN (or double-clicked from the Desktop).
  1401. 4.5
  1402. The sector offset in byte 22 is used where two files are mapped into the
  1403. same portion of the disc. In such a case the files share the same
  1404. identifying number (in bytes 23/4) but byte 22 indicates how many
  1405. sectors into the portion each file starts.
  1406. 4.5
  1407. A typical example of this would involve two small files each fitting
  1408. into one disc sector (they might for instance be !Boot, !Run or !Sprites
  1409. files within an application directory). Because the minimum size of a
  1410. map entry is 2 bytes representing 2 sectors on the disc, it would be
  1411. inefficient to give each file a separate map entry, so the two files
  1412. would be made to share. In this case, assuming the shared identifying
  1413. number is say 8, bytes 23 and 24 of the directory entries for both files
  1414. would be &08 and &00 but byte 22 would be &01 for the file that occupies
  1415. the first sector and &02 for the second.
  1416. 4.5
  1417. In the usual situation where a file has a map entry to itself, byte 22
  1418. is zero.
  1419. 4.5
  1420. The bits of byte 25 (the file attributes byte) are used as follows:
  1421. 4.5
  1422. bit  0   object has read access for you
  1423. 4.5
  1424. bit  1   object has write access for you
  1425. 4.5
  1426. bit  2   undefined
  1427. 4.5
  1428. bit  3   object is locked against deletion
  1429. 4.5
  1430. bit  4   object has read access for others
  1431. 4.5
  1432. bit  5   object has write access for others
  1433. 4.5
  1434. bit  6   undefined
  1435. 4.5
  1436. bit  7   undefined
  1437. 4.5
  1438. Bits 4 and 5 only have meaning to the network filing system. Bits 2, 6
  1439. and 7 should be set to zero.
  1440. 4.5
  1441. General note: If you want to explore disc maps and directories it is
  1442. very handy to have a disc sector editor such as the !DiscEdit appli
  1443. cation on Careware 2. Failing that it is reasonably easy to construct a
  1444. program to read from a disc sector by sector (rather than file by file)
  1445. and to display the contents. The key to such a program is the SWI call
  1446. öADFS_DiscOpò. For instance, the BASIC instruction:
  1447. 4.5
  1448. SYS öADFS_DiscOpò,0,1,address%,buffer%,length%
  1449. 4.5
  1450. will read starting at the ödisc addressò (as defined above) given in the
  1451. variable address%, the number of bytes given in length% (1024 for one
  1452. sector) into the address in RAM stored in buffer%. Obviously, a certain
  1453. amount of caution is advisable since a very similar command (replacing 1
  1454. with 2 for instance) could result in writing to and corrupting the
  1455. contents of a disc.
  1456. 4.5
  1457.  
  1458. 4.5
  1459.  
  1460. 4.5
  1461. {4 .5
  1462. Å   Caverns Ö A simple map and the passwords are given at the end of the
  1463. magazine on page 60. Neil Berry
  1464.  
  1465. Impression Hints and Tips
  1466. 4.6
  1467. Here are a few more hints and tips mostly from the editoræs dabblings in
  1468. preparing the magazine...
  1469. 4.6
  1470. Å   Dashes Ö If you, like me, donæt like to see hyphens used where dashes
  1471. should be used Ö i.e. in places like this Ö you will probably be sick
  1472. and fed up of typing <alt-153>. (Note that the character in öalt-153ò is
  1473. a hyphen, just in case you werenæt aware of the difference.) If you are
  1474. importing text into Impression, occurrences of Éhyphen hyphenæ will be
  1475. converted automatically by Impression into a long dash ÿ see what I
  1476. mean. Personally, I prefer the shorter one so what I have done is set up
  1477. the abbreviation dictionary with Éexpand as you typeæ and used an
  1478. underline character to be turned into a dash. The only drawback is that
  1479. itæs OK for things like the dashes earlier in this paragraph, but if,
  1480. for example, you use dashes in phone numbers, as 0603Ö766592, the
  1481. abbreviation technique does not work and you are back to  <alt-153>.
  1482. Anyone any other ideas?
  1483. 4.6
  1484. Å   Find styles Ö If you want to find a style, get up the find/replace box
  1485. with <ctrl-f4> and then click in the menu box to the right of the Find
  1486. box and select the style you are looking for. This will come up as, say,
  1487. öò. Type an ö@ò after this Ö which stands for öany textò Ö and then
  1488. press <return>. This will highlight the whole of the first piece of text
  1489. with that style or effect. Unfortunately, the facility to replace that
  1490. style with another style is not yet working. If you do want to do any
  1491. search and replace on the style names, export the text, with styles, and
  1492. then use another WP such as !Edit to do the searching and replacing
  1493. before returning it to Impression.
  1494. 4.6
  1495. Å   Rogue effects Ö Someone sent me a file in which they had used a
  1496. particular font which I did not have so when I loaded the file,
  1497. Impression told me it was changing it to Trinity.medium. I did an edit-
  1498. style and looked at all the style definitions to no avail. Eventually, I
  1499. realised that it must have been used as an effect, so how was I to find
  1500. it and eliminate it or change it to some font I did possess? Because the
  1501. font had been changed to Trinity.medium (i.e. the BaseStyle font) I
  1502. could not pick it out with a visual scan so the first idea was to change
  1503. the BaseStyle to, say, Zapf.Dingbats so that anything which was in a
  1504. different font was obviously an effect or a style. Unfortunately, this
  1505. didnæt reveal the offending effect. At this point, I became convinced
  1506. that I had a non-existent, un-removable effect, i.e. a bug in Impres
  1507. sion. So I sent the offending file to CC who informed me that the
  1508. particular effect WAS in the text and they also showed me how to locate
  1509. it... as follows...
  1510. 4.6
  1511. (Actually, the reason that I couldnæt find the effect was that I had
  1512. already gone through the document adding extra styles and had covered
  1513. this rogue font-change effect with a font-change style of my own. In
  1514. other words, the style, because it was applied later than the effect,
  1515. took precedence.)
  1516. 4.6
  1517. Å   Finding effects Ö In the same way that you can find styles (see above)
  1518. you can also find effects as long as you tell Impression that you want
  1519. effects to be shown on the style menu. To do this, locate the file öUKò
  1520. in the Impression öResourcesò directory. Load it into !Edit and find
  1521. öCnf1:ò and change it to öCnf1:Eò Ö thatæs a one, not a letter ölò. Save
  1522. the file and shut down and re-start Impression. You then will have
  1523. effects on your style menus and search on {öeffectnameò }@, as explained
  1524. above.
  1525. 4.6
  1526. Å   Fast search and replace Ö There are a couple of very useful keyboard
  1527. short-cuts not documented in the manual which speed up the search and
  1528. replace. When the ötext foundò box is on screen, <ctrl-R> does a
  1529. öReplaceò and <ctrl-N> moves to the öNextò.
  1530. 4.6
  1531. Å   Keyboard short-cuts Ö Apart from the ones listed on pages 119ff of the
  1532. Impression manual, here are a few more: (some are mentioned on the menu,
  1533. but not in manual)
  1534. 4.6
  1535. <ctrl-shift-D> go to chapter
  1536. 4.6
  1537. <ctrl-shift-H> produces a bullet i.e. a öÅò.
  1538. 4.6
  1539. <ctrl-shift-I> also produces a bullet i.e. a öÅò!
  1540. 4.6
  1541. <ctrl-shift-J> produces superscript
  1542. 4.6
  1543. <ctrl-shift-K> produces subscript
  1544. 4.6
  1545. <ctrl-shift-T> save text story
  1546. 4.6
  1547. Å   Page number justification problems Ö Some of you may have had
  1548. difficulty getting correct centring or right justification of page
  1549. numbers on footers. This is corrected in version 2.09 Ö well, almost!
  1550. The footers on right hand pages were wrong last month, when I was using
  1551. version 2.05, (in fact I didnæt even notice!) and the footers on the
  1552. left hand pages would have been wrong this month (with 2.09) if I had
  1553. not found a way round it. If you try to have left aligned page number
  1554. with a right tabbed piece of text, the text suffers a left shift. Iæve
  1555. solved it for now by splitting the footer text into two separate frames,
  1556. one left aligned and the other right aligned. Itæs messy, but it works. 
  1557. A
  1558. 4.6
  1559.  
  1560. Hints and Tips
  1561. 4.7
  1562. Å   Ballarena Ö I would advise using the mouse to control your Ébatæ
  1563. because the keyboard is not very responsive. Also, note that the ÉAutoæ
  1564. bat does not always respond fast enough to catch the ball, and there is
  1565. nothing you can do about it! I was very disappointed in the final
  1566. message which just congratulates you, and ends your game. The passwords
  1567. are: PUNKANDJUMP, MONTPELLIER, SEA SEX SUN, VL 86 C 010, MOUNTAINEERS,
  1568. GRENOUILLE, BLUBEDILOMAR, BRAIN KILLER, RHYTHM BOX, BOUBOULOID, MENFOU,
  1569. 32 BIT POWER, MARTINI, SEE YOU SOON, ETERNA. Mike Gregory (& Russell
  1570. Lamb).
  1571. 4.7
  1572. Å   Changing !Editæs default file types Ö Answering my own Help!!! plea in
  1573. Archive hereæs how to change the default filetypes for !Edit:
  1574. 4.7
  1575. *DIR ADFS::4.$.RISC-OS.!Edit
  1576. 4.7
  1577.  (or your path here)
  1578. 4.7
  1579. *GOS
  1580. 4.7
  1581. *L. !RUNIMAGE 8000
  1582. 4.7
  1583. *BREAKSET 8004
  1584. 4.7
  1585. *GO 8000
  1586. 4.7
  1587. *SAVE ö!RUNIMAGEò 8000+1F2C0
  1588. 4.7
  1589.  8008 8000
  1590. 4.7
  1591. *BASIC
  1592. 4.7
  1593. *L. !RUNIMAGE 8F00
  1594. 4.7
  1595. $&1B208=öReadMeò These can be changed
  1596. 4.7
  1597. $&1B214=öDataFileò to suit your needs
  1598. 4.7
  1599. $&1B220=öExecFileò with any string up
  1600. 4.7
  1601. $&1B22C=öEditFileò to 10chars in
  1602. 4.7
  1603. $&1B238=ö!Runò        length.
  1604. 4.7
  1605. *SAVE !RUNIMAGE 8F00+1F2C0 8008 8000
  1606. 4.7
  1607. Rob Davison, Southland, New Zealand
  1608. 4.7
  1609. Å   ÉCheapoæ dialog boxes Ö You can make use of Wimp_ReportError instead
  1610. of writing code for a dialog box when programming wimps. The following
  1611. code fragment is an example:
  1612. 4.7
  1613. DEFPROCsave_file(name$)
  1614. 4.7
  1615. IF FNfile_there(name$) THEN IF
  1616. 4.7
  1617.  FNdialog(öA file of that
  1618. 4.7
  1619. name exists. Overwrite it?ö)=FALSE THEN ENDPROC
  1620. 4.7
  1621. REM save file
  1622. 4.7
  1623. ENDPROC
  1624. 4.7
  1625.  
  1626. 4.7
  1627. DEFFNdialog(str1$):!block%=1
  1628. 4.7
  1629. :$(block%+4)=str1$
  1630. 4.7
  1631. SYSöWimp_ReportErrorò,block%,
  1632. 4.7
  1633. 19,öMessage from
  1634. 4.7
  1635. applicö TO ,resp%
  1636. 4.7
  1637. =resp%=1
  1638. 4.7
  1639. where the string öMessage From Applicationò is <20 characters in length.
  1640. 4.7
  1641. The only disadvantages are that all other desktop activity is suspended,
  1642. the machine beeps (if wimpflags bit 4 is not set) and that the user has
  1643. to answer öOKò or öCANCELò instead of the more logical öYESò or öNOò.
  1644. However, this saves a great deal of programming and can be very useful
  1645. at times (This is why FWP2 stops printing Ö See Archive 3.10 p 25). Rob
  1646. Davison, New Zealand.
  1647. 4.7
  1648. Å   Cleaning A310 keyboard contacts Ö I recently had a very nasty
  1649. intermittent fault on my A310. It began as a line of 222222222æs being
  1650. printed at the cursor, for no apparent reason. Also the É2æ key of the
  1651. numbers keypad wouldnæt function occasionally. This was accompanied by a
  1652. more worrying symptom where the screen display would suddenly go hay-
  1653. wire and only occasionally would right itself after switching the
  1654. machine off and then on.
  1655. 4.7
  1656. Eventually, it was cured by cleaning the key-contact of the É2æ (keypad)
  1657. and on the basis of öIf it works, donæt fix itò, I didnæt clean any
  1658. other keys. After having the machine checked at a local dealer (ú17.50)
  1659. and some discussion with Archivesæ Technical Help, it was assumed that
  1660. the screen break-up was due to CMOS *Configuration settings somehow
  1661. being changed to Monitor-Multisync, by the spurious keyboard input. The
  1662. problem has not occurred since.
  1663. 4.7
  1664. For anyone else with keyboard problems, hereæs how I cleaned mine: Lay
  1665. the keyboard upside-down and remove all 8 screws under the keyboard base
  1666. and gently lift off the base. Remove the 6 larger screws, securing the
  1667. PCB to the keyboard top-cover. Lift out the complete PCB and keys unit.
  1668. The keytops are all secured in a frame which is, in turn, secured by 20-
  1669. odd small screws from the PCB underside. Take them all out (and put them
  1670. somewhere safe) and, keeping the whole kaboodle together with a firm
  1671. grip, turn it over and set it down right-side up. The complete set of
  1672. keys can now be lifted slowly off the PCB, exposing the rubber contact/
  1673. covers. These are glued with a weak glue. I found that all the rubber
  1674. bits stayed stuck to the PCB. I gently peeled away the rubber contact/
  1675. cover at the offending key position and marvelled at how the dirt had
  1676. managed to penetrate so far, considering that the cover was stuck down.
  1677. The keyboard key contacts (A310) are just gold plated discs of PCB
  1678. copper, easily cleaned with switch cleaner and a non-hairy paper-towel
  1679. or cloth. If you have to blow away any bits, use a camera Épuffer
  1680. brushæ. If you have to use your mouth to blow away grit, crumbs etc,
  1681. wait for any teeny drops of condensation to evaporate. Spit doesnæt make
  1682. a good contact cleaner and some spirit-based cleaners may tend to
  1683. dissolve the pcb-surface varnish which will be smeared over the
  1684. contactsæ surface. Your local electronics hobby shop (e.g. Tandy) should
  1685. have cans of switch-cleaner at ú2 Ö ú3 (which is a lot cheaper than ú120
  1686. for a new keyboard(!) and well worth the extra effort of DIY).
  1687. 4.7
  1688. D.P.Allen, Surrey
  1689. 4.7
  1690. Å   Data cartridges for tape streamers revisited Ö Further to the hint in
  1691. 3.6 p2, the metal variety of DAT can become unreliable after three or
  1692. four writes and so it is better to use the non-metal variety e.g.
  1693. Memorex tapes. Mr Chapman, London
  1694. 4.7
  1695. Å   RISC-OS printing hints Ö Printing out with the RISC-OS printer drivers
  1696. is very easy. However I found several areas which are not well explained
  1697. and one or two things which are down right misleading!
  1698. 4.7
  1699. Å   PRM pages 1526-1528 sprite plotting commands must be with reference to
  1700. the address of the sprite not the name, so if you use
  1701. 4.7
  1702. SYS öOS_SpriteOpò,&122,
  1703. 4.7
  1704. spriteaddr%,önameò,0
  1705. 4.7
  1706. ,xpos%,ypos%
  1707. 4.7
  1708. then, when printing, the error öSprite Not knownò will be returned. The
  1709. solution is to use &222 and an address instead of the sprite name.
  1710. Addresses for a named sprite can be found with
  1711. 4.7
  1712. SYSöOS_SpriteOpò,&118
  1713. 4.7
  1714. addr is in R2 on exit Ö see PRM page 406.
  1715. 4.7
  1716. Å   PRM page 1532. Always use Ö1 (for current) as the destination mode
  1717. with öColourTrans_Select-Tableò if you specify a mode (even the current
  1718. one) ColourTrans will not set up the table correctly resulting in
  1719. strange looking sprites on printout.
  1720. 4.7
  1721. Å   When rendering Draw objects remember to decrease Éflatnessæ to a lower
  1722. value. A useful way of calculating it is to divide the default (512) by
  1723. the print resolution divided by 90 eg. flat= 512/(printxres%/90) where
  1724. printxres% might be 300 Ö as read from
  1725. 4.7
  1726. SYS öPDriver_Infoò TO,printxres%
  1727. 4.7
  1728. printyres% the 90 comes from a normal approximately 90 dots per inch on
  1729. screen. Rob Davison, Southland, New Zealand
  1730. 4.7
  1731. Å   Saving the CMOS RAM settings Ö In recent editions of Archive (e.g.
  1732. 4.3, p.10 and 4.5, p. 21) there have been repeated mentions of the
  1733. problem which arises when a battery failure deletes all the information
  1734. in the CMOS RAM.
  1735. 4.7
  1736. There is one very simple way of solving this problem: On Careware N║ 6
  1737. you will find the application !SysUtil by Jon Marten; one of the choices
  1738. it offers is öSave Configurationò!
  1739. 4.7
  1740. All you have to do is copy the Utility and the öConfigFileò it produces
  1741. to some disc where they are easily accessible Ö not the hard disk!
  1742. 4.7
  1743. After the dreaded memory loss you simply load !SysUtil and drag the
  1744. ConfigFile icon onto the !SysUtil icon and confirm that you want to
  1745. change the configuration. Jochen Konietzko, Koeln, Germany
  1746. 4.7
  1747. Å   Shutdown of hard drives Ö During the recent experience I have had due
  1748. to the volume of hardware Iæve been setting up and testing, the
  1749. following items have come to light.
  1750. 4.7
  1751. MR45æs seemed to be suffering from corruption but, when reformatted, the
  1752. problem went away, so where did the corruption come from?
  1753. 4.7
  1754. A little further investigation revealed that a verify scan caused the
  1755. Closedown procedure of the drive not to occur.
  1756. 4.7
  1757. It was found that, in order to close the drive down properly, a *bye and
  1758. two ¬Shutdowns were required! At first, this was thought to only relate
  1759. to MR45æs but, in fact, it has been found that this is not so, and even
  1760. my own machine (A440/1 with standard Acorn hardware) does similar
  1761. things.
  1762. 4.7
  1763. So, how do you know whether your hard drive is shut down properly? If an
  1764. <f12> is followed by a *bye, a staccato blip from the drive LED should
  1765. occur and a short sharp click noise should emit from the drive itself.
  1766. This is not the closedown condition.
  1767. 4.7
  1768. A *shutdown will now give a flickering performance from the drive LED
  1769. and a multiple clicking from the drive lasting about half a second.This
  1770. is the shutdown condition with the heads parked and isolated from the
  1771. discs and closedown of the system can now occur. Ray Maidstone, Norwich.
  1772. 4.7
  1773. Å   !UIM_Hack update (cf Archive 3.10 p 9) Ö This utility allows you to
  1774. edit characters in The 4th Dimensionæs U.I.M. game. It has now been
  1775. updated and improved by the author, David Sheperdson, and has been put
  1776. on this monthæs program disc.
  1777. 4.7
  1778. Impression Hints and Tips
  1779. 4.7
  1780. Å   Beware thin lines Ö It seems that Impression canæt cope with the very
  1781. thinnest lines that Draw can produce. It does not display them properly
  1782. on the screen and sometimes doesnæt print them properly. The answer is
  1783. to use 1 mm lines instead. This came to light when Brian Cowan was using
  1784. graphs generated by the graph plotting utility (on Shareware N║ 31)
  1785. which apparently uses these thin lines. (This has only been tested in
  1786. version 2.05.)
  1787. 4.7
  1788. Å   Double-clicking on a graphic opens the öalter graphicò window, (For
  1789. those who donæt read manuals.)
  1790. 4.7
  1791. Å   Help! Ö Does anyone know how to create a new Master Page based on an
  1792. existing master page? Itæs a real pain to have to change the margins
  1793. every time you create a new master page. Why canæt you have a new master
  1794. page just slightly different from an existing one? The particular
  1795. application was where I wanted to try two, three, four, five columns
  1796. etc. for a document and every time I wanted to change the number of
  1797. columns, I had to create a new master page, changing the margins from to
  1798. the 5 mm I wanted before changing the number of columns and the inter-
  1799. column gap. (Mind you, I did find one short-cut as a result of having to
  1800. do this over and over again. If you click in the first margin box, you
  1801. can use <ctrl-U> to remove the ö12.7mmò, then press <5> and then <down>
  1802. will move you to the next box and you can repeat the <ctrl-U>, <5>,
  1803. <down> for each box. This applies to most of the dialogue boxes Ö <down>
  1804. moves you to the next box requiring input. Yes, I know it says this in
  1805. the manual, but I didnæt see it.)
  1806. 4.7
  1807. Anyway, can I put my plea another way? Is there any way of editing a
  1808. master page other than sliding the boxes around? Can you edit, by
  1809. entering numbers, the sizes of the margins, for example?
  1810. 4.7
  1811. Å   Search & replace again Ö We mentioned last month that, when doing a
  1812. find and replace, <ctrl-N> finds the Next occurrence, <ctrl-R> does a
  1813. Replace of the marked text. Be warned though that, if the find box is
  1814. on-screen, <ctrl-A> no longer deletes the character at the cursor (as
  1815. <copy> does) it forces All the replaces to occur from the cursor
  1816. downwards to the very end of the document. I found this the hard way
  1817. while attempting to do a selective search and replace at the top of a
  1818. large document. I was changing a column of words into a list by
  1819. replacing
  1820. 4.7
  1821.  with a comma and a space. You can just imagine the havoc that the
  1822. öreplace allò command reeked on my (unsaved!!!) document. You have been
  1823. warned! By the way, <ctrl-E>, presumably relating to Every or End, has
  1824. exactly the same effect as <ctrl-A>. (This has only been tested on
  1825. 2.09.)
  1826. 4.7
  1827. Å   Transferring text between documents Ö In Archive 4.2 p.8, there was a
  1828. hint about the transfer of text between two documents. The implication
  1829. was that this was not possible with Impression. This is not true Ö it is
  1830. just done differently. You select the text in question, press <ctrl-C>,
  1831. move to the appropriate spot in the other document, click once and
  1832. insert the text with <ctrl-V>! Jochen Konietzko, Koeln, Germany  A
  1833. 4.7
  1834.  
  1835. Hints and Tips
  1836. 4.8
  1837. Å   ARM code errata Ö The following is for all those who have an unshak
  1838. able faith in the integrity of Acornæs code:
  1839. 4.8
  1840. The code given to return from SWI öOS_ BreakPtò on page 736 of the PRMs
  1841. is incorrect. The following works.
  1842. 4.8
  1843. .backtobreak%
  1844. 4.8
  1845.    SWI öOS_EnterOSò
  1846. 4.8
  1847.    ADR R14,breaksave
  1848. 4.8
  1849.    LDMIA R14,{r0-r14 }^
  1850. 4.8
  1851.    LDR R14,[R14,#15*4]
  1852. 4.8
  1853.    ADD R14,R14,#4
  1854. 4.8
  1855.    MOVS PC,R14
  1856. 4.8
  1857. The code given on page 231 of the old BASIC User Guide (under CALL) is
  1858. incorrect. For example, to use MATCH, the line tokenisation routine, the
  1859. following code will work. This has been corrected in the new BASIC User
  1860. Guide.
  1861. 4.8
  1862. .tokenise
  1863. 4.8
  1864.    STMFD R13!,{r14 }
  1865. 4.8
  1866.    ADD R0,R14,#18*4
  1867. 4.8
  1868.    ADR R1,source
  1869. 4.8
  1870.    ADR R2,dest
  1871. 4.8
  1872.    MOV R3,#1
  1873. 4.8
  1874.    MOV R4,#0
  1875. 4.8
  1876.    ADR R14,cominghome
  1877. 4.8
  1878.    MOV PC,R0
  1879. 4.8
  1880. .cominghome
  1881. 4.8
  1882.    LDMFD R13!,{pc }
  1883. 4.8
  1884. .source
  1885. 4.8
  1886.    EQUS STRING$(90,CHR$(0))  ALIGN
  1887. 4.8
  1888. .dest
  1889. 4.8
  1890.    EQUS STRING$(90,CHR$(0))  ALIGN
  1891. 4.8
  1892. J Heher, South Africa
  1893. 4.8
  1894. Å   BASIC printing to a DeskJet Plus Ö The April issue of Archive
  1895. contained a Help!!! plea about printing from Archimedes BASIC to a
  1896. DeskJet 500. I have a DeskJet Plus and have successfully printed from
  1897. BASIC. For reference, my printer is normally set with the function
  1898. switches 6 and 8 in bank A and 2 in bank B up, all others are down.
  1899. 4.8
  1900. To print, I use the command VDU 2,1,27,1,38, 1,107,1,49,1,71 (see Line
  1901. Termination in Appendix 8.19 of the Owneræs Manual). Here is an example
  1902. of how it can be used:
  1903. 4.8
  1904.  10 REM >PrintTest
  1905. 4.8
  1906.  20 VDU 2,1,27,1,38,1,107,1,49,1,71
  1907. 4.8
  1908.  30 PRINT öTEST OF NORMAL PRINTINGò
  1909. 4.8
  1910.  40 VDU 1,27,1,38,1,100,1,49,1,68
  1911. 4.8
  1912.  50 PRINT öThis is underlinedò
  1913. 4.8
  1914.  60 VDU 1,27,1,38,100,1,64
  1915. 4.8
  1916.  70 VDU 1,27,1,40,1,115,1,51,1,66
  1917. 4.8
  1918.  80 PRINT öThis is BOLD printingò
  1919. 4.8
  1920.  90 VDU 1,27,1,40,1,115,1,48,1,66
  1921. 4.8
  1922. 100 VDU 1,27,1,40,1,115,1,50,1,48, 1,72
  1923. 4.8
  1924. 110 PRINT öThis is 20 PITCHò
  1925. 4.8
  1926. 120 VDU 1,27,1,69 :REM reset printer
  1927. 4.8
  1928. 130 VDU 3
  1929. 4.8
  1930. 140 END
  1931. 4.8
  1932. A Kitchenside, Weybridge
  1933. 4.8
  1934. Å   Big memory tips Ö As a footnote to my own article in last monthæs
  1935. Archive on making best use of machines with more than 1M memory, Iæd
  1936. like to add one more tip. I was reminded by a review of Protext, which
  1937. noted that the current version does not multi-task, that my eleventh tip
  1938. might have been, öboycott non multi-tasking packagesò. Since, with 1M,
  1939. you couldnæt really multi-task two significant applications, this was
  1940. not a problem. Now, itæs a real pain in the neck not to be able to have
  1941. several applications with simultaneously active windows, much of the
  1942. power and ease-of-use of RISC-OS is being un-used and itæs annoying
  1943. knowing that 3M of your upgrade is being wasted!
  1944. 4.8
  1945. So, unless thereæs a really good reason such as a time-critical sound
  1946. sampler or video screen grabber, I suggest that we boycott such
  1947. packages. Then, software producers would have to bring them up to date
  1948. and not try to palm us off with öArthur programs with !Run and !Boot
  1949. filesò. In an ideal world, software sellers would refuse to stock them
  1950. but at least they could be marked as such, perhaps indicating their
  1951. antiquity by listing them in a suitable script? Stuart Bell, Brighton.
  1952. 4.8
  1953. Å   C book Ö I was recommended a good C book which I used on a C short
  1954. course I attended: The Waite Groupæs öNew C Primer Plusò, First Edition
  1955. 1990, editor Howard W Sams & Co, ISBN 0Ö672Ö22687Ö1. It covers ANSI C,
  1956. UNIX, Microsoft C and Turbo C.   S. Stel, Netherlands.
  1957. 4.8
  1958. Å   ChangeFSI update Ö A new version of ChangeFSI v0.79 is available from
  1959. Acorn Direct for ú19.95. This will handle more image formats than would
  1960. v0.69: Degas PI1, PI2 & PI3, !Translator Clear, MacPaint 579x720x1 bit/
  1961. pixel, ZSoft .PCX, Windows3 .BMP, Pineapple 16 bit/pixel, UNIX rle, PC
  1962. TGA. Unfortunately it will not run from the desktop under !ChangeFSI
  1963. (Shareware Disc 21) as is. This is because version 0.79 is 94 Kbytes
  1964. long, compared with 74K for v0.69. The solution is to edit the !Run file
  1965. of !ChangeFSI and increase the WimpSlot from 128K to 160K. All is then
  1966. well. A Quayle, Chester
  1967. 4.8
  1968. Å   C txt library Ö This idea was inspired by the article ÉIntroduction to
  1969. Cæ ù Part 5, in Archive 3.6. This gave a complete RISC-OS application
  1970. using the libraries supplied with Release 3 of Acorn C. In particular,
  1971. it used the Étxtæ library to provide a window to display text generated
  1972. by the sample program. This requires a minimum of effort by the
  1973. programmer since the library looks after most of the problems.
  1974. 4.8
  1975. Although it works as described, it has two major disadvantages. The
  1976. first is the slow speed during text generation. The second is the
  1977. operation of the window controls. In particular, the cursor control keys
  1978. cannot be used to move the text through the window, the close icon has
  1979. no effect and the vertical scroll bars can only be dragged. Here are
  1980. some techniques which overcome these problems.
  1981. 4.8
  1982. Improved text generation speed turns out to be a very simple modifi
  1983. cation since the cause of the slow operation is the redrawing of the
  1984. window for every item added to the text buffer using, for example, the
  1985. txt_insertstring function. Two extra lines are required; the first turns
  1986. off the display updates when text generation starts and the second turns
  1987. it back on when the operation is complete. The lines shown below should
  1988. be inserted immediately after the visdelay_begin() statement and
  1989. immediately before the visdelay_ end() statement in the original program
  1990. function sysvars_to_text().
  1991. 4.8
  1992. /* turn off display update */
  1993. 4.8
  1994. txt_setcharoptions(t, txt_DISPLAY, FALSE);
  1995. 4.8
  1996.  
  1997. 4.8
  1998. /* turn on display update */
  1999. 4.8
  2000. txt_setcharoptions(t, txt_DISPLAY, TRUE);
  2001. 4.8
  2002. Improving text window control requires rather more code but again the
  2003. principle is fairly straightforward. Firstly an event handler has to be
  2004. registered for the text window following its successful creation by the
  2005. txt_new() function using the following statement:
  2006. 4.8
  2007. /* register the text window event handler */
  2008. 4.8
  2009. txt_eventhandler(t, user_txevent, NULL);
  2010. 4.8
  2011. This registers the function user_txevent which will be called to process
  2012. text window events.
  2013. 4.8
  2014. The function itself has to process all the events which the user
  2015. requires. A sample function is given below which is commented to show
  2016. which events are being processed. The keyboard key macro definitions
  2017. given in Éakbd.hæ are used for consistency but, in addition, the ÉHomeæ
  2018. key must also be defined using a macro as this is omitted from Éakbd.hæ.
  2019. The actual key values required are defined in the PRM, page 1198 and the
  2020. macro definitions are given in file Éakbd.hæ. Note, however, that the
  2021. definitions given for both akbd_ PageUpK and akbd_PageDownK are wrong so
  2022. I have not used these but used their correct definition in the following
  2023. code. The value txt_ EXTRACODE is added to the key value to represent
  2024. the equivalent window operation. A full list of these is given on page
  2025. 325 of the ANSI C Release 3.
  2026. 4.8
  2027.  
  2028. 4.8
  2029. #include öakbd.hò
  2030. 4.8
  2031.  
  2032. 4.8
  2033. #define HOME        (30)
  2034. 4.8
  2035.  
  2036. 4.8
  2037. /***********************************
  2038. 4.8
  2039. user_txevent    text window event handler
  2040. 4.8
  2041.         t            text object
  2042. 4.8
  2043.         h            event handle
  2044. 4.8
  2045. ***********************************/
  2046. 4.8
  2047. void user_txevent(txt t, void *h)
  2048. 4.8
  2049. {lines ; /* number of lines in window */
  2050. 4.8
  2051.  
  2052. 4.8
  2053.  h = h;
  2054. 4.8
  2055.  while (txt_queue(t) > 0)
  2056. 4.8
  2057.  {number of lines visible in window */
  2058. 4.8
  2059.   lines = txt_visiblelinecount(t);
  2060. 4.8
  2061.  
  2062. 4.8
  2063.   /* process the next user event code */
  2064. 4.8
  2065.   switch (txt_get(t))
  2066. 4.8
  2067.   {+ akbd_Fn+127:
  2068. 4.8
  2069.     /* close window icon */
  2070. 4.8
  2071.     txt_hide(t);
  2072. 4.8
  2073.     break;
  2074. 4.8
  2075.   
  2076. 4.8
  2077.    case akbd_UpK:
  2078. 4.8
  2079.    case txt_EXTRACODE + akbd_UpK:
  2080. 4.8
  2081.    case txt_EXTRACODE + akbd_Sh + akbd_Ctl + akbd_UpK:
  2082. 4.8
  2083.     /* scroll up one line */
  2084. 4.8
  2085.     txt_movevertical(t, ù1, TRUE);
  2086. 4.8
  2087.     break;
  2088. 4.8
  2089.   
  2090. 4.8
  2091.    case akbd_DownK:
  2092. 4.8
  2093.    case txt_EXTRACODE + akbd_DownK:
  2094. 4.8
  2095.    case txt_EXTRACODE + akbd_Sh + akbd_Ctl + akbd_DownK:
  2096. 4.8
  2097.     /* scroll down one line */
  2098. 4.8
  2099.     txt_movevertical(t, 1, TRUE);
  2100. 4.8
  2101.     break;
  2102. 4.8
  2103.   
  2104. 4.8
  2105.    case akbd_Sh + akbd_UpK:
  2106. 4.8
  2107.    case txt_EXTRACODE + akbd_Sh + akbd_UpK:
  2108. 4.8
  2109.     /* scroll up one page */
  2110. 4.8
  2111.     txt_movevertical(t, -lines, FALSE);
  2112. 4.8
  2113.     break;
  2114. 4.8
  2115.    case akbd_Sh + akbd_DownK:
  2116. 4.8
  2117.    case txt_EXTRACODE + akbd_Sh + akbd_DownK:
  2118. 4.8
  2119.     /* scroll down one page */
  2120. 4.8
  2121.     txt_movevertical(t, lines, FALSE);
  2122. 4.8
  2123.     break;
  2124. 4.8
  2125.   
  2126. 4.8
  2127.    case akbd_Ctl + akbd_UpK:
  2128. 4.8
  2129.    case HOME:
  2130. 4.8
  2131.     /* move to start of text */
  2132. 4.8
  2133.     txt_setdot(t, 0);
  2134. 4.8
  2135.     break;
  2136. 4.8
  2137.   
  2138. 4.8
  2139.    case akbd_Ctl + akbd_DownK:
  2140. 4.8
  2141.    case akbd_Sh + akbd_CopyK:
  2142. 4.8
  2143.     /* move to end of text */
  2144. 4.8
  2145.     txt_setdot(t, txt_size(t));
  2146. 4.8
  2147.     break;
  2148. 4.8
  2149.   
  2150. 4.8
  2151.    default:
  2152. 4.8
  2153.     break;
  2154. 4.8
  2155.   }
  2156. 4.8
  2157.  }
  2158. 4.8
  2159.  return;
  2160. 4.8
  2161. }
  2162. 4.8
  2163. David Scott, Stockport
  2164. 4.8
  2165. Å   Connection problems Ö If you are having connection problems with RS423
  2166. connectors, or video or printer Ö or a dongle, it may be because the
  2167. plugs are not Égoing homeæ properly into the sockets on the back of the
  2168. computer. I have noticed this particularly on A540æs, but it could also
  2169. occur on other Archimedes computers. This may be because the fixing
  2170. pillars either side of the socket are too high. The solution it to take
  2171. a pair of pliers (or a box spanner if you have a suitable sized one) and
  2172. remove each of the pillars in turn, take off the washer and screw the
  2173. pillar back in. That extra millimetre can make all the difference.
  2174. 4.8
  2175. Å   CPC monitor Ö When my multisync died on me suddenly and I was forced
  2176. to make do with what I had Ö a well worn Amstrad CPC green screen
  2177. monitor. In practice it was fairly easy to connect the six-pin CPC
  2178. connector to the nine-pin connector on the A3000:
  2179. 4.8
  2180.    Archimedes      CPC
  2181. 4.8
  2182.    1, 2 & 3   Ö   6
  2183. 4.8
  2184.    6, 7, 8 & 9   Ö   5
  2185. 4.8
  2186.    5   Ö   4
  2187. 4.8
  2188. Naturally, it is impossible to use the multisync modes but it certainly
  2189. is almost as sharp a picture on the tube as on my multisync and much
  2190. cheaper. If your main interest is games I wouldnæt recommend it but for
  2191. most business uses it is perfectly all right. I guess you could get a
  2192. second hand green CPC monitor for next to nothing in the UK as many
  2193. owners have exchanged them for the new CPC monitors. Ask your local
  2194. dealer! A spare monitor could come in handy any day! Tord Eriksson,
  2195. Sweden.
  2196. 4.8
  2197. Å   !Edit Ö For what seems like an eternity I have been wrestling with the
  2198. problem of importing text from a wordprocessor (in my case View). What I
  2199. wanted to do was free the text from newline characters in order that, on
  2200. loading it into Ovation, it could be formatted to new column width, in
  2201. whatever point size, without the newline control code producing extra
  2202. linefeeds. At the same time, it should retain the carriage returns
  2203. marking the paragraphs and multi-line spacing. This way I did not lose
  2204. all the style. What follows is how I do it . It might seem obvious but
  2205. it could help someone who is as thick as me. If I have missed the point
  2206. would some kind person tell me before I go mad.
  2207. 4.8
  2208. After loading your text into !Edit, go through the text ensuring that
  2209. there are double returns at the end of each paragraph and on multiple
  2210. line text like program listings or poetry.
  2211. 4.8
  2212. My technique is firstly to change double returns into something which is
  2213. unlikely to appear elsewhere in the text, thus:
  2214. 4.8
  2215. Press <F4> to select Find
  2216. 4.8
  2217. In the Find dialogue box enter  \n\n <return>
  2218. 4.8
  2219. In the Replace dialogue box enter  ZCZC<return>
  2220. 4.8
  2221. Click on the Magic Character box
  2222. 4.8
  2223. Click on the Go box
  2224. 4.8
  2225. Click on End of File Replace
  2226. 4.8
  2227. Click on Stop
  2228. 4.8
  2229. Press <ctrl-up> to move the cursor to the top
  2230. 4.8
  2231. Now, to replace the single returns:
  2232. 4.8
  2233. Press <F4> to select Find
  2234. 4.8
  2235. In the Find dialogue box enter  \n <return>
  2236. 4.8
  2237. In the Replace dialogue box press <space>
  2238. 4.8
  2239. Click on Go
  2240. 4.8
  2241. Click on End of File Replace
  2242. 4.8
  2243. Click on Stop
  2244. 4.8
  2245. Press <ctrl-up>
  2246. 4.8
  2247. Then, to restore the double returns to single ones:
  2248. 4.8
  2249. Press <F4> to select Find
  2250. 4.8
  2251. In the Find dialogue box enter  ZCZC<return>
  2252. 4.8
  2253. In the Replace dialogue box enter \n <return>
  2254. 4.8
  2255. Click on Go
  2256. 4.8
  2257. Click on End of File replace
  2258. 4.8
  2259. Click on Stop
  2260. 4.8
  2261. You should have your text with the paragraph and multi-line spacing
  2262. intact. (Simplified from a hint sent in by R Follett, Winnersh, Berks.)
  2263. 4.8
  2264. Å   Improving sound quality Ö Further to the comments by Jeremy Mears
  2265. (Archive 4.7 p 21) there is no need, on the A3000, to actually solder to
  2266. the motherboard. You can make contact to the appropriate resistors using
  2267. micro test clips (Tandy Ö ú1.50 for four). This would, I suppose, still
  2268. invalidate the warranty but is less obvious than blobs of solder on the
  2269. p.c.b.! To get access to the resistors, you have to remove the disc
  2270. drive by unscrewing it from underneath. R86 is under the keyboard side
  2271. of the drive whereas R99 is under the middle of the drive. Pin 1 of the
  2272. expansion port is the furthest right (looking from the keyboard side of
  2273. the computer). Gerald Williams, Aldershot.
  2274. 4.8
  2275. Å   Multiple height and width text printing Ö I know that the emphasis
  2276. these days is on programs which multi-task and use mode 12 on the
  2277. desktop but not every program is suitable for this and some of these
  2278. programs require larger than usual height characters.
  2279. 4.8
  2280. I am (slowly) developing a word game for the Archimedes, from one I
  2281. wrote last year on my Model B. The öBò version uses mode 2, with double
  2282. height routines written in machine code for speed. The original version
  2283. of this code was quite öillegalò and would not work on a Master but it
  2284. was fast! With it, I could also have text printed 3 or even 4 times
  2285. normal height just as quickly. However, I am new to the Archimedes and
  2286. ARM code is currently beyond me, so after trying various routines in
  2287. BASIC I came across VDU23,17,7. This gives characters at any height and
  2288. any width and is very fast! I can even get half width which gives the
  2289. impression of mode 1 characters in mode 2. Also, it works in most Screen
  2290. modes (except 3, 6 & 7).
  2291. 4.8
  2292. Iæve put together a short routine which demonstrates how easy and fast
  2293. this routine is. To use it, all you have to do is append the PROCedure
  2294. to your program and call it with the colour you wish it to appear in,
  2295. the X & Y positions, the height and width of the characters and the
  2296. Text$ Ö the routine will do the rest! One point to bear in mind,
  2297. however, is that text is printed using the graphic cursor, i.e. under
  2298. VDU 5 and MOVE or PLOT, rather than the text cursor and VDU 31, X%,Y%.
  2299. 4.8
  2300. Even though this demonstration program is about 20 lines long, the only
  2301. bits you need are in PROCtext(colour, X_co_ord, Y_co_ord, Height, Width,
  2302. Text$). The function FNvdu simply returns the text width of the screen
  2303. mode window in use and this is used to check if lines are too long in
  2304. the first line of PROCtext. The second line in PROCtext is personal as I
  2305. like being able to centralise text without effort! To do so, just set X%
  2306. to -1. The %110 sets bits 1 and 2 so that both characters and spacing
  2307. are altered at the same time. %100 sets spacing, while %010 will alter
  2308. just character sizes. It is also possible to use 0.5 as Height or Width
  2309. but that works better in öchunkyò modes, like 2 rather than 12. When the
  2310. width is set to an odd number, the öauto-centralisingò is sometimes a
  2311. little off so you may prefer to set up the X co-ord manually.
  2312. 4.8
  2313. REM >$.Height/Wid.!RunImage
  2314. 4.8
  2315. :
  2316. 4.8
  2317. DIM block% 12, output% 12
  2318. 4.8
  2319. MODE12:COLOUR3
  2320. 4.8
  2321. :
  2322. 4.8
  2323. PROCtext(1,-1,1,2,3,öMulti Height & Width!ò)
  2324. 4.8
  2325. PROCtext(2,-1,4,2,1,öDouble Height, Normal Widthò)
  2326. 4.8
  2327. PROCtext(3,-1,7,1,2,öNormal Height, Double Widthò)
  2328. 4.8
  2329. PROCtext(4,-1,10,3,3,ö3 * 3 Formatò)
  2330. 4.8
  2331. PROCtext(5,-1,15,4,1,öRidiculous! 4 X 1 !!ò)
  2332. 4.8
  2333. PROCtext(6,-1,20,1,1,öYou should reset the height & width
  2334. 4.8
  2335.  before finishingò)
  2336. 4.8
  2337. PROCtext(6,-1,21,1,1,öbut as it stands the PROCedure will
  2338. 4.8
  2339. do this anywayò)
  2340. 4.8
  2341. END
  2342. 4.8
  2343. :
  2344. 4.8
  2345. DEFPROCtext(C%,X%,Y%,H,W,T$)
  2346. 4.8
  2347. F%=FNvdu
  2348. 4.8
  2349. IF F%-(LENT$*W)<=0 THEN ERROR 300,öLine too longò
  2350. 4.8
  2351. GCOL C%
  2352. 4.8
  2353. Y%=1000-(Y%*32)
  2354. 4.8
  2355. IF X%=-1 THEN X%=(F%-LENT$*2)/(W*2)
  2356. 4.8
  2357. IF W=1 THEN X%=(F%-LENT$)/4
  2358. 4.8
  2359. X%=X%*32
  2360. 4.8
  2361. VDU 23,17,7,%110,W*8;H*8;0;
  2362. 4.8
  2363. VDU 5,25,4,X%;Y%;
  2364. 4.8
  2365. PRINT T$
  2366. 4.8
  2367. VDU 4,23,17,7,%110,8;8;0;
  2368. 4.8
  2369. ENDPROC
  2370. 4.8
  2371. :
  2372. 4.8
  2373. DEF FNvdu
  2374. 4.8
  2375. !block%=256
  2376. 4.8
  2377. block%!4=-1
  2378. 4.8
  2379. SYSöOS_ReadVduVariablesò,block%,
  2380. 4.8
  2381. output%
  2382. 4.8
  2383. =!output%
  2384. 4.8
  2385. Å   Off screen desktop windows Ö Normally, the filer and switcher windows
  2386. are forced to stay within the confines of the screen but, by altering
  2387. their template files, it is possible to make them move Éoff screenæ and
  2388. thus help to reduce window Éclutteræ.
  2389. 4.8
  2390. To do this, you have to copy the window templates from the DeskFS to a
  2391. directory called Templates. First, create a directory called Templates
  2392. in the root directory of your harddisc or Éworkdiscæ and then type the
  2393. following:
  2394. 4.8
  2395. *deskfs
  2396. 4.8
  2397. *copy templates.filer  scsifs::scsidisc4.$.templates.filer
  2398. 4.8
  2399. *copy templates.switcher  scsifs::scsidisc4.$.templates.filer
  2400. 4.8
  2401. (You can also copy netfiler, palette and wimp windows across if
  2402. required.)
  2403. 4.8
  2404. Load the window template data into !FormEd (Shareware Disc 20) and set
  2405. the Éno boundsæ option for each window. Then, edit your disc !boot file
  2406. to include the following line:
  2407. 4.8
  2408. Set Wimp$Path scsifs::scsidisc4.
  2409. 4.8
  2410. (or whatever your system is!) Donæt forget the full stop at the end.
  2411. This points Wimp$Path in the direction of the updated windows.
  2412. 4.8
  2413. Finally re-boot your machine to see the result!  M Roscoe, Ealing
  2414. 4.8
  2415. Å   PrinterDM with the Star LC24Ö10 Ö I was interested to see the note on
  2416. !PrinterDM and the LC24-10 in Marchæs edition of Archive. May I draw
  2417. your attention to the öHint and Tipò which I had published in the March
  2418. edition of Risc User on the same subject but concerning a different
  2419. problem. I was initially disappointed in the results I obtained with
  2420. Impression Junior (and from the Ovation test disc and, to a lesser
  2421. extent, !Draw printouts). This was due to some lines of text having a
  2422. marked öslewedò effect. After speaking to Star, and much sleuthing, I
  2423. tracked down the problem to the very same line in the PrData file of
  2424. !PrinterDM (version 1.12). There is apparently some incompatibility
  2425. between the Star and the Epson LQ800. The former does not like the özero
  2426. absolute tabò command used to obtain the CR without LF. The solution was
  2427. to substitute the commands used in the FX80 module, although modified to
  2428. use the correct line feed command for 24 pin printers. With my version
  2429. of !PrinterDM I have not experienced any squashed text with the 24/180
  2430. inch feed (could the writer have been in IBM mode where the command
  2431. gives n/216 inches rather than n/180 inches?) but the bigger feed
  2432. suggested in Marchæs tip could equally well be used. The modified line
  2433. is as follows:
  2434. 4.8
  2435. line_epilogue ö<27>A<0><13><27>2<27>J<24>ò
  2436. 4.8
  2437. Iæm surprised that this matter has not previously been commented on,
  2438. especially as I think it also applies to the XB24-10.  A.F. Taylor,
  2439. Poole
  2440. 4.8
  2441. Å   Quattro to Schema transfer Ö To move data files from Quattro, first
  2442. save the file with a WKI extension. Then you can use Schemaæs !sch123 to
  2443. translate the file into Schema format. This method leaves all sorts of
  2444. spurious bits and pieces which have to be edited out by hand but it does
  2445. work.  M Green, Devon
  2446. 4.8
  2447. Å   Quitting First Word Plus Ö If you quit First Word Plus (release 2)
  2448. from the task manager while a text file is loaded, you will be thrown
  2449. out of the desktop. If other applications are running that may object
  2450. e.g. Draw, Paint, etc, they will announce what is about to happen and
  2451. give you a chance to prevent it. Otherwise you will lose any files that
  2452. you may have been working on in First Word Plus.     R Bunnett,
  2453. Swanley
  2454. 4.8
  2455. Å   Reading disc names Ö For those software writers who need to check that
  2456. the user has inserted an appropriate disc in the disc drive the
  2457. following function returns the name if the disc currently inserted:
  2458. 4.8
  2459. DIM block% 5
  2460. 4.8
  2461. :
  2462. 4.8
  2463. DEF FNdiscname
  2464. 4.8
  2465. SYS öOS_GBPBò,5,,block%
  2466. 4.8
  2467. ?(block%+?block% +1)=13
  2468. 4.8
  2469. =$(block%+1)
  2470. 4.8
  2471. M Sawle, Hampshire
  2472. 4.8
  2473. Å   !Schema VAT rate Ö New spreadsheets are created with various user
  2474. names available, one of which is öVatò. To change this from 0.15 to
  2475. 0.175, look in the !Schema directory and then in the Menu directory and
  2476. you should find a file called StartUp. This has a write-lock on it so
  2477. you will have to use ÉAccessæ off the filer menu to enable it to be
  2478. changed. At the end of this file are a number of lines that start with
  2479. Éputusnæ, the first of which is the Vat rate which simply needs to be
  2480. changed before the file is again saved and the write-lock access
  2481. restored. Ian Hamilton, Harrow.
  2482. 4.8
  2483. Å   Spaced filenames Ö If you want a <space> in a disc or file name, use a
  2484. hard space. This is available by pressing either <alt><1><6><0> or
  2485. <alt><space>. You should note that if you do use it then you canæt use
  2486. the copy key on a catalogue because the Archimedes thinks that the
  2487. character is a normal space (which is illegal in a filename). E Hughes,
  2488. Derbyshire
  2489. 4.8
  2490. Å   Twin World cheats Ö The file SavedGame can be edited using !Edit to
  2491. cheat. Byte values of interest include:
  2492. 4.8
  2493. Byte 1 = Level (Maximum = 22 = &16)
  2494. 4.8
  2495. Byte 4 = Red Spells (Maximum 99 = &63)
  2496. 4.8
  2497. Byte 5 = Blue Spells (Maximum 99 = &63)
  2498. 4.8
  2499. Byte 6 = Green Spells (Maximum 99 = &63)
  2500. 4.8
  2501. Bytes 8-11 = Score, low byte first. (Maximum = 999999 = &F423F )
  2502. 4.8
  2503. Byte 12 = Lives (Maximum = 9 or 10 = &9 or &0A)
  2504. 4.8
  2505. Remember all value are in hex, so use the magic character option in
  2506. !Editæs Find.  Stuart Turgis
  2507. 4.8
  2508. Å   TwinWorld hints
  2509. 4.8
  2510. Ö Owls in the forest can be killed by jumping up and firing.
  2511. 4.8
  2512. Ö Similarly, on some occasions you will have to jump, but fire on the
  2513. way down to hit denizens close to you.
  2514. 4.8
  2515. Ö Jump between worlds whenever possible Ö if you loose a life, youære
  2516. taken back to the last time you changed worlds.
  2517. 4.8
  2518. Ö Stamping your feet can reveal objects Ö either treasure or keys.
  2519. 4.8
  2520. Ö Beware of calling the genie when you are already carrying two other
  2521. sorts of objects (remember the horn is one), because you wonæt be able
  2522. to buy an object which you donæt already hold.
  2523. 4.8
  2524. Ö Beware when shooting the three-headed dragon. If you donæt shoot the
  2525. head furthest away from you, it flies away from you and fires an almost
  2526. continuous salvo.
  2527. 4.8
  2528. Ö Watch out for extended jump Ö you can sometimes use it when you donæt
  2529. realise Ö on some screens itæs essential and you may only have a limited
  2530. amount.
  2531. 4.8
  2532. Ö Watch out for the parachute Ö in the last few levels I found I
  2533. couldnæt get rid of it and it limited my objects to just two types.
  2534. 4.8
  2535. Ö When firing at the bird Ö if you duck, it flies lower to avoid your
  2536. fire. Stand until the bird is fairly close, then crouch and fire.
  2537. 4.8
  2538. Ö When the giant clam fires at you, or the Big eye, if you run so the
  2539. Ébulletæ is off the screen it will disappear.
  2540. 4.8
  2541. Impression
  2542. 4.8
  2543. Hints & Tips
  2544. 4.8
  2545. Bruce Goatly (BG), who is busy writing a book about using Impression,
  2546. very kindly sent us some hints & tips (in return for permission to use
  2547. our H&T in his book!). Most of the rest of the H&T are from the editoræs
  2548. experiences with the unreleased version 2.09. (Version 2.10 is not ready
  2549. for release so 2.05 is still the latest officially available version.)
  2550. 4.8
  2551. Å   Abbreviation expansion Ö Use it to correct common spelling errors or
  2552. to enforce house style (I often type Éansæ for Éandæ and Éthwæ for
  2553. Étheæ, and the house style for my book is Édiskæ whereas I almost always
  2554. spell it Édiscæ). BG.
  2555. 4.8
  2556. Å   Date and time format Ö As I continually forget what day it is, I use
  2557. the Insert date option quite a lot. If you want to change the format of
  2558. the date (the default is in the form 6th April 1991), load the !Run file
  2559. into Edit and alter the definition of the variable Impression$DateFormat
  2560. (see pp. 337-339 of the User Guide, on using system variables).
  2561. Similarly, you can alter the time format by editing
  2562. Impression$TimeFormat. BG.
  2563. 4.8
  2564. Å   Dongle connection problems Ö If you are having problems with a dongle
  2565. that keeps saying it is not present and you find that you need to wiggle
  2566. it (just a little bit!) to recognise its presence, go back and read the
  2567. hint above about ÉConnection problemsæ. Alternatively, CC themselves
  2568. offer a hint about it. They say that it is important to quit properly
  2569. from Impression and not just do a <ctrl-break>, otherwise the dongle
  2570. might need to be left for a couple of hours for a capacitor to discharge
  2571. before Impression can be loaded again.
  2572. 4.8
  2573. Å   Line spacing and font changes Ö If a line in the middle of a paragraph
  2574. starts with a different font from the lines around it, the line spacing
  2575. may be upset for that one line because of the way Impression does its
  2576. calculations. The way round it is to put the cursor at the start of the
  2577. offending line, cancel the font change at that point and insert a Énullæ
  2578. character (such as Alt-131). This will be invisible but will correct the
  2579. line spacing. BG.
  2580. 4.8
  2581. Å   Loading text files Ö If you want to load a text file into Impression,
  2582. there is no need to create a new document first Ö just drag the Edit
  2583. file onto the Impression icon and it will set up an untitled document
  2584. and load the text into a null frame.
  2585. 4.8
  2586. Å   Marking a single character Ö If you are doing DTP in a lower resolu
  2587. tion screen mode, you may be finding it difficult to use the mouse to
  2588. drag-mark a single character e.g. the Élæ in Éwillæ. One way of doing it
  2589. is to move the cursor between two of the characters, click <select> but
  2590. firmly hold the mouse in place. Then you use the cursor left or right,
  2591. as appropriate, to move the cursor to the other side of the character to
  2592. be marked and finally press <adjust>. George Foot, Oxted.
  2593. 4.8
  2594. My method of doing any of this kind of detailed work is to have two
  2595. windows open on the same document Ö which is extremely easy to do
  2596. (another advantage over PageMaker!) Ö one shows the full page and one
  2597. just an enlarged section of the text. Then you can flick backwards and
  2598. forwards between the two views enlarging and contracting the windows or
  2599. simply pushing them to the back when they are not wanted.
  2600. 4.8
  2601. (However, have you noticed that Impression sometimes insists on going
  2602. back to the beginning of the document when you expand and contract the
  2603. window using the size switch icon in the top right hand corner of the
  2604. window? Has anyone worked out why it happens and, more importantly, how
  2605. to stop it?)
  2606. 4.8
  2607. Å   Special characters Ö The list in Appendix 5 of the Impression II
  2608. manual gives a printout of all the characters. This is useful, but there
  2609. is some variation from one typeface to another, so it would be useful to
  2610. have an Impression file of it so that you could print it out in your
  2611. particular typeface. Iæll put a file of it on the monthly program disc,
  2612. but if you want to do it yourself, you can run the following program and
  2613. put the text into a multi-column Impression document.
  2614. 4.8
  2615. 10 REM > CHARLISTER
  2616. 4.8
  2617. 20 *SPOOL CHARS
  2618. 4.8
  2619. 30 @%=2
  2620. 4.8
  2621. 40 FOR N% = 32 TO 255
  2622. 4.8
  2623. 50 PRINT N%;CHR$(9);
  2624. 4.8
  2625. ö{òöheadingòöon }{ò ;CHR$(N%); ö}ò
  2626. 4.8
  2627. 60 NEXT
  2628. 4.8
  2629. 70 *SPOOL
  2630. 4.8
  2631. Å   Spell-checking Ö Not really a hint, but I was using the spelling
  2632. checker and it offered me the word öfaltnessò and told me that
  2633. öflatnessò was wrongly spelled. Also, while spell-checking, someone had
  2634. written öBeebugsæ policyò. The spelling checker knows Beebug but can you
  2635. guess what it offered me as an alternative for the accidental plural?
  2636. Yes, thatæs right, öBedbugsò! On the same theme, I spell-checked my
  2637. Factfile and came up with Motley Electronics, Mike Leecher of EMU Ltd,
  2638. ARM3æs from Aloof One and IDLE drives from Ian Copycats. Then I tried
  2639. some of our contributors and found Brain Cowman, Dim Parkland and last,
  2640. but not least, Pall Beggarly.
  2641. 4.8
  2642. Å   Tickets please! Ö (The following saga gives, firstly, an unnecessarily
  2643. long method of doing a job but one which illustrates techniques which
  2644. might prove useful in other circumstances. It is followed by the easier,
  2645. smarter method!) I wanted to make some numbered tickets at A6 size so I
  2646. made up an A4 page with four copies of the ticket. I used a two column
  2647. master page so that I could just take a copy of the text on the page and
  2648. paste it 14 times to make my 60 tickets. Near the bottom of each ticket,
  2649. it said, öTicket number: ò with an appropriate blank space. Then I
  2650. created four guide frames on the master page at about the right place to
  2651. put in the ticket numbers and inserted four new frames on each page. I
  2652. then went through linking all the frames together. To create the text
  2653. for the numbers, I used PipeDream using the örowò command and copying it
  2654. down 60 rows. I then ösavedò this in tab format straight into the first
  2655. ticket number frame and, instantly, all the tickets were numbered.
  2656. Brilliant! The only real hassle was lining up the ticket number boxes
  2657. with the words on the ticket. The problem is that although you can have
  2658. both the text and the master page on screen at the same time and at the
  2659. same magnification (which helps), the main page is not updated until the
  2660. master page is closed so I changed the öpreferencesò to make the master
  2661. page come up at the right magnification.
  2662. 4.8
  2663. (A similar technique of linked frames is used for the running heads on
  2664. the magazine Ö i.e. the articlesæ names at top outside corners of the
  2665. pages. The dummy Archive, before articles are inserted, has a whole
  2666. string of 60 öXòs, one on each page, alternately left and right aligned.
  2667. Then, when an article has been inserted, the running heads are altered
  2668. using selective search and replace to change, for example, öXò into
  2669. öHints & Tipsò. This is easier than using copy and paste because it
  2670. preserves the left and right alignment. But I digress... let me get back
  2671. to the tickets...)
  2672. 4.8
  2673. Then I suddenly realised the easy way of doing it.... Create the ticket
  2674. at full A4 size on the master page using öTicket number: ò and then
  2675. inserting the page number. (Use <menu> Ö Misc Ö Insert Ö Current page
  2676. number Ö Numeric.) Then, all you do is to add 59 pages (click on öInsert
  2677. new pageò with <adjust>, not <select> so that the menu option stays on
  2678. the screen) and use öFit lotsò on the öPrintò dialogue box reducing the
  2679. scale to 50%. If you find that it still says, öFit lots (1)ò at 50% and
  2680. you have to go down to about 48% before it goes to (4), click on
  2681. öSetup...ò and select the option to öIgnore page boundaryò. If you donæt
  2682. do this but print out at 48%, you will find that the margins are
  2683. unequal. This is a much quicker way of doing it than the previous method
  2684. and also gives the possibility of deciding that you want the tickets
  2685. smaller after all so you just reduce the scale and, perhaps, change to
  2686. sideways printing.
  2687. 4.8
  2688. Å   Widows & orphans Ö This is the technical term for where you get a
  2689. paragraph split so that a single line is on one page (or column) and the
  2690. rest is on the previous or next. If the first line is split off from the
  2691. rest, the solution is fairly obvious Ö use <ctrl-G> at the beginning of
  2692. the paragraph to push the line onto the next column. The odd line at the
  2693. end of a paragraph is less easy. If the text is left justified, you can
  2694. again use <ctrl-G> to push one more line to the next column to join the
  2695. lonely orphan. However, if you subsequently edit the paragraph so that
  2696. the layout of the lines changes, you have to edit out the <ctrl-G>.
  2697. Also, this doesnæt work at all if you are using full justification
  2698. because the <ctrl-G> causes the justification on the last line of the
  2699. column to be lost and it looks like the end of a paragraph without a
  2700. full stop. The only solution I can find is to create a new frame with
  2701. <ctrl-I> and lay it over the last line of the column. This forces that
  2702. line over to the next column without losing the justification.
  2703. 4.8
  2704. SCSI Hints & Tips
  2705. 4.8
  2706. Å   Removable drive problems Ö We are beginning to understand more about
  2707. the problems with removable drives. Let me explain... SCSI drives are
  2708. intelligent and they keep their own record of any duff sectors. However,
  2709. this record is not available to the user. If you tell the computer to
  2710. öformatò the disc, it deliberately ignores any sectors it already knows
  2711. are duff. If you get a ösoft errorò i.e. where the data gets corrupted
  2712. so that the CRC check shows up an error, reformatting will clear the
  2713. problem. However, if the disc surface is actually damaged, it may be
  2714. that reformatting clears the problem temporarily but, with time, the
  2715. problem may reappear and you will get the dreaded öDisc error 10 at... ò
  2716. or whatever. The solution to this is to use the *DEFECT command provided
  2717. by RISC-OS. If you get an error, *VERIFY the disc, note the addresses
  2718. which are thrown up as either suspect or actually having a disc error,
  2719. say, 7CEC00, 7CEE00 and 7CF000 and then type in
  2720. 4.8
  2721. *DEFECT SCSI::5 7CEC00
  2722. 4.8
  2723. *DEFECT SCSI::5 7CEE00
  2724. 4.8
  2725. *DEFECT SCSI::5 7CF000
  2726. 4.8
  2727. where SCSI::5 is the drive definition. It is worth recording these
  2728. addresses in case you need to format the disc again in the future. You
  2729. then need to enter the *DEFECT commands again. If *DEFECT finds that you
  2730. are trying to map out a sector that is allocated to a file or directory,
  2731. it will tell you so, in which case, you will have to copy the file or
  2732. directory and delete the one which it says is in the way.
  2733. 4.8
  2734. Obviously, it is better if you can avoid getting hard errors in the
  2735. first place so, just as a reminder, (1) always dismount the drive
  2736. properly before switching off the power and (2) keep your drive cool by
  2737. not packing other hardware around it.
  2738. 4.8
  2739. Å   Removable drive problems (Part 2) Ö Surely there canæt be any MORE
  2740. problems with the removable drives Ö they really wonæt be worth selling.
  2741. Yes, there are more problems but, yes, I still think they are worth
  2742. selling. If you try to use the MR45æs or the Atomwide equivalent on an
  2743. Acorn SCSI podule or on a TechnoSCSI (I have not tried any others), you
  2744. will find that occasionally they just hang up Ö usually when copying a
  2745. sequence of files. It is a timing problem which Acorn say they will look
  2746. into but they are not too optimistic. They say that Syquest, who make
  2747. the drive mechanisms, have interpreted the SCSI standards in a different
  2748. way from other drive manufacturers. The Acorn engineers have tried to
  2749. modify their software to accommodate Syquestæs idiosyncrasies but
  2750. although they have managed to make a version of their software that will
  2751. work when copying lots of files, they find that it does not format the
  2752. cartridges properly! It is not beyond the bounds of possibility to get
  2753. SCSI software to work on the Syquest drives Ö both Oak and Lingenuity
  2754. have done it successfully but, as yet, there is no satisfactory way of
  2755. running them on Acorn or TechnoSCSI cards.
  2756. 4.8
  2757. I should say to A540 owners, that, although I am using a Syquest
  2758. removable drive on my A540, I am doing so on an Oak podule. I made the
  2759. change (before I realised there was any problem) purely on the basis
  2760. that (1) the Oak software is the easiest to use on the MR45æs because of
  2761. the ease of dismounting and re-mounting discs and (2) it is the fastest
  2762. that I have tried. (I have not yet tried the offerings from HCCS or The
  2763. Serial Port but unless they have specifically tailored their software
  2764. for the Syquest mechanisms, I doubt that they will work.)
  2765. 4.8
  2766. Å   SCSI land speed record Ö Oak are claiming an Archimedes drive speed
  2767. record. Their 300M HS drive, on an A440 with a 20MHz ARM3, runs at 1939
  2768. / 1761 / 1043  Kbytes/sec in modes 0, 15 and 21 respectively. Can anyone
  2769. beat that?  A
  2770. 4.8
  2771.  
  2772. Hints and Tips
  2773. 4.9
  2774. Å   Beware spaces Ö There is a problem with spaces at the end of OS
  2775. variables:
  2776. 4.9
  2777. If you include in a !Run file code such as the following:
  2778. 4.9
  2779. Set ThisApp$Dir <Obey$Dir>
  2780. 4.9
  2781. Run <ThisApp$Dir>.!RunImage
  2782. 4.9
  2783. then beware that you donæt include a space at the end of the first line!
  2784. If you do, the space will be included in the definition of ThisApp$Dir
  2785. and the second line will cause a öBad File Nameò error. Hugh Eagle.
  2786. 4.9
  2787. Å   PC emulator with an ARM3 Ö The default boot-up process for the ARM3
  2788. performs an RMClear command, killing all RAM resident modules including,
  2789. in particular, the module that drives the ARM3. So, in order, to get the
  2790. PC emulator to take advantage of the ARM3És extra speed you need to
  2791. alter the line in !PC.Genboot.!Config immediately after the one that
  2792. reads öPerform RMClear?ò from öYò to öNò! (Thanks to Martin Coulson of
  2793. Atomwide for this advice.) Hugh Eagle
  2794. 4.9
  2795. Å   Printer tips Ö You can alter the halftone density by editing the
  2796. PrData file within your printer driver (see Archive 4.6 for an example
  2797. of how to find this). For instance, PrinterLJ has lines such as:
  2798. 4.9
  2799. pxres_halftone:300/8
  2800. 4.9
  2801. pyres_halftone:300/8
  2802. 4.9
  2803. so each halftone dot is actually formed of a matrix of 8x8 dots, giving
  2804. a halftone density of 300/8=37.5 dpi. This gives a very coarse effect
  2805. but can produce 65 different grey levels. Altering the lines to:
  2806. 4.9
  2807. pxres_halftone:300/6
  2808. 4.9
  2809. pyres_halftone:300/6
  2810. 4.9
  2811. gives öonlyò 37 grey levels and a dot pitch of 50 dpi. Experiment to see
  2812. what suits your printer best.
  2813. 4.9
  2814. A word of caution. I used !Draw to produce some PCB artwork, printed it
  2815. out using !PrinterLJ on a DeskJet Plus and sent it off... Disaster! The
  2816. size was OK across the width but was 1.5% too small along the length of
  2817. the paper, as was discovered when the finished circuit boards came back.
  2818. Iæd previously had no trouble using an Epson-compatible printer, so it
  2819. may be something to do with the friction feed on the HP slipping, or
  2820. perhaps a slightly thicker paper would have helped. Anyway, if your hard
  2821. copy must be accurate, then check it! Jonathan Oakley, Cambridge.
  2822. 4.9
  2823. Å   Printing * command output Ö Ever since I got my LaserDirect I have
  2824. been laboriously printing the results of *Status, *Dump, etc. by
  2825. directing the output to a file and then printing the file (while
  2826. bemoaning the loss of the <Ctrl-B>, etc. facility α la BBC). However, I
  2827. have just realised that it is easier (and much more in keeping with
  2828. Acornæs RISC-OS standards, I am sure) to open a Task Window in !Edit,
  2829. enter the * command (which puts its output in the window) and then print
  2830. the contents of the window by ösavingò to the printer driver icon. In
  2831. other words, click <menu> on the !Edit icon on the icon bar and use
  2832. Create Ö New Task window. This presents you with a new window with a *
  2833. ready for a command. Type in the command whose output you want listing,
  2834. say, *STATUS. When the listing has finished, click on the window with
  2835. <menu> and go Edit Ö Save and drop the text file produced onto your
  2836. printer icon. Easy! (Then close the window, answering ÉYesæ to ÉKill and
  2837. closeæ.) Hugh Eagle
  2838. 4.9
  2839. Å   Printing via a RISC-OS printer driver from a BASIC program Ö Have you
  2840. ever wondered why your computer has a button called öPrintò that doesnæt
  2841. seem to do anything of the sort?
  2842. 4.9
  2843. At last, applications seem to be appearing that recognise that pressing
  2844. the <Print> key is rather an intuitive way of printing (Impression and
  2845. Poster are two examples). Also, I have discovered that RISC-OS printer
  2846. drivers are not nearly as fearsome as the PRM makes them seem and it is
  2847. actually quite easy to incorporate into your own programæs printing
  2848. routines which are activated by ... wait for it ... the <Print> key.
  2849. Amazing!
  2850. 4.9
  2851. Take the Painting application from the original Arthurian Welcome disc,
  2852. for instance. We still use this in my family because it is so simple,
  2853. but it has always (incredibly) lacked a printing facility. To rectify
  2854. this, proceed as follows:
  2855. 4.9
  2856. Put this line near the beginning of the program (e.g. immediately after
  2857. PROCdesktop (at about line 200):
  2858. 4.9
  2859.  PROCPrintSetup(110000)
  2860. 4.9
  2861. Note: 110,000 bytes is big enough to allow the program to run in mode
  2862. 20. 55,000 would be enough for mode 12.
  2863. 4.9
  2864. Put this line in the WimpPoll loop (e.g. immediately after the ENDCASE
  2865. statement at around line 400):
  2866. 4.9
  2867. IF INKEY-33 THEN PROCPrint(162,232,1274,972)
  2868. 4.9
  2869. Note: INKEY-33 is the crucial function that recognises whether the
  2870. <Print> key is being pressed.
  2871. 4.9
  2872. Finally, put these procedures at the end of the program:
  2873. 4.9
  2874. DEF PROCPrintSetup(SpriteAreaSize%)
  2875. 4.9
  2876. DIM SpriteArea% SpriteAreaSize%
  2877. 4.9
  2878. !SpriteArea%=SpriteAreaSize%
  2879. 4.9
  2880. SpriteArea%!8=16
  2881. 4.9
  2882. SYS öOS_SpriteOpò,9+256,SpriteArea%
  2883. 4.9
  2884. ENDPROC
  2885. 4.9
  2886.  
  2887. 4.9
  2888. DEF PROCPrint(X1%,Y1%,X2%,Y2%)
  2889. 4.9
  2890. SYS öHourglass_Onò
  2891. 4.9
  2892. PrintHandle%=OPENOUT(öprinter:ò)
  2893. 4.9
  2894. SYS öPDriver_SelectJobò,PrintHandle% ,0 TO Old%
  2895. 4.9
  2896. ON ERROR LOCAL PROCPrintError
  2897. 4.9
  2898.  
  2899. 4.9
  2900. MOVE X1%,Y1%:MOVE X2%,Y2%
  2901. 4.9
  2902. SYS öOS_SpriteOpò,14+256, SpriteArea%,öTempSpriteò,1 : REM Get sprite
  2903. 4.9
  2904.  
  2905. 4.9
  2906. DIM RectBlock% 15,Transform% 15,PrintPosition% 7
  2907. 4.9
  2908. RectID%=1
  2909. 4.9
  2910. BackCol%=&FFFFFF00:REM set background colour to white
  2911. 4.9
  2912.  
  2913. 4.9
  2914. REM X1%, Y1%, etc. are the screen coordinates of the area
  2915. 4.9
  2916. to be printed
  2917. 4.9
  2918. !RectBlock%=X1%:RectBlock%!4=Y1%
  2919. 4.9
  2920. RectBlock%!8=X2%:RectBlock%!12=Y2%
  2921. 4.9
  2922.  
  2923. 4.9
  2924. REM No scaling or rotation required
  2925. 4.9
  2926. !Transform%=&10000:Transform%!4=0
  2927. 4.9
  2928. Transform%!8=0:Transform%!12=&10000
  2929. 4.9
  2930.  
  2931. 4.9
  2932. REM Put the bottom LH corner 1.5ö REM from the left AND 5ò from the
  2933. 4.9
  2934. REM bottom of the page
  2935. 4.9
  2936. !PrintPosition%=1.5*72000
  2937. 4.9
  2938. PrintPosition%!4=5*72000
  2939. 4.9
  2940.  
  2941. 4.9
  2942. SYS öPDriver_GiveRectangleò,RectID%, RectBlock%,Transform%,
  2943. PrintPosition%,BackCol%
  2944. 4.9
  2945. SYS öPDriver_DrawPageò,1,RectBlock%, 0,0 TO More%,,RectID%
  2946. 4.9
  2947. WHILE More%
  2948. 4.9
  2949.   SYS öOS_SpriteOpò,34+256
  2950. 4.9
  2951. ,SpriteArea%,öTempSpriteò
  2952. 4.9
  2953. ,X1%,Y1%,0
  2954. 4.9
  2955.   SYS öPDriver_GetRectangleò,, RectBlock% TO More%,,RectID%
  2956. 4.9
  2957. ENDWHILE
  2958. 4.9
  2959. SYS öPDriver_EndJobò,PrintHandle%
  2960. 4.9
  2961. SYS öHourglass_Smashò
  2962. 4.9
  2963. CLOSE#(PrintHandle%)
  2964. 4.9
  2965. ENDPROC
  2966. 4.9
  2967.  
  2968. 4.9
  2969. DEF PROCPrintError
  2970. 4.9
  2971. SYS öPDriver_Abortò,PrintHandle%
  2972. 4.9
  2973. SYS öHourglass_Smashò
  2974. 4.9
  2975. CLOSE#(PrintHandle%)
  2976. 4.9
  2977. ENDPROC
  2978. 4.9
  2979. Hugh Eagle
  2980. 4.9
  2981. Å   Running one application from inside another If youæve ever been
  2982. puzzled by odd behaviour when you try to run one application from inside
  2983. another, the following advice from Mark Neves of Computer Conceptsæ
  2984. Technical Support Department may help.
  2985. 4.9
  2986. My particular problem arose when I tried to make sure that a printer
  2987. driver was loaded by running !PrinterXX from within application Aæs !Run
  2988. file. The result was that application A failed to run and when I quit
  2989. !PrinterXX, an error was reported.
  2990. 4.9
  2991. The answer is that when you run a ösibling taskò from another appli
  2992. cationæs run file the sibling ötakes over the current environmentò until
  2993. it terminates and only then does it return control to the parent task
  2994. (in a manner analogous to a subroutine call).
  2995. 4.9
  2996. The solution is to use the command
  2997. 4.9
  2998. * Desktop <sibling task name>
  2999. 4.9
  3000. rather than *Run.  Hugh Eagle
  3001. 4.9
  3002. Å   öSavingò data from one application to another Ö (This is another of
  3003. those öobvious to those who know itò hints.) If you want to transfer
  3004. data (e.g. text or a sprite or a drawn object) from one RISC-OS
  3005. application to another you donæt have to save it on a disc from
  3006. application A and then load it into application B; all you have to do is
  3007. drag the icon from application Aæs öSaveò box (i.e. the window that
  3008. appears when you choose a Save menu option) into application Bæs window.
  3009. 4.9
  3010. This works with all well behaved (öRISC-OS compliantò) applications,
  3011. e.g. !Edit, !Draw, Impression, !Paint, !Poster, etc. and generally works
  3012. for either the whole contents of a window or for selected items. Hugh
  3013. Eagle
  3014. 4.9
  3015. Å   Sprite plotting and colour translation Ö The ColourTrans section of
  3016. the PRM (pages 1399 to 1424) includes references to a number of SWIæs
  3017. (including, in particular, ColourTrans_SelectTable) which have to be
  3018. called with R1 pointing to the ösource paletteò. Since, according to PRM
  3019. pages 390Ö391, a spriteæs palette data starts 44 bytes after the
  3020. beginning of the sprite, it seems clear that, in order to translate a
  3021. spriteæs palette you simply call the ColourTrans SWI with
  3022. SpritePointer%+44 in R1, doesnæt it? Wrong!!!
  3023. 4.9
  3024. In fact, the palette data in a sprite appears to include 8 bytes for
  3025. each colour with the second 4 bytes duplicating the first 4 (does anyone
  3026. know why this is?) whereas ColourTrans expects only 4 bytes per colour.
  3027. 4.9
  3028. So, before you can translate a spriteæs colours, you need to include
  3029. some code on the following lines:Ö
  3030. 4.9
  3031. PaletteLength%=SpritePointer%!32Ö44
  3032. 4.9
  3033. IF PaletteLength%=0 THEN
  3034. 4.9
  3035.  PalettePointer%=0
  3036. 4.9
  3037. ELSE
  3038. 4.9
  3039.  FOR I%=0 TO PaletteLength%-8 STEP 8
  3040. 4.9
  3041.   Palette%!(I%/2) = SpritePointer%!(I%+44)
  3042. 4.9
  3043.  NEXT
  3044. 4.9
  3045.  PalettePointer%=Palette%
  3046. 4.9
  3047. ENDIF
  3048. 4.9
  3049. Note: The palette data, if any, starts 44 bytes after the beginning of
  3050. the sprite. SpritePointer%!32 contains the number of bytes from the
  3051. beginning of the sprite to the start of the actual sprite pixel data. If
  3052. this equals 44, there is no palette.
  3053. 4.9
  3054. The point of setting PalettePointer% to 0 if there is no palette data,
  3055. is that if the sprite has no palette then, in many cases, (especially if
  3056. the sprite is defined in a 256 colour mode) it makes sense to call
  3057. ColourTrans with R1 set to 0 since ColourTrans will then translate the
  3058. default palette for the spriteæs mode. However ...
  3059. 4.9
  3060. Å   Strange sprite colours Ö Ever since RISC-OS arrived, Iæve been puzzled
  3061. by the odd colours which have appeared when some sprites have been
  3062. plotted by various applications (including Impression, no less). I think
  3063. that, at last, Iæm beginning to understand why. Consider the following
  3064. curious state of affairs:
  3065. 4.9
  3066. Palette details are an optional part of the sprite data format. A lot of
  3067. sprites are created by !Paint. !Paint, by default, creates sprites
  3068. without a palette (presumably on the assumption that, having been
  3069. designed in the Desktop colour scheme, they will be used on the
  3070. Desktop.)
  3071. 4.9
  3072. The PRM (page 1278) recommends that you should use the ColourTrans
  3073. module for best results when plotting or printing a sprite. However,
  3074. although ColourTrans knows how to translate from any given palette and
  3075. from the default palette for any mode, it doesnæt seem to be equipped
  3076. with any means of translating the standard desktop palette of a mode
  3077. other than the current one.
  3078. 4.9
  3079. Therefore, the best that applications can do when faced with a palette-
  3080. less sprite is to tell ColourTrans to assume that the sprite was defined
  3081. in the default palette for its mode. The trouble with this is that it is
  3082. about the worst possible thing that can be done with a sprite defined to
  3083. be used on the Desktop since, for instance, colour 0 which is intended
  3084. to be white, will be translated by ColourTrans, working from the default
  3085. palette, into black! For example, even Impression reverses the colours
  3086. of its standard document icon.
  3087. 4.9
  3088. So, whatæs to be done? As far as I can tell:
  3089. 4.9
  3090. The best advice is to make sure that every sprite has a palette. If this
  3091. isnæt possible then, for plotting sprites on the Desktop, use
  3092. Wimp_ReadPixTrans if a sprite doesnæt have a palette (this is the
  3093. routine that the Wimp manager uses for plotting sprites as icons and
  3094. seems to produce quite acceptable results on the whole) and save
  3095. ColourTrans calls for sprites that do have palettes. For example, follow
  3096. the above palette conversion routine with code something like this:
  3097. 4.9
  3098. SYS öColourTrans_SelectTableò,Mode%, PalettePointer%,-1,-1,ColTable%
  3099. 4.9
  3100. IF PaletteLength%<>0 THEN
  3101. 4.9
  3102.   SYS öOS_SpriteOpò,52+512,Sprites% ,SpritePointer%,200,200,
  3103. Mask%*8,Scale%,ColTable%
  3104. 4.9
  3105. ELSE
  3106. 4.9
  3107.   IF NumberOfColoursInSprite%<63 THEN SYS öWimp_ReadPixTransò, 512,
  3108. Sprites%,SpritePointer% ,,,,,ColTable%
  3109. 4.9
  3110.   SYS öOS_SpriteOpò,52+512,Sprites%, SpritePointer%,200,200,
  3111. 4.9
  3112. Mask%*8,Scale%,ColTable%
  3113. 4.9
  3114. ENDIF
  3115. 4.9
  3116. If youære plotting to a printer, öWimp_ReadPixTransò doesnæt help and I
  3117. donæt think there is any straightforward, foolproof method. (It would be
  3118. possible, I think, to create a block of palette data with the RGB values
  3119. for the colours of the Desktop palette in the relevant mode and then
  3120. feed this into ColourTrans, but this would be a rather tedious process.)
  3121. Hugh Eagle
  3122. 4.9
  3123. Impression HintsáandáTips
  3124. 4.9
  3125. Å   Adding fonts by using search & replace Ö As a mathematics and physics
  3126. teacher, I use a lot of Greek letters and it is rather bothersome to
  3127. have to work through all those menus to reach the effect öGreekò every
  3128. time. Therefore, I use search & replace in a way which (at least in the
  3129. Impression Junior handbook) is not documented:
  3130. 4.9
  3131. I type the text, using the Latin equivalents of the Greek letters (ög-
  3132. Quantò instead of ög-Quantò) then, when I have finished the text, I use
  3133. the following:
  3134. 4.9
  3135.    Find: g-Quant
  3136. 4.9
  3137.    Replace: g-Quant
  3138. 4.9
  3139. Impression does the rest. (Many thanks to Computer Concepts for the
  3140. information!)
  3141. 4.9
  3142. By the way, if you wish to find out how all the other effects are saved
  3143. in an Impression document, there is an easy way to find out: Just take a
  3144. document with lots of effects and save only the text story (öwith
  3145. effectsò). If you then drag the icon of the saved text story onto the
  3146. !Edit icon, the text will appear with all the effects in plain language. 
  3147.  Jochen Konietzko, Koeln, Germany
  3148. 4.9
  3149. (Wouldnæt it be easier to use <ctrl-F6> and edit the öGreekò style, go
  3150. down to the bottom where it says öKey short-cutò, click in the box and
  3151. press, say, <ctrl-shift-F9>, then OK it? Then when you want, say, ög-
  3152. Quantò, you type ö<ctrl-shift-F9>g<ctrl-shift-F9>-Quantò.... Oh, I see,
  3153. Impression Junior doesnæt have styles. Oh well, nice try!)
  3154. 4.9
  3155. Å   Cutting invisible text Ö If you have more text in a frame than will
  3156. fit, you get the little red arrow which indicates that some of the text
  3157. is invisible. You could obviously create a new frame, click on the over-
  3158. full frame and then click <adjust> on the new frame but there may still
  3159. be too much for that frame. So, is there any way of marking the
  3160. invisible text so that you can cut it or copy it? The answer is that you
  3161. simply use <ctrl-down> to move the cursor to the (invisible) bottom of
  3162. the text the click <adjust> to indicate the upper limit of the area to
  3163. be marked. Ed.
  3164. 4.9
  3165. Å   Handy hint Ö If you use the Éhandæ to move up or down through a long
  3166. document, you are not limited in your movements to the visible page. In
  3167. other words, if you keep moving the mouse up and up (by repeatedly
  3168. lifting the mouse off the table) or down and down, you just keep moving
  3169. through the document in the desired direction. (This is particularly
  3170. useful if you are a trackerball user!) Ed.
  3171. 4.9
  3172. Å   Importing text files into Impression Ö In the new version of Impres
  3173. sion which CC have just sent me (version 2.11), I have discovered an
  3174. exciting new concept in the Archimedes world Ö öthe Return Stripperò!!
  3175. 4.9
  3176. In the Extensions directory is a new loader module called öLoadReturnò
  3177. which at last seems to deal satisfactorily with the importing of text
  3178. files. Using this, I no longer have to load the file into !Edit then
  3179. change linefeeds into carriage returns before importing. Nor do I have
  3180. to suffer fixed line lengths in the imported text.
  3181. 4.9
  3182. However, I do have two quibbles (some people are never satisfied!):
  3183. 4.9
  3184. Double carriage returns are reduced to single returns, so spaces between
  3185. paragraphs are eliminated (unless you change the style so that it leaves
  3186. such a space Ö which I think is good practice. Ed). I feel it would be
  3187. helpful to be able to set a öpreferenceò to decide whether or not double
  3188. returns are preserved.
  3189. 4.9
  3190. Importing a text file now involves a somewhat tiresome sequence of
  3191. message windows whereby I am asked to accept or reject each of the
  3192. available loader modules in turn. I feel it would be helpful to be able
  3193. to use the öpreferenceò facility either to define which loader is used
  3194. for which filetype or, at the very least, to determine the order in
  3195. which the various loader options are offered to me. Hugh Eagle.
  3196. 4.9
  3197. (All I did was to put the LoadReturn extension into the Auto directory
  3198. in the Impression directory and now when I want files stripping, I use
  3199. !Settype (Shareware 19 or 23) to change them to Acorn data file type
  3200. (&FFD) and they are stripped automatically. Ed.)
  3201. 4.9
  3202. Å   Labels & Tickets Ö Another way of doing tickets and labels is to
  3203. define a new master page which is the right size for what you want to
  3204. create (pretty radical, eh?). öFit lotsò still works, giving you
  3205. multiple tickets per sheet, but youære not restricted to 1% size
  3206. increments which can cause you to miss the boundaries on sticky labels,
  3207. especially where there are three or four across the page width.
  3208. (Brilliant! Why didnæt I think of that? Ed. Ö see below.)
  3209. 4.9
  3210. A similar technique works for cassette inlays. One way is to define a
  3211. single master page 101mm deep and 288mm wide, divided into columns of
  3212. 16, 12, 65, 65, 65 and 65mm; this format will fit two inlays to an A4
  3213. page (assuming zero border width, which will vary between printers), but
  3214. you need to fiddle around with !FontDraw and !Draw (Or use Draw1╜ Ö see
  3215. below. Ed) to get text on the spine of the cassette. Starting with a
  3216. page 288mm deep and 101mm wide gives you the spine text a sensible way
  3217. round, but the four öbodyò pages are then landscape, which you may not
  3218. want.
  3219. 4.9
  3220. Another way is to split the inlay into two chapters; the spine has a
  3221. 101mm wide, 28mm high master page, and the body pages are 65mm by 101mm,
  3222. or vice versa if you want landscape. Then you need to do a bit of
  3223. cutting and pasting by hand, as Impression wonæt print individual pages
  3224. sideways. This is the technique I ended up by using, printing at 141%
  3225. then reducing the pasted-up result from two up on A3 back down by 70% to
  3226. A4, thus enhancing the graphics halftones from 37.5 dpi to 53.6 dpi.
  3227. Iæve included an example ... (Which we have put on the Monthly Program
  3228. Disc. Ed) Jonathan Oakley, Cambridge.
  3229. 4.9
  3230. Å   Labels & tickets Ö Edæs version Ö I have played a bit with Jonathanæs
  3231. ideas and developed them a little. I tried to create some labels (like
  3232. the ones on our Shareware Discs etc which come as 24 to an A4 page) and
  3233. found that his method worked very well. I created a master page that was
  3234. 70mm x 37.125mm (which is 210mm divided by 3 horizontally and 297mm
  3235. divided by 8 vertically). I set a border 3mm wide on all four sides
  3236. because the Laser Direct HiRes can print up to about 2.5mm of the edge
  3237. of the page and I wanted to have a simple line border around my labels.
  3238. I put all my text on the master page including a page number so that I
  3239. could have a serial number on the labels. I then closed the master page
  3240. and created another 23 pages for my document by using <menu> Edit Ö
  3241. Insert new page. I clicked 22 times with <adjust> so that the menu
  3242. stayed on screen and once with <select>. I then pressed <print> and
  3243. clicked on öFit lotsò and then öSetup...ò and then öIgnore page borderò.
  3244. The printout which appeared was almost right but was 1mm too far to the
  3245. right, 1mm too low at the top and the last label was even lower. (Thinks
  3246. hard.... tries various things and then....) The printout was slightly
  3247. too long so I created a slightly shorter master page Ö 70mm x 37.11mm. I
  3248. tried to see if there was any adjustment on the laser printer but
  3249. couldnæt find any so I went to the (new, shorter) master page, clicked
  3250. on the frame and pressed <ctrl-F10> to alter the frame. In the position
  3251. section, I simply increased X from 5 to 6 and reduced Y from 5 to 4 in
  3252. order to move the text on the page 1 mm right and 1 mm up. Bingo! Every
  3253. border on every label was almost exactly 5mm.
  3254. 4.9
  3255. I also had a quick try with Jonathanæs cassette inlay printing and it is
  3256. really very easy with his first method Ö I cheated though by using
  3257. Draw1╜ (Shareware 34). For the spine, all you do is create a new Draw1╜
  3258. document, type in the text you want, change it to whatever font you are
  3259. using, press <menu> Ö Special Ö Text to path and then <menu> Ö Save Ö
  3260. Selection and drop the Draw file produced into the relevant graphics
  3261. frame in your Impression document. Then use <adjust> to drag the picture
  3262. round until it is near enough at right angles to the rest of the text
  3263. (having decided which way you want it to face) and finally press <ctrl-
  3264. F11> (Alter graphic) and set the Angle to exactly 90░ or 270░. (If you
  3265. can remember which way round 90░ or 270░ puts it, then thereæs no need
  3266. to swing it round with <adjust>.) Here is a bit of text that I have just
  3267. inserted. It must have taken me all of 45 seconds to create the frame,
  3268. type in the text, convert it and add it in! (Software to enable me to do
  3269. that on the Mac cost me hundreds of pounds a couple of years ago!)
  3270. 4.9
  3271. Å   öRunningò an Impression document Ö In Alan Highetæs review of !Menon
  3272. on Shareware 38 (Archive 4.8 page 48) he mentions that it did not work
  3273. well with Impression documents since an attempt to örunò one of these
  3274. caused a second copy of Impression to appear on the icon bar.
  3275. 4.9
  3276. I have observed a similar phenomenon in trying to create a front-end for
  3277. Impression which, amongst other things, opens a template document chosen
  3278. by the user. Simply *Running the document results in the loading of a
  3279. new copy of Impression regardless of whether one is already running.
  3280. 4.9
  3281. So, why is it that double-clicking on an Impression document in a Filer
  3282. window will load it into an existing copy of Impression whereas
  3283. örunningò it doesnæt?
  3284. 4.9
  3285. Mark Neves of Computer Conceptsæ Technical Support Department has kindly
  3286. explained why this happens and has pointed to a solution.
  3287. 4.9
  3288. The reason is that what happens when you double click on an icon in a
  3289. Filer window is not simply that the document is örunò. First, the Filer
  3290. broadcasts a Message_DataOpen message inviting other applications to
  3291. open the document, and only if this message is returned unacknowledged
  3292. does it instigate a *Run.
  3293. 4.9
  3294. The solution is a fairly simple program on the following lines:
  3295. 4.9
  3296. REM >!RunImage
  3297. 4.9
  3298. TaskName$=öRunImpDocò
  3299. 4.9
  3300. :
  3301. 4.9
  3302. PROCSetUpWimp
  3303. 4.9
  3304. DocToOpen$=FNReadOSVarVal
  3305. 4.9
  3306. (öDoc$ToOpenò)
  3307. 4.9
  3308. PROCPollLoop
  3309. 4.9
  3310. SYS öWimp_CloseDownò,Taskid% ,&4B534154
  3311. 4.9
  3312. IF NotAcknowledged% THEN OSCLI(öRun ò+DocToOpen$)
  3313. 4.9
  3314. END
  3315. 4.9
  3316. :
  3317. 4.9
  3318. DEF PROCPollLoop
  3319. 4.9
  3320. LOCAL mask%,quit%
  3321. 4.9
  3322. NotAcknowledged%=FALSE
  3323. 4.9
  3324. PROCSendDataOpenMessage
  3325. 4.9
  3326. mask%=0
  3327. 4.9
  3328. quit%=FALSE
  3329. 4.9
  3330. REPEAT
  3331. 4.9
  3332. SYS öWimp_Pollò,mask%,block% TO reason%
  3333. 4.9
  3334. CASE reason% OF
  3335. 4.9
  3336. WHEN 17,18 : IF block%!16=4 THEN quit%=TRUE
  3337. 4.9
  3338.  REM Another task (presumably
  3339. 4.9
  3340.  REM Impression) has acknowledged
  3341. 4.9
  3342.  REM our request to load a file.
  3343. 4.9
  3344. WHEN 19  : NotAcknowledged%=TRUE:quit%=TRUE
  3345. 4.9
  3346.  REM Our request has not been acknowledged.
  3347. 4.9
  3348. ENDCASE
  3349. 4.9
  3350. UNTIL quit%
  3351. 4.9
  3352. ENDPROC
  3353. 4.9
  3354. :
  3355. 4.9
  3356. DEF PROCSendDataOpenMessage
  3357. 4.9
  3358. !block%=256
  3359. 4.9
  3360. block%!12=0:block%!16=5:block%!20=0
  3361. 4.9
  3362. block%!28=0:block%!32=0:block%!36=0
  3363. 4.9
  3364. block%!40=&2000
  3365. 4.9
  3366. $(block%+44)=DocToOpen$
  3367. 4.9
  3368. ?(block%+44+LEN(DocToOpen$))=0
  3369. 4.9
  3370. SYS öWimp_SendMessageò,18,block%,0
  3371. 4.9
  3372. ENDPROC
  3373. 4.9
  3374. :
  3375. 4.9
  3376. DEF PROCSetUpWimp
  3377. 4.9
  3378. DIM block% &1000,errblk% 256
  3379. 4.9
  3380. REM Taskid%=FNWimpInit(200,TaskName$)
  3381. 4.9
  3382. SYS öWimp_Initialiseò,200, &4B534154,TaskName$ TO Version%,Taskid%
  3383. 4.9
  3384. ON ERROR PROCError(TaskName$)
  3385. 4.9
  3386. ENDPROC
  3387. 4.9
  3388. :
  3389. 4.9
  3390. DEF FNReadOSVarVal(varname$)
  3391. 4.9
  3392. LOCAL temp1%,temp2%,length%
  3393. 4.9
  3394. DIM temp1% 100,temp2% 100
  3395. 4.9
  3396. $temp2%=varname$
  3397. 4.9
  3398. SYS öOS_ReadVarValò,temp2%,temp1%, 100,0,3 TO ,,length%
  3399. 4.9
  3400. temp1%?length%=13
  3401. 4.9
  3402. var$=$temp1%
  3403. 4.9
  3404. =var$
  3405. 4.9
  3406. :
  3407. 4.9
  3408. DEF PROCError(TaskName$)
  3409. 4.9
  3410. !errblk%=ERR
  3411. 4.9
  3412. $(errblk%+4)=REPORT$+ö at line ò+ STR$ERL
  3413. 4.9
  3414. errblk%?(4+LEN$(errblk%+4))=0
  3415. 4.9
  3416. SYS öWimp_ReportErrorò,errblk%,1, TaskName$
  3417. 4.9
  3418. SYS öWimp_CloseDownò,Taskid%, &4B534154:END
  3419. 4.9
  3420. ENDPROC
  3421. 4.9
  3422. To use this program, simply set up the OS variable Doc$ToOpen with the
  3423. full pathname of the document and run the program. Hugh Eagle
  3424. 4.9
  3425. Å   Setting a style in an Impression frame Ö Question: how do I set up a
  3426. blank frame containing a predetermined style (for instance, to hold the
  3427. address of the person I am writing to, where I would like to use a
  3428. different font from the one in the body of the letter)? If I put the
  3429. cursor in the frame, then apply the style, then move the cursor
  3430. elsewhere (or save and reload the document) before bringing it back to
  3431. the address frame, and then start typing, the text comes up in the
  3432. Basestyle.
  3433. 4.9
  3434. Answer: If after applying the style, I type anything (for instance a
  3435. couple of carriage returns) in the address frame then the applied style
  3436. seems to be remembered and the address frame works as intended.
  3437. 4.9
  3438. Caution: if I delete the entire contents of the frame the applied style
  3439. is deleted too. So, if I want to blank the frame for reuse I have to
  3440. remember to leave a carriage return or two to preserve the style. Hugh
  3441. Eagle.
  3442. 4.9
  3443. Å   Typesetting Ö We said we would try to find companies willing to do
  3444. typesetting from Impression output. Here are two that we have found. If
  3445. you discover others, ask them to send us details of their services and
  3446. we will publish them. We are particularly interested in those that will
  3447. take Impression files as such rather than PostScript files on MS-DOS
  3448. discs.
  3449. 4.9
  3450. The Type Station in Cardiff offers a full bureau service for bromide or
  3451. film. You create PostScript files and either send them by post on an MS-
  3452. DOS disc or send them c/o BT using a modem. For details, contact Elgan
  3453. Davis on 0222Ö229977.
  3454. 4.9
  3455. Focus Print in Aberdeen can do bromides (PMTæs) from your Impression
  3456. files. Phone Alexander Bisset on 0224Ö592571 ext 211 (or 0224Ö593956
  3457. evenings).ááA
  3458. 4.9
  3459.  
  3460. Hints and Tips
  3461. 4.10
  3462. Å   *Count command Ö In Archive 4.6 p8 the hint about *Count, is only
  3463. partly right. The *Count command only counts data. This means that
  3464. directories indeed donæt contribute, but also that only the amount of
  3465. data in a file is counted. However, all files must be an integer
  3466. multiple of the block-size (1k for D and E format), and for short files
  3467. this makes a huge difference. My 46Mb hard disc has about 8Mb difference
  3468. between space used from *Free and from *Count for these reasons!
  3469. 4.10
  3470. One implication of this is that when you archive a large number of small
  3471. files with !Spark you can save much more disc space than you might
  3472. expect. One thing I would suggest for hard disc users is to copy the
  3473. directory tree using *Copy :4.$ :0 T R, and then archive it, which will
  3474. compress it down to almost nothing. Think of all the time you spend
  3475. setting up the directory structure; this may be more important than
  3476. losing files, most of which you will (should?), after all, have on
  3477. floppies. As an added bonus this also gives you the location of all
  3478. applications, as these are just directories. If (perish the thought) you
  3479. have a disc crash, you can just drag the tree out of the archive and
  3480. onto a new hard disc.  Stephen Burke, Liverpool.
  3481. 4.10
  3482. Å   DataLoad problems? Ö The PRM says that if a DataLoad message isnæt
  3483. acknowledged, the sending task should delete <Wimp$Scrap> and give an
  3484. error. However, I think this is wrong. You arenæt guaranteed that the
  3485. scrap file used is, in fact, <Wimp$Scrap>. One case where this must
  3486. happen is with an application which can both load and save files of the
  3487. same type at the same time; it must not use <Wimp$Scrap> for both, or it
  3488. might get very confused! However, there might be other reasons. I
  3489. therefore think you should remember the name of the file you saved, and
  3490. delete that Ö you get told that it wasnæt a secure file, so this should
  3491. be safe.  Stephen Burke, Liverpool.
  3492. 4.10
  3493. Å   Hard Drive problems Ö BEWARE!!! If you have a fairly old computer Ö a
  3494. 310 or a 440 or even a vintage 410/1 or if you are working in a dusty
  3495. environment and you are putting in a new hard drive, check/replace the
  3496. fan filter. Why? Well, drive suppliers tell us that on more than one
  3497. occasion they have had a computer where the fan filter was blocked up
  3498. with dust, the customer has installed a new drive and not changed the
  3499. filter and, as a result of the lack of airflow, the drive has suffered a
  3500. fatal head crash. So, you have been warned. (Fan filters should be
  3501. available öfrom your local Acorn dealerò or they can be bought from
  3502. N.C.S. as part of an öAnnual Service Kitò Ö including a new pair of
  3503. batteries Ö priced ú3.)
  3504. 4.10
  3505. Å   How long is a line? Ö While editing an old program which I was
  3506. converting from the BBC Master to run on the Archimedes, I came across
  3507. some features of Basic line lengths which may be of interest. The
  3508. program was originally written for the BBC-B with the longest possible
  3509. lines to save space.
  3510. 4.10
  3511. On Page 16 of the ÉBasic User Guideæ issue 1 dated 1988, it says ÉA line
  3512. of Basic can contain up to 238 characters...æ but on page 386 it says
  3513. that ÉAs in a Basic program, the length of a line is limited (by the
  3514. Basic Editor) to 251 characters..æ. This implies that the system has two
  3515. different ideas of what the maximum line length should be, instead of
  3516. one. Unfortunately, the one it uses seems to depend on what you are
  3517. doing.
  3518. 4.10
  3519. My module ARMBasicEdit (version 1 21 August 87) allows the insertion of
  3520. many more than 238 characters in a line. I can get up to 369 before
  3521. there is a warning bell, but then neither <Escape> nor <Return> nor SAVE
  3522. work until there are only the 251 characters left. Programs containing
  3523. lines of length between 239 and 251 apparently run without problems.
  3524. However, if you try editing the lines with Basic loaded, just using the
  3525. Copy key, you find that there is a warning bell after 239 characters,
  3526. (excluding the line number), not after 251.
  3527. 4.10
  3528. Programs with lines longer than 239 characters can be converted to ASCII
  3529. using *SPOOL. However, when you attempt to read them back into a Basic
  3530. program using *EXEC, the lines are truncated to 239, so that the program
  3531. no longer runs. There is a warning bell but the *EXEC process does not
  3532. stop, so not allowing me to find which lines are at fault. I find this
  3533. very frustrating. The file Btest, on the monthly disc, is an example of
  3534. such a program. The file ÉCHECK240æ is a small program which reads a
  3535. file made using *SPOOL which cannot be successfully read back using
  3536. *EXEC. It lists the line numbers which are too long, allowing me to edit
  3537. them with the Basic Editor.
  3538. 4.10
  3539. CHAINöBtestò to see that it runs. Then try
  3540. 4.10
  3541. *SPOOL TEMP
  3542. 4.10
  3543. LIST
  3544. 4.10
  3545. *SPOOL
  3546. 4.10
  3547. *EXEC TEMP
  3548. 4.10
  3549. CHAIN öCHECK240ò
  3550. 4.10
  3551. and reply öTEMPò at the prompt. Kate Crennell, Didcot.
  3552. 4.10
  3553. Å   Printer drivers Ö Further to recent tips about altering the PrData
  3554. file within the printer driver, you can also alter the title of your
  3555. preferred driver and make it the default driver on loading. For example,
  3556. the amendments to !PrinterDM in Archive 4.8 could be made to read öStar
  3557. LC24-10ò by altering the line before the line öprinter number:2ò. The
  3558. default loading is achieved by amending the line öprinter:01ò to
  3559. öprinter:02ò. This line is found towards the end of the data file
  3560. immediately before the line ölocation:1ò. Note that the printer number
  3561. must be padded out with a zero (0). Pressing <select> after loading the
  3562. driver will confirm if your amendments have been correctly made.  Ted
  3563. Lacey, Southampton.
  3564. 4.10
  3565. Å   Printing A5 on an A4 printer Ö If you ask the manufacturers, they say
  3566. it is not possible to put A5 paper through either the Qume (300 d.p.i.)
  3567. or the Canon (600 d.p.i.) Laser Directs Ö or the LBP4æs for that matter
  3568. Ö but it is possible. All you need is a pile of A5 sheets of scrap paper
  3569. sellotaped up into a solid block about ╜ö thick (or ╛ò thick for the
  3570. Canons). You put them at the back of the A4 paper tray and put the A5
  3571. paper, sideways, of course, at the front. The paper usually goes through
  3572. OK but does occasionally stick. All you have to be careful of, presum
  3573. ably, is that you donæt print on the lower half of the (A4) paper that
  3574. is not actually there. Having said that, I have been using A5 paper on
  3575. Qumeæs, Canons and Mac Laserwriters for years and have occasionally left
  3576. the öA5ò tray in when printing A4 without any obvious damage to the
  3577. printers.
  3578. 4.10
  3579. We can now get hold of spare paper trays for Qume (ú66) and Canon LBP4
  3580. (ú57) and Canon LBP8 (ú54)
  3581. 4.10
  3582. (A possible alternative to the paper is a block of wood the same size
  3583. and thickness but I havenæt actually tried it.)
  3584. 4.10
  3585. Å   Psychedelic sound-to-light Ö Whilst playing a Tracker module, it is
  3586. possible to obtain some interesting effects on your monitor by typing
  3587. the following Basic command:
  3588. 4.10
  3589. SYS öOS_UpdateMEMCò,768,1792
  3590. 4.10
  3591. The screen can be returned to normal with either a MODE command or with:
  3592. 4.10
  3593. SYS öOS_UpdateMEMCò,1536,1792
  3594. 4.10
  3595. Rob Swain, Kent
  3596. 4.10
  3597. Å   Render Bender on SCSI hard disc drives revisited Ö In Archive 3.11 p6,
  3598. Neil Berry explains how to use Render Bender on SCSI hard disc drives
  3599. but leaves us with the problem of how to use *KILLADFS. This can be
  3600. achieved by changing all references made to SWI ADFS_Drives (&40242) to
  3601. SWI SCSI_Drives (&403C6). i.e.
  3602. 4.10
  3603. In the ÉRenderæ Basic listing: change the SWI &40242 to &403C6 in line
  3604. 15810
  3605. 4.10
  3606. In ÉAnirouteæ Basic listing: change the SWI &40242 to &403C6 in line
  3607. 6670
  3608. 4.10
  3609. Atle Mjelde Bσrdholt, Norway
  3610. 4.10
  3611. Å   Running one application inside another Ö The comment in Archive 4.9
  3612. page 6 seems to need some amplification. As explained on page 11 of the
  3613. May/June 1991 issue of öThe Archimedeanò from Computer Concepts, if you
  3614. want to run one application from inside the !Run file of another, you
  3615. should first enter the command
  3616. 4.10
  3617. *Desktop Run <sibling task name>
  3618. 4.10
  3619. and then repeat the *Wimpslot command from earlier in the !Run file to
  3620. ensure that there is enough memory available for the main application
  3621. before you run it.
  3622. 4.10
  3623. Thus, for example, to make Impression automatically load a printer
  3624. driver whenever it is run you should edit the !Impress.!Run file by
  3625. inserting two extra lines immediately before the last so that the last
  3626. three lines read:
  3627. 4.10
  3628. Desktop Run [...path...].!PrinterXX
  3629. 4.10
  3630. Wimpslot Ömin xxxK Ömax xxxK
  3631. 4.10
  3632. Run ö<Impression$Dir>.!RunImageò %*0
  3633. 4.10
  3634. The xxxK in the Wimpslot command should be exactly the same as used
  3635. earlier in the !Run file Ö the precise amount of memory needed will vary
  3636. from one version of Impression to another. Hugh Eagle, Horsham.
  3637. 4.10
  3638. Å   Sound improvements Ö A much improved sound, which is also more
  3639. controllable, can be obtained using the standard colour monitor supplied
  3640. with the Archimedes. A 3.5mm jack (Archimedes) to phono (monitor) cable
  3641. is required, and the speaker on the Archimedes should be turned off
  3642. using *SPEAKER OFF.  Sean Kelly, London
  3643. 4.10
  3644. Å   Sound voice changes Ö Among the (many) things that annoy me are those
  3645. professional programmers who alter your Sound Voice for their games
  3646. which otherwise claim to be öRISC-OS Compatibleò. They return you to the
  3647. desktop with their Sound Modules set up as ChannelVoice 1. Not everyone
  3648. likes the WaveSynth-Beep as default voice, and as for some of the sound
  3649. modules or digitised Voice Modules which are then sounded when an error
  3650. occurs, YUK!
  3651. 4.10
  3652. It is quite a simple matter to find out what ChannelVoice the user has
  3653. set up and the program could very easily, before exiting to the desktop,
  3654. restore it using the following code which is available for all program
  3655. mers to use, professional or amateur (please!).
  3656. 4.10
  3657. REM Find the Useræs ChannelVoice 1
  3658. 4.10
  3659. SYS öSound_AttachVoiceò,1,0 to ,user_voice%
  3660. 4.10
  3661.  
  3662. 4.10
  3663. REM Because ChannelVoice 1 now equal to 0, reset
  3664. 4.10
  3665. SYS öSound_AttachVoiceò,1,user_voice%
  3666. 4.10
  3667. REM Rest of program, Wimp Interface, whatever
  3668. 4.10
  3669. *ChannelVoice 1 Totally Fantastic Voice
  3670. 4.10
  3671.  
  3672. 4.10
  3673. REM Program at end, restore user voice
  3674. 4.10
  3675. SYSöSound_AttachVoiceò,1,user_voice%
  3676. 4.10
  3677. David Shepherdson
  3678. 4.10
  3679. Å   Toolkit Plus update Ö Claresæ Toolkit Plus usually produces a ÉBad
  3680. disc addressæ error when you try to edit E format floppy discs. This can
  3681. be rectified by performing the following:
  3682. 4.10
  3683. 1   RMLoad the Toolkit Plus module.
  3684. 4.10
  3685. 2   Type: *Modules <return> and take note of the Épositionæ address of the
  3686. Toolkit Plus module.
  3687. 4.10
  3688. 3   Use *WFIND &EF060240 <return> and ignore the first occurrence (i.e.
  3689. press <ctrl-tab> to go on to the next occurrence).
  3690. 4.10
  3691. 4   Locate the instruction seventeen lines down which reads BCC xxxxx.
  3692. 4.10
  3693. 5   Select Éword modeæ and zero this instruction.
  3694. 4.10
  3695. You should now be able to edit E format discs.
  3696. 4.10
  3697. S Edwards, Wordsley
  3698. 4.10
  3699. Å   Toolkit Plus with SCSI Ö Claresæ Toolkit Plus provides a disc sector
  3700. editor, which refused to work on my SCSI hard disc. A modified Toolkit
  3701. Plus may be produced by using !Edit on the Toolkit Plus module to
  3702. replace all occurrences of ÉADFSæ with ÉSCSIæ before saving the module
  3703. with a new name e.g. SCSITools.
  3704. 4.10
  3705. A drawback is that the modified version will not cope with ADFS
  3706. floppies. Changing the module name (e.g. from ÉToolkit+æ to ÉSCSIToolsæ)
  3707. using !Edit allows the modified and original modules to be present at
  3708. the same time, and changing the disc edit command names allows both ADFS
  3709. and SCSI discs to be edited Ö for instance, !Edit could be used to
  3710. replace ÉAEDITæ in Toolkit+ with ÉWEDITæ in SCSITools.
  3711. 4.10
  3712. Sean Kelly, London
  3713. 4.10
  3714. Impression HintsáandáTips
  3715. 4.10
  3716. Å   Abbreviations Ö I use abbreviations quite a lot such as öimpò for
  3717. Impression and just örò for Archimedes but I often want to say, for
  3718. example öá...using DrawPlus (Careware 13)...ò and although öcaò and öCaò
  3719. are both set up to expand to öCarewareò, using ö(caò doesnæt work. There
  3720. is no easy way round it as far as I know Ö you just have to put ö(caò
  3721. into the abbreviations dictionary to expand to ö(Carewareò.
  3722. 4.10
  3723. Å   Bullets Ö Weæve mentioned that <ctrl-shift-H> produces a bullet but
  3724. since <backspace> (immediately below <F12> and above <\>) produces the
  3725. same ASCII code as <ctrl-H>, you will find that <shift-backspace>
  3726. produces a bullet. Touch typists may well find it somewhat more natural
  3727. than <ctrl-shift-H>.
  3728. 4.10
  3729. Å   Creating tables Ö The release notes issued with Impression II describe
  3730. the new features of version 2.12 but they do less than justice to one of
  3731. those features, namely the capacity to create tables. It is possible to
  3732. vary the width of individual columns and individual rows in a table as
  3733. well as the thickness of the vertical and horizontal lines which form
  3734. the table.
  3735. 4.10
  3736. In addition, the many editing facilities of Impression can be used to
  3737. modify text which has been entered into the table so that the style and
  3738. size of the characters in any öcellò of the table can be varied as
  3739. desired.
  3740. 4.10
  3741. Moreover, in the manner usual with Impression II, another frame can be
  3742. superimposed on any selected part of the table with the effect that
  3743. lines of the table can be covered and will ödisappearò permitting text
  3744. of any size and nature to be introduced and adjusted to appear to be a
  3745. part of the structure of the table.
  3746. 4.10
  3747. In addition to text, any of the superimposed frames can be made graphics
  3748. frames permitting illustrations to be introduced. You can use left hand
  3749. tabulation in the some columns, right hand tabulation in others and
  3750. decimal point tabulation in others.
  3751. 4.10
  3752. Practical matters: First construct the empty table. Then determine which
  3753. cells will be visible in the completed table and enter text into those
  3754. cells, Finally, superimpose other frames as required. Proceeding in this
  3755. order prevents interference with tabulation.
  3756. 4.10
  3757. The usual procedure will be to construct a table of this kind within a
  3758. frame of its own so that it can be moved as a whole to any desired
  3759. position within the document of which it will form a part. Therefore, on
  3760. completion of the table, the various frames of which it is composed
  3761. should be Grouped so that the table occupies a single frame. George
  3762. Foot, Oxted.ááA
  3763. 4.10
  3764.  
  3765. 4.10
  3766.  
  3767. 4.10
  3768.  
  3769. 4.10
  3770. Oak
  3771. 4.10
  3772. From 4.9 page 12
  3773. 4.10
  3774.  
  3775. 4.10
  3776. Lindis International
  3777. 4.10
  3778. From 4.8 page 16
  3779. 4.10
  3780.  
  3781. 4.10
  3782. Computer Concepts
  3783. 4.10
  3784. New artwork
  3785. 4.10
  3786. Coming direct to you, hopefully!
  3787. 4.10
  3788. If not, use old one.
  3789. 4.10
  3790.  
  3791. 4.10
  3792. Computer Concepts
  3793. 4.10
  3794. New artwork
  3795. 4.10
  3796. Coming direct to you, hopefully!
  3797. 4.10
  3798. If not, use old one.
  3799. 4.10
  3800.  
  3801. 4.10
  3802. Graphics Galore on the Cheap!
  3803. 4.10
  3804. Tord Eriksson
  3805. 4.10
  3806. Reading with amazement about the latest version of Ventura Publisher Mac
  3807. that costs a cool ú695 (exclusive VAT!) and so-called Ébudgetæ DTP
  3808. programs for IBMs weighing in at ú70 to ú160, I wonder if we Archimedes
  3809. users really know how fortunate we are when it comes to good, cheap
  3810. software.
  3811. 4.10
  3812. The öbudgetò DTP programs for IBMs canæt even word-process Ö you have to
  3813. use a separate editor, just as you have to do if you do some DTP with
  3814. !Draw....
  3815. 4.10
  3816. Of course, the latest version of Ventura Publisher Mac can print fonts
  3817. in 23╜ size instead of just 23 or 24 point size Ö a revolution no doubt
  3818. but one that almost all DTP and word-processors for our Archimedes
  3819. machines manage easily!
  3820. 4.10
  3821. Archimedes Ö no master of colours!
  3822. 4.10
  3823. There is a difference between modern IBMs and Mac IIæs that puts all
  3824. Acorn computers at a disadvantage, even if it was once hailed as an
  3825. advance over said computers: Colours!
  3826. 4.10
  3827. In terms of colour, both Mac II computers and IBMs with VGA are better
  3828. than Archimedes and the sky is the limit as there are hundreds of
  3829. graphics cards that can be bought that improve things further Ö 24-bit
  3830. colours are available.
  3831. 4.10
  3832. RISC-OS has an upper limit of 8 bits per pixel, 256 colours Ö 24 bits
  3833. per pixel gives 16,777,216 different colours, quite a lot more!.
  3834. 4.10
  3835. For the Archimedes range, the limitations are built-in, through RISC-OS
  3836. and the fixed hardware. (There are some improvements possible with
  3837. hardware add-ons, but nothing major).
  3838. 4.10
  3839. Serious DTP is black & white!
  3840. 4.10
  3841. Fortunately, colour printers are very rare in everyday printing, mainly
  3842. due to the fact that such printers are very costly and/or requires
  3843. skilled staff to attend to them.
  3844. 4.10
  3845. So, for practical purposes, DTP will continue to be a mainly black &
  3846. white affair, maybe with some colour thrown in for good measure on
  3847. covers etc.
  3848. 4.10
  3849. The woes of illustrating....
  3850. 4.10
  3851. Being a former technical illustrator, I am painfully aware of the amount
  3852. of work needed to set text in a circular fashion as on a coin or an
  3853. official seal or make the logo on a fluttering flag look like the real
  3854. thing. Hours and hours of work, or in the case of the flag, take a photo
  3855. of the real thing and trace that with tracing paper....
  3856. 4.10
  3857. If the logo is new, you canæt print it first on a flag, so you try to
  3858. make do with crinkling a piece of paper upon which you put your text or
  3859. logo and take a photo of that....
  3860. 4.10
  3861. All this is now of the past, as long as your logo or text can be
  3862. transformed into a !Draw file.
  3863. 4.10
  3864. First Ö !FontFX
  3865. 4.10
  3866. Let us try an example: There used to be an oil company around this part
  3867. of the world called Caltex. Let us say we are going to do a drawing with
  3868. a flag fluttering with that name on it.
  3869. 4.10
  3870. First we have the text, set in Pembroke:
  3871. 4.10
  3872. To make it more interesting letæs add a shadow, with the shadow in the
  3873. north-east, and make the text itself a black outline filled with a light
  3874. grey and behind it, the dark grey shadow:
  3875. 4.10
  3876.  
  3877. 4.10
  3878.  
  3879. 4.10
  3880.  
  3881. 4.10
  3882. Both these operations are very easy to do with !FontFX as you just click
  3883. on the buttons needed, no previous know-how needed!
  3884. 4.10
  3885. To make this flutter we have to use a couple of other utilities:
  3886. !DrawPlus (or !Draw) and DrawBender.
  3887. 4.10
  3888. Warped universe
  3889. 4.10
  3890. A normal picture is plotted in our brain according to the angle we watch
  3891. the picture from: If we fly above a square field the corners are right
  3892. angle corners (a so-called birdæs-eye view) and if we stand just outside
  3893. the field the angles get very odd indeed Ö their sum is still 360,
  3894. though!
  3895. 4.10
  3896. If a square is wrapped around a cylinder things get much more compli
  3897. cated, especially when seen at an angle Ö an illustratoræs nightmare!
  3898. Not even all CAD programs seems to be able to solve it correctly....
  3899. 4.10
  3900. Secondly Ö make a mould!
  3901. 4.10
  3902. DrawBender manipulates !Draw files by plotting them inside each other:
  3903. Any text that is going to be manipulated has to be in !Draw format. The
  3904. coordinate system öinsideò a square is still square but inside a circle
  3905. it takes on the characteristics of a text printed on a balloon like
  3906. this:
  3907. 4.10
  3908.  
  3909. 4.10
  3910.  
  3911. 4.10
  3912.  
  3913. 4.10
  3914.  
  3915. 4.10
  3916. The first (the circle) is called the mould and the second (the square
  3917. inside a frame) is called the object.
  3918. 4.10
  3919. Due to the way DrawBender works, a real circle couldnæt be used Ö it had
  3920. to be substituted it with a 32-sided polygon and it had to be flipped
  3921. over because paths have to be clockwise to work as moulds in DrawBender
  3922. whereas !Draw and !DrawPlus draw counter-clockwise Ö itæs all very well
  3923. explained in the DrawBender manual!
  3924. 4.10
  3925. Wonderful results!
  3926. 4.10
  3927. Taking the text, we put it on rectangular background, to make the
  3928. outline of the flag as the outline of the mould doesnæt show up on the
  3929. finished result:
  3930. 4.10
  3931. This is now our object! A öflapping flagò is our mould:
  3932. 4.10
  3933. Conclusion
  3934. 4.10
  3935. As the end result shows the effect is quite stunning. This amount of
  3936. manipulation is available to IBM users of course Ö I could recommend
  3937. Express Publisher (ú159.95) as the ölow-costò alternative!
  3938. 4.10
  3939. For Archimedes users the cost is just ú21, including two manuals and
  3940. lots of sample files (available from Ian Copestake Software).ááA
  3941. 4.10
  3942.  
  3943. Hints and Tips
  3944. 4.11
  3945. Å   Running applications Ö Carrying on from Hugh Eagleæs tip about running
  3946. one application from inside another, on a A310, if you only have
  3947. floppies and have, say, a DTP !Impression disc with !PrinterDM ,
  3948. !FontDraw and !DrawPlus all at the same level, you can tailor the !run
  3949. file of, say, !Impression to load other applications at the same
  3950. directory level, dependant on memory, by using the command
  3951. 4.11
  3952. *desktop <obey$dir>.^.!second_
  3953. 4.11
  3954. application_name
  3955. 4.11
  3956. the <obey$dir> sets the filing system into the first selected appli
  3957. cation (!Impression.) and the .^. takes it back up to the level you were
  3958. at first! The next application then loads on the desktop ready for use.
  3959. Repeat the line with ö!third_ application_nameò and so on.  Ned Abell
  3960. 4.11
  3961. Å   Colour separations Ö Last month, there was a question from John
  3962. Oversby about a colour separation program for !Draw or sprite files. One
  3963. solution is to use DrawPlus (Careware 13), actually drawing different
  3964. colours on different ölayersò. Another possible solution revolves around
  3965. the Impression Business Supplement which provides colour separation for
  3966. PostScript files. However, the ideal solution is a simple öfilterò
  3967. program which takes in a !Draw file and selects all objects of a
  3968. particular colour and puts them into a new !Draw file. Does anyone know
  3969. of such a program? I would be interested in using this for producing
  3970. double-sided printed circuit boards using !Draw. It is easy to write a
  3971. Basic program to do this starting from the !Draw format as specified in
  3972. the PRM Ö I could even do this myself Ö but making it RISC-OS-ified is
  3973. another matter. Brian Cowan
  3974. 4.11
  3975. Impression H & T
  3976. 4.11
  3977. Å   Business Supplement Ö Like many of you I was excited about the release
  3978. of more software for serious users of Impression II. The addition of the
  3979. mail-merge facility is particularly useful. However, I have noticed that
  3980. it suffers from a problem that early versions of Impression had. Namely,
  3981. using the * print facility causes the print to crash after the first
  3982. document with öInvalid number of output bitsò in multiscan mode. The
  3983. problem is resolved by switching to mode 15. Also, beware of forgetting
  3984. to load your RISC-OS printer driver before requesting a print from
  3985. !Importer. This is because it wonæt warn you that you will receive a
  3986. draft copy Ö and worse, you have to close everything down and start
  3987. again.
  3988. 4.11
  3989. Another word of warning to those of you planning to buy the supplement
  3990. thinking that the WordStar loader will solve all your translation
  3991. problems Ö it doesnæt (not on my version, anyway)! If I had thought
  3992. about it, the result one gets is obvious. All the ASCII spaces that mess
  3993. up justification are stripped Ö but this is at the cost of losing a
  3994. space at the end of a line. Consequently, numerous words are joined
  3995. together. If you are prepared to use the spellchecker to separate the
  3996. words again the utility is fine and it does stop those messy spaces
  3997. appearing whenever you make an alteration to the text. However, itæs
  3998. still hard work!  John Brocks
  3999. 4.11
  4000. Å   Font usage Ö Is there a product or would someone like to write an
  4001. application which takes an Impression document and tells you what
  4002. fontsáare required? The reason for this is that some PD software
  4003. includes documentation prepared in Impression format. This is a great
  4004. idea but sometimes strange fonts are used. If you are using Adrian
  4005. Lookæs !FontDir (Shareware 36) then you need to know which fonts are
  4006. needed before Impression is booted up. Brian Cowan
  4007. 4.11
  4008. That should be easy enough. If you want to do it manually, you can save
  4009. the text of an Impression document with styles and look at it in Edit.
  4010. You can search for öfont  ò and look through all the references to
  4011. particular fonts as they occur in the style definitions and as effects
  4012. within the text. Mind you, that will give you the fonts that appear
  4013. within the style definitions regardless of whether those styles have
  4014. actually been used in the document. Anyone want to have a go at writing
  4015. such an application?
  4016. 4.11
  4017. Is anyone interested in / able to convert between the Impression
  4018. Document Description File format and TeX? I think it should be possible
  4019. since both contain the same sort of information. This would be useful
  4020. for scientific applications where many journals accept material on disc
  4021. or by wire in TeX format. Brian Cowan
  4022. 4.11
  4023. Å   Labels and tickets Ö When I was printing video cassette labels onto a
  4024. roll of adhesive labels they were printing too far to the right. I
  4025. failed to understand that !Impression is smart and says, öright, you are
  4026. printing a document 165mm wide. I will print it 82.5mm to the right and
  4027. left of the centre line of the printerò. I have a mark on the case of my
  4028. Citizen 120D printer to align the left hand side of A4 paper, when
  4029. putting in individual sheets but I canæt centre different rolls of
  4030. labels accurately without putting several marks on the case which would
  4031. be confusing so I got round the problem by designing new master pages
  4032. that are always A4 width (210 mm) and creating a frame on that page that
  4033. is the right width for the labels and off centred to the left. I
  4034. continue to put the label roll edge to the mark.
  4035. 4.11
  4036. I then had to change the !Printer DM page size to one 102mm by 210mm
  4037. wide which gives me the the right ögreyingò on the screen as I have
  4038. öPreferencesò, öShow page bordersò, switched on. This prints two perfect
  4039. sets of labels but I still get unwanted form feeds at the end of the
  4040. page! (Example supplied on monthly program disc.)  Ned Abell
  4041. 4.11
  4042. Å   Retaining styles Ö Hugh Eaglesæs question about setting a style in a
  4043. blank Impression frame (Archive 4.9 p11) can be answered in terms of
  4044. ÉPlace holdingæ in the same way as my hint on re-aligning lines starting
  4045. with a different font (Archive 4.8 page 11). Just set the style and type
  4046. a Énullæ character in the frame (i.e. one which is not defined in the
  4047. font you are using) by using Alt and the keypad numbers. (EFF fonts are
  4048. rapidly filling up, making null characters harder to find, but try 136
  4049. or 139.) Bruce Goatly
  4050. 4.11
  4051. Å   Un-deleting Ö As you probably know, you can highlight a passage, type
  4052. over it and thereby replace it. Well, if you have second thoughts
  4053. immediately afterwards, you can restore the original by highlighting the
  4054. replacement passage and typing <ctrl-V>. This deletes the replacement
  4055. altogether rather than cutting it to the clipboard; the clipboard still
  4056. contains the original version. Bruce GoatlyááA
  4057. 4.11
  4058.  
  4059. 4.11
  4060. Help!!!!
  4061. 4.11
  4062. Å   Mac Scanner Ö Does anybody know of software to use a Mac AppleScanner
  4063. with a SCSI interface on an Archimedes? Brian Cowan
  4064. 4.11
  4065. Å   Podule expansion Ö Does anyone know of an expansion box which allows
  4066. more than 4 podules to be attached to an Archimedes computer at any one
  4067. time? A G Duckett, Telford.ááA
  4068. 4.11
  4069.  
  4070. 4.11
  4071.  
  4072.  
  4073.  
  4074. ProTips
  4075. 4.11
  4076. Peter Jennings
  4077. 4.11
  4078. This is a column of hints and tips for users of Protext 5. It is not
  4079. intended as a regular feature to rival PipeLine as there are probably
  4080. not yet enough users of the Archimedes version of Protext to support it.
  4081. Arnor have promised to keep me informed of developments to Protext,
  4082. particularly the eagerly awaited RISC-OS version, and I will pass the
  4083. details on in future issues of Archive, along with any hints or tips
  4084. that pioneering users of this exciting new word processor may care to
  4085. send by way of Paul Beverley.
  4086. 4.11
  4087. In the meantime, here are a few hints of my own plus advice on an
  4088. irritating bug that has emerged from the software since I completed the
  4089. review in last monthæs Archive.
  4090. 4.11
  4091. First the bug, which has suddenly appeared after lying dormant during
  4092. three monthsæ constant use of Protext. It shows itself during attempts
  4093. to save a file, either manually or automatically, with two messages, one
  4094. saying that the file öPROTEXT!Xò or öPROTEXT!Tò cannot be found and the
  4095. other: öError creating fileò. More alarmingly, the text sometimes
  4096. disappears from the screen. Any further attempt to save brings a öFile
  4097. openò message. My description of this as öirritatingò may seem rather
  4098. inadequate but, in fact, it is not disastrous and can be dealt with
  4099. quite easily. When the message about PROTEXT!X appears just type öcloseò
  4100. at the command line, followed by ösò (for save). Your original file name
  4101. will then be offered and pressing <return> will duly save it.
  4102. 4.11
  4103. Arnor have not given me any fix for this fault but have just said,
  4104. rather uncertainly: öWe think we may have solved the problem in the next
  4105. version of Protext.ò Let us hope they have.
  4106. 4.11
  4107. Omissions
  4108. 4.11
  4109. Two strange omissions from Protext, so far, are a function key strip and
  4110. an icon. If you dislike the boring default applications icon, or the
  4111. blank squares representing files, you can always design your own icons,
  4112. using !Paint. First create a directory for them, called !Sprites, inside
  4113. the main !Protext directory. Then design an application icon named
  4114. !protext and a files icon called file_cdf, with additional small
  4115. versions if wanted. Finally, add an initial line to the !Boot file:
  4116. öIconSprites <Obey$Dir>.!Spritesò. If you are not sure how to create
  4117. icons there are instructions in the chapter on öPaintò in the User Guide
  4118. or you can find a set of ready-made sprites in a !Sprites directory on
  4119. this monthæs program disc. You can just copy !Sprites into the !Protext
  4120. directory but do not forget to add the IconSprites line to the !Boot
  4121. file. The ready-mades have a simple öP5ò design, with a border round the
  4122. files sprite, but are colourful enough to be readily identified in a
  4123. desktop directory.
  4124. 4.11
  4125. A do-it-yourself function key strip is also easily made, either using a
  4126. program which provides a template or by starting from scratch with
  4127. Protextæs excellent line drawing facility. One made this way is also on
  4128. this monthæs disc. It has to be printed in two sections, one below the
  4129. other, as Protext can not print down the paper in landscape form. Anyone
  4130. who has a wide-carriage printer can copy the second section beside the
  4131. first by using the Protext öboxò marking facility.
  4132. 4.11
  4133. Line drawing
  4134. 4.11
  4135. When making a grid by line drawing, the natural way is to begin by
  4136. drawing either the horizontal lines or the outside box shape and then
  4137. adding the verticals afterwards. If you do it this way, however, you may
  4138. find the vertical lines going slightly beyond the outside boundaries. To
  4139. correct this, draw the uprights with the up or down arrow key, as
  4140. normal, but use one of the horizontal, left or right, arrow keys for the
  4141. final stroke before reaching the horizontal boundary. The line will then
  4142. turn the corner to make a neat join instead of an intersection. Corners
  4143. are drawn in the same way.
  4144. 4.11
  4145. Although Protext comes with 48 printer drivers, there isnæt one for the
  4146. very popular Panasonic KX-P1081 printer, which I use. The FX80 printer
  4147. driver is suitable for it but will not print line drawings. So the
  4148. function key strip needs to have the IBM9 printer driver loaded and one
  4149. of the printeræs tiny DIP switches changed. These can be found below and
  4150. immediately to the right of the printer head when it is in its öhomeò
  4151. position on the extreme left. Lift up the thin strip of clear plastic
  4152. covering them and use a small screwdriver or similar implement to push
  4153. switch number one, on the extreme left, down (for off). The other
  4154. switches can probably be left as set but if you still have a problem try
  4155. putting either switch six or seven up (for on).
  4156. 4.11
  4157. Hopefully, Arnor will produce a key strip and their own official icons
  4158. when the RISC-OS version of Protext finally appears.
  4159. 4.11
  4160. Obvious when you know
  4161. 4.11
  4162. Finally, a few brief tips of the öitæs obvious when you knowò variety.
  4163. You can find your version number of Protext by pressing <escape> and
  4164. reading the bar above the command line. This also shows you the current
  4165. directory and the selected printer driver.
  4166. 4.11
  4167. The öSwapò line at the top of the colour configuration menu puzzled me
  4168. for a time as it does not seem to be explained anywhere. I eventually
  4169. discovered that selecting it and pressing <return> shows the colours
  4170. used for alternate documents when more than one is loaded.
  4171. 4.11
  4172. It is a good idea to lock the files of templates, such as letter
  4173. headings, to prevent them being overwritten if a document you are
  4174. working on is automatically saved with the templateæs name. If, for any
  4175. reason, you cannot lock the template, load it with the command ömò for
  4176. merge instead of ölò for load. The bar at the top of the screen will
  4177. show öNo fileò and you will be asked for a name before the document is
  4178. saved.ááA
  4179. 4.11
  4180.  
  4181. Hints and Tips
  4182. 4.12
  4183. Å   Basic line lengths revisited (Archive 4.10 p7) Ö The Basic line input
  4184. buffer is 238 characters and so this is the most you can type in from
  4185. the Basic prompt. Once entered, this line is tokenised before being
  4186. stored as part of a program. Most of the keywords are reduced to only
  4187. one byte, so the line ends up taking up much less room in a program. The
  4188. maximum length for a line in a program is 255 bytes, but four of these
  4189. bytes have special purposes (one is a line terminator, one the line
  4190. length and two the line number). This leaves 251 bytes for the rest of
  4191. the line. So whatæs the point in allowing bigger lines in the program if
  4192. you canæt type them in? Well, you can by being devious. Try typing the
  4193. following at the Basic prompt:
  4194. 4.12
  4195. 10E.:E.:E.: etc
  4196. 4.12
  4197. until you hit the line limit and then press Return. Listing your program
  4198. now should reveal:
  4199. 4.12
  4200. 10ENDPROC:ENDPROC:ENDPROC: etc
  4201. 4.12
  4202. up to a length of about 790 characters! This line is perfectly valid and
  4203. would run OK (although I canæt think of a program where 79 ENDPROCs in a
  4204. row would be useful!) but is much too long to edit at the Basic prompt
  4205. or in the Basic Editor. It wouldnæt be sensible for the Basic Editor to
  4206. limit you to 251 characters since, once tokenised, your line would be
  4207. much shorter, so it allows you to type up to 369 characters hoping that
  4208. tokenising will bring it back to 251. It objects if you try to type in
  4209. more than 369 characters; it also objects if you type a shorter line
  4210. which would be longer than 251 characters once tokenised (try REM
  4211. followed by 300 letters). As for solving the problem, if you have a copy
  4212. of Twin, you could try loading your Basic program into it. Twin has no
  4213. line length limit and will cope with anything. Returning to Basic will
  4214. always work provided the resulting tokenised lines would be no longer
  4215. than 251 characters. Lorcan Mongey
  4216. 4.12
  4217. Å   Citizen printer spare parts Ö You may be interested to know that you
  4218. can get spare parts for Citizen printers from XMA Ltd, Ruddington Lane,
  4219. Wilford, Nottingham, NG11 7EP. (0602 Ö818222) Rob Brown, Tadworth,
  4220. Surrey.
  4221. 4.12
  4222. Å   Fatal error type = 5 Ö !Edit will report this error if you have too
  4223. many outline fonts in your !Fonts folder. This will prevent you from
  4224. editing any documents within !Edit. The following Basic program will
  4225. solve this problem by hiding the !Fonts folder before running !Edit and
  4226. then restoring it once !Edit has been run.
  4227. 4.12
  4228. 1. Rename the É!RunImageæ file inside the É!Editæ folder as ÉEditImageæ.
  4229. 4.12
  4230. 2. Type the following program in and then save it as É!RunImageæ in the
  4231. É!Editæ folder.
  4232. 4.12
  4233. REM ><Edit$Dir>.!RunImage
  4234. 4.12
  4235. SYS öWimp_Initialiseò,200,&4B534154, öEditStartò TO ,taskid%
  4236. 4.12
  4237. *Set temp <Font$Prefix>
  4238. 4.12
  4239. *UnSet Font$Prefix
  4240. 4.12
  4241. *WimpSlot -min 160k -max 160k
  4242. 4.12
  4243. *WimpSlot -min 160k
  4244. 4.12
  4245. SYS öWimp_StartTaskò,öRun <Edit$Dir> .EditImage ò+FNenv_string
  4246. 4.12
  4247. *Set Font$Prefix <temp>
  4248. 4.12
  4249. *Unset temp
  4250. 4.12
  4251. SYS öWimp_CloseDownò,,taskid% ,&4B534154
  4252. 4.12
  4253. END
  4254. 4.12
  4255.  
  4256. 4.12
  4257. DEFFNenv_string
  4258. 4.12
  4259. LOCAL env$,x%
  4260. 4.12
  4261. SYS öOS_GetEnvò TO env$
  4262. 4.12
  4263. IF LEN(env$)<6 THEN =öò
  4264. 4.12
  4265. WHILE INSTR(env$,ö ò,x%)>0
  4266. 4.12
  4267. x%=INSTR(env$,ö ò,x%)+1
  4268. 4.12
  4269. ENDWHILE
  4270. 4.12
  4271. =RIGHT$(env$,LEN(env$)-x%+1)
  4272. 4.12
  4273. Å    Locating the I/O podule (a SWI number change) Ö Those writing code
  4274. for the I/O podule for use on different machines should note that Acorn
  4275. made a SWI number change between version 1.04 and 1.06 of the software
  4276. (use *Help Modules to find what version you have). Earlier issues of the
  4277. podule use &4043F for SWI öI/O _Podule_Hardwareò whereas the later
  4278. versions use &40500. ARM code assembled on a machine with one version of
  4279. the software will not work on another machine with a different version
  4280. without changing this SWI number. Richard House, Surrey.
  4281. 4.12
  4282. Å   PC screen fonts Ö If you are not overly fond of the chunky IBM
  4283. character set in the PC emulator, the following few lines of Basic will
  4284. modify the emulator ROM file with the BBC font of your choice.
  4285. 4.12
  4286. REM >PCFONT
  4287. 4.12
  4288. REM Merge BBC FONT file into !PC ROM file
  4289. 4.12
  4290. REM N.B. *** COPY ORIGINAL ROM FILE BEFORE RUNNING THIS ***
  4291. 4.12
  4292. :
  4293. 4.12
  4294. DIM rom% &2000 : offset%=&166E
  4295. 4.12
  4296. R$=ö:4.$.!PC.ROMò
  4297. 4.12
  4298. OSCLI(öLoad ò+R$+ö ò+STR$~rom%)
  4299. 4.12
  4300. A%=OPENIN(R$) : r1%=EXT#A% : CLOSE#A%
  4301. 4.12
  4302. :
  4303. 4.12
  4304. F%=OPENIN(ö4:.BBCFONTS.NEWFONTò) : REM file of type &FF7
  4305. 4.12
  4306. REPEAT
  4307. 4.12
  4308. A%=BGET#F%
  4309. 4.12
  4310. IF A%<>23 THEN PRINT öThis is not a BBC font file!ò : END
  4311. 4.12
  4312. C%=BGET%F%
  4313. 4.12
  4314. FOR I%=0 TO 7
  4315. 4.12
  4316. rom%?(offset%+((C%+128) MOD 256) *8+ I%)=BGET#F%
  4317. 4.12
  4318. NEXT I%
  4319. 4.12
  4320. UNTIL EOF#F%
  4321. 4.12
  4322. CLOSE#F%
  4323. 4.12
  4324. :
  4325. 4.12
  4326. OSCLI(öSave ò+R$+ö òSTR$~rom%+ ö + ò+STR$~r1%)
  4327. 4.12
  4328. END
  4329. 4.12
  4330. This program has been used successfully on the ROM files supplied with
  4331. version 1.33 and the latest 1.60 (large and small) Ö each version stores
  4332. its VDU 23 character definitions from offset &166E onwards. Pete Bready,
  4333. Glasgow.
  4334. 4.12
  4335. Å   Impression Junior styles? Ö In the June 1991 edition of Archive, it
  4336. was pointed out that Impression Junior does not have styles. Although it
  4337. does not have styles, it does have rulers. These are intended to define
  4338. margins and tab-stops, but they can be used for other things.
  4339. 4.12
  4340. If you save a text story with effects, you will see the definition of a
  4341. ruler, which looks like:
  4342. 4.12
  4343.  
  4344. 4.12
  4345. There will also be the definition of the BaseStyle, which contains a
  4346. number of additional commands. By copying some of these to the ruler
  4347. definition, you can create the equivalent of a style. As an example, a
  4348. Éstyleæ that changes the font of the text subject to the ruler to greek,
  4349. could be, for example:
  4350. 4.12
  4351.  
  4352. 4.12
  4353. As Impression Junior does not have the facility to create rulers with
  4354. these extensions, they must be written using an ordinary text editor
  4355. (such as !Edit) and imported into Impression where they become rulers.
  4356. 4.12
  4357. The commands that I know work are:
  4358. 4.12
  4359. font <font name>   Ö e.g. Greek, Trinity.Medium, etc
  4360. 4.12
  4361. fontsize <size>pt   Ö 8 to 20 is reasonable
  4362. 4.12
  4363. fontaspect <size>%      Ö
  4364. 100 normal, 200 stretches to twice size
  4365. 4.12
  4366. fontcolour rgb = (<n>,<n>,<n>)  Ö n is from 0 to 1 or 0 to 100 (both
  4367. appear to work)
  4368. 4.12
  4369. linecolour rgb = (<n>,<n>,<n>)  Ö as above
  4370. 4.12
  4371. justify [left, right, centre, full]  Ö full is to both margins
  4372. 4.12
  4373. underline [0,1]      Ö other
  4374. values also work but give strange underline
  4375. 4.12
  4376. strikeout [on, off]      Ö
  4377. writes É-æ over characters
  4378. 4.12
  4379. script [off, sub, super]      Ö
  4380. sub and super-scripts
  4381. 4.12
  4382. leader ö<text>ò      Ö overwrites
  4383. tab character
  4384. 4.12
  4385. By using these additional commands, it is possible to generate some very
  4386. useful rulers.
  4387. 4.12
  4388. Simon Callan, Borehamwood.ááA
  4389. 4.12
  4390.    
  4391.