In the following program, the text should be written initially in black, and then be overwritten in red (so that nothing of the black is seen. That happens if the two lines calling ITALIC_FONT@ are commented out.
OPTIONS (INTL, DREAL)
PROGRAM DEMO
INCLUDE <WINDOWS.INS>
INTEGER, EXTERNAL:: KB_DRAW
IW = WINIO@ ('%ca[Demo]%gr%sc', 300, 100, KB_DRAW)
END
INTEGER FUNCTION KB_DRAW()
INCLUDE <WINDOWS.INS>
CHARACTER*(100) VALUE
VALUE = 'Spencer, E (1967) A method of analysis'
CALL DRAW_CHARACTERS@ (VALUE, 10, 10, RGB@(0,0,0))
VALUE = 'of the stability of embankments'
CALL DRAW_CHARACTERS@ (VALUE, 10, 25, RGB@(0,0,0))
VALUE = 'assuming parallel inter-slice forces'
CALL DRAW_CHARACTERS@ (VALUE, 10, 40, RGB@(0,0,0))
VALUE = 'Geotechnique, 17, 11-26'
CALL DRAW_CHARACTERS@ (VALUE, 10, 55, RGB@(0,0,0))
VALUE = 'Spencer, E (1967) A method of analysis'
CALL DRAW_CHARACTERS@ (VALUE, 10, 10, RGB@(255,0,0))
VALUE = 'of the stability of embankments'
CALL DRAW_CHARACTERS@ (VALUE, 10, 25, RGB@(255,0,0))
VALUE = 'assuming parallel inter-slice forces'
CALL DRAW_CHARACTERS@ (VALUE, 10, 40, RGB@(255,0,0))
VALUE = 'Geotechnique, 17, 11-26'
CALL ITALIC_FONT@ (1)
CALL DRAW_CHARACTERS@ (VALUE, 10, 55, RGB@(255,0,0))
CALL ITALIC_FONT@ (0)
CALL PERFORM_GRAPHICS_UPDATE@ ()
KB_DRAW = 2
END
However, with the lines left in, the final line is displaced one line upwards. Something similar happens with BOLD_FONT@ and UNDERLINE_FONT@.
In my rather larger program (which does not overwrite) the effects are somewhat more far reaching, including wholesale displacement upwards of many text lines. The overwriting in the demo is merely to demonstrate what happens in a simple example.
Incidentally, the FTN95.CHM entry for ITALIC_FONT@ does not state what the values of the argument are.
I also noted that in FTN95.CHM the entry for HIGH_RES_CLOCK@ mentions calling DBOS, and elsewhere (I can't find it again) I came across a link that should invoke Internet Explorer - and doesn't on a modern PC.
FTN95 v8.50 used.
Eddie
(with apologies to Eric Spencer, but his paper is a time-waster!)