1 SUB SMG_CHANGE_VIRTUAL_DISPLAY(LONG New_rows,LONG New_cols, & BYTE Border_flag,BYTE Video_attr,BYTE Vir_disp_num) !---------------------------------------------------------------& ! & ! SMG_CHANGE_VIRTUAL_DISPLAY & ! & ! Creation Date: 3-July-1985 & ! Author: Ken Messer & ! Purpose: Change the attributes of a & ! virtual display & ! & ! Modification history & ! & ! Date Description of change(s) & ! & !---------------------------------------------------------------& ! & ! Copyright (c) 1985 - Ken Messer, Allied Electronics, Inc., & ! 401 E. 8th St., Ft. Worth, TX 76102 & ! & ! This software may be copied and distributed freely to anyone & ! for non-commerical use provided that this copyright notice is & ! included. & !---------------------------------------------------------------& OPTION TYPE = INTEGER, SIZE = INTEGER LONG %include "SMG$LIBRARY:SMG.DFN" DECLARE BYTE CONSTANT True = -1, & False = 0 DECLARE LONG RS, & Display_attr, & Video_attributes EXTERNAL LONG CONSTANT SMG$M_Border, & SMG$M_Blink, & SMG$M_Bold, & SMG$M_Reverse, & SMG$M_Underline, & SS$_Normal EXTERNAL LONG FUNCTION SMG$Change_virtual_display EXTERNAL STRING FUNCTION Get_Error_Message(LONG) !---------------------------------------------------------------& ! & ! M a i n P r o g r a m L o g i c & ! & !---------------------------------------------------------------& ! Border the display if desired IF Border_flag <> 0 THEN Display_attr = SMG$M_Border ELSE Display_attr = 0 END IF ! Set the desired video attributes Video_attributes = 0 Video_attributes = Video_attributes OR SMG$M_Blink & IF Video_attr AND 1 Video_attributes = Video_attributes OR SMG$M_Bold & IF video_attr AND 2 Video_attributes = Video_attributes OR SMG$M_Reverse & IF Video_attr AND 4 Video_attributes = Video_attributes OR SMG$M_Underline & IF Video_attr AND 8 ! Call the SMG RTL routine to change the display RS = SMG$Change_virtual_display(Display_id(Vir_disp_num), & New_rows,New_cols,Display_attr,Video_attributes) ! Check for error IF RS AND SS$_Normal = 0 THEN PRINT Get_Error_Message(RS) STOP END IF ! Change common area variables to reflect size change Display_rows(Vir_disp_num) = New_rows Display_cols(Vir_disp_num) = New_cols 32767 SUBEXIT END SUB