[UP]


Manual Reference Pages  - fixedwidth (3)

NAME

fixedwidth(3f) - [M_draw:TEXT] Turns fixedwidth mode on or off for SOFTWARE fonts. (LICENSE:PD)

CONTENTS

Synopsis
Description
Example

SYNOPSIS

subroutine fixedwidth(onoff) logical onoff

DESCRIPTION

Turns fixedwidth text on or off. .TRUE. causes all text to be printed with a fixed width for each character. Otherwise, the text is spaced proportionally, where each character has a unique width less than or equal to the current fixed font width. This routine only affects software text.

The default at program initialization is fixedwidth(.false.)

EXAMPLE

Sample program:

   program demo_fixedwidth
      use M_draw
      implicit none
      real,parameter :: x1=0.0,  x2=40.0,  y1=0.0,  y2=4.0
      real,parameter :: scl=3*0.7
      integer :: idum
   ! set up display
      call prefsize(1000,100)
      call vinit(’ ’)
      call page(x1,x2,y1,y2)
   ! set font appearance
      call linewidth(200)
      call font("times.rb")
   ! draw a string using proportional and fixed spacing
      call move2(x1+0.3,y1+0.4)
      call textsize(0.8*scl,1.2*scl)
      call color(1)
      call fixedwidth(.false.)
      call drawstr("fixedwidth(.false.)")
      call textsize(0.6*scl,1.2*scl)
      call color(2)
      call fixedwidth(.true.)
      call drawstr(" fixedwidth(.true.)")
   ! wrap up
      idum=getkey()
      call vexit()
   end program demo_fixedwidth


fixedwidth (3) March 11, 2021
Generated by manServer 1.08 from ea99a150-4b14-423e-87fd-a0212f3d4745 using man macros.