|
| Startup file for Ovation
|
| ====================================================================
| Generic startup.
| 
| Ensure there is enough memory to begin
WimpSlot -min 608K -max 608K
|
| Ensure we aren't using RISC OS 2...
RMEnsure UtilityModule 3.10 Error This application requires RISC OS 3.10 or later
|
|Ensure we have CallASWI
RMEnsure UtilityModule 3.70 RMEnsure CallASWI 0.02 RMLoad System:Modules.CallASWI
RMEnsure UtilityModule 3.70 RMEnsure CallASWI 0.02 Error This application requires CallASWI 0.02 or later
|
| Ensure we have a suitable 26/32 bit version of SharedCLibrary
RMEnsure SharedCLibrary 5.34 RMLoad System:Modules.CLib
RMEnsure SharedCLibrary 5.34 Error This application requires SharedCLibrary 5.34 or later
| [mine is v5.83 - what are the actual version differences?]
|
| Ensure we can find !System.
If "<System$Path>" = "" then Error System resources cannot be found
|
|
| ====================================================================
| Now the various configurable options...
|
Set Ovation$Printfile Printer:
| [ where to direct output to; c.pr, printgraphics() ]
|
|
| NB parameter substitution is active here - hence use double percents below
Set Ovation$DateFormat %%ZDY%%ST %%MO %%CE%%YR
Set Ovation$TimeFormat %%Z12:%%MI%%AM
| [ formats for date and time; c.wos, getsysdate() ]
| [ default built in date: "%ZDY %M3 %YR" ]
| [ default built in time: "%Z12:%MI%AM" ]
|
|
Set Ovation$TextCPI 10
Set Ovation$TextLPI 6
| [ default settings for importing text? c.drbox; draftsetvars() ]
| [ defaults built in: CPI = 10, LPI = 8 ]
|
|
| The next line allows Ovation to use the JPEG rendering in RISC OS 3.60
Set Ovation$JPEG 1
RMEnsure SpriteExtend   0.99 Unset Ovation$JPEG
| [flag that we can directly render JPEGs; c.vdi, bootvdi() ]
|
|
| The next line tells Ovation where to look for dictionaries
Set Ovation$Dictionary <Dictionary$Dir>
If "<Ovation$Dictionary>" = "" then Set Ovation$Dictionary <Obey$Dir>
|
|
| Width of registration marks in millipoints
SetEval Ovation$RegWidth 250
| [ set width of registration marks; c.pr, renderregm() ]
|
|
| Mode 0 print the old clunky way, Mode 1 use Printers 1.22 queuing
SetEval Ovation$PrintMode 1
| [ print directly to device or print to printer queue? c.pr, printinit() ]
|
|
| The following system variables from previous versions:
|    Ovation$Dither          (we have ColourTrans dithering)
|    Ovation$FontMan3        (we can do rotated fonts)
|    Ovation$Sprite3         (we can do rotated sprites)
|    Ovation$Templates       (plain or nicer templates?)
| are no longer supported. This is because RISC OS 2 is no longer
| supported, so these things can be assumed to be present.
|
|
| ====================================================================
| Continue running the application
|
If "<Ovation$Dir>"=""  Then Seteval Ovation$Case 1  Else Seteval Ovation$Case <Ovation$Case>+1
| [ this deals with multiple invocations; Ovation will unset its values and
|   kill the Ovation module if it is the last incarnation to be quit.
|   c.main, terminate() ]
|
Set Ovation$Dir <Obey$Dir>
IconSprites <Ovation$Dir>.!Sprites
Set Alias$@RunType_CDD   Run <Ovation$Dir>.!Run %%*0
Set Alias$@RunType_CDC   Run <Ovation$Dir>.!Run %%*0
Set Alias$@PrintType_CDD Run <Ovation$Dir>.!Run -Print %%*0
Set File$Type_CDD Ovation
Set File$Type_CDC OvnStyle
|
RMEnsure Ovation        1.02 Run <Obey$Dir>.Resources.Ovation
Ovation_Keyboard_OS35
RMEnsure UtilityModule  3.50 Ovation_Keyboard_OS3
RMEnsure UtilityModule  3.00 Ovation_Keyboard_OS2
| [ need to see what this module is actually doing... it seems there are
|   certain keypresses that the Wimp (OS?) doesn't report; so it looks
|   like the module adds them somehow; mod+menu.Omodule (BASIC assembler) ]
|
WimpSlot -min 512K -max 512K
Run "<Ovation$Dir>.!RunImageS" %*0