mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-02-03 09:44:24 -05:00
Forgot to commit a new utility function.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4534 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
e4927efd62
commit
0e52f8eb5c
21
lib/fmtmsg.f90
Normal file
21
lib/fmtmsg.f90
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
subroutine fmtmsg(msg,iz)
|
||||||
|
|
||||||
|
character*22 msg
|
||||||
|
|
||||||
|
! Convert all letters to upper case
|
||||||
|
iz=22
|
||||||
|
do i=1,22
|
||||||
|
if(msg(i:i).ge.'a' .and. msg(i:i).le.'z') &
|
||||||
|
msg(i:i)= char(ichar(msg(i:i))+ichar('A')-ichar('a'))
|
||||||
|
if(msg(i:i).ne.' ') iz=i
|
||||||
|
enddo
|
||||||
|
|
||||||
|
do iter=1,5 !Collapse multiple blanks into one
|
||||||
|
ib2=index(msg(1:iz),' ')
|
||||||
|
if(ib2.lt.1) go to 100
|
||||||
|
msg=msg(1:ib2)//msg(ib2+2:)
|
||||||
|
iz=iz-1
|
||||||
|
enddo
|
||||||
|
|
||||||
|
100 return
|
||||||
|
end subroutine fmtmsg
|
Loading…
Reference in New Issue
Block a user