1 | DDBRP ;SFISC/DCL-BROWSER PRINT UTILITY ;NOV 04, 1996@13:54
|
---|
2 | ;;22.0;VA FileMan;;Mar 30, 1999
|
---|
3 | ;Per VHA Directive 10-93-142, this routine should not be modified.
|
---|
4 | PRTHELP ; Print Help
|
---|
5 | ;
|
---|
6 | N DDGLI,DDGLHN1,DDGLHN2
|
---|
7 | S (DDGLHN1,DDGLHN2)=$S(DDBRHTF:9202,1:9201)
|
---|
8 | ;
|
---|
9 | BRM ;Clear scroll region, title bar and
|
---|
10 | N DX,DY,X
|
---|
11 | S DX=0,DY=$P(DDBSY,";"),X=$$CTXT^DDBR("PRINT BROWSER HELP",$J("",IOM+1),IOM)
|
---|
12 | X IOXY
|
---|
13 | W $P(DDGLVID,DDGLDEL,6) ;rvon
|
---|
14 | W $P(DDGLVID,DDGLDEL,4) ;uon
|
---|
15 | W X
|
---|
16 | W $P(DDGLVID,DDGLDEL,10) ;rvoff
|
---|
17 | F DY=$P(DDBSY,";",2):1:$P(DDBSY,";",4) X IOXY W $P(DDGLCLR,DDGLDEL)
|
---|
18 | W $P(DDGLVID,DDGLDEL,6) ;rvon
|
---|
19 | W $P(DDGLVID,DDGLDEL,4) ;uon
|
---|
20 | W X
|
---|
21 | W $P(DDGLVID,DDGLDEL,10) ;rvoff
|
---|
22 | W @IOSTBM
|
---|
23 | S DY=$P(DDBSY,";",2)
|
---|
24 | X IOXY
|
---|
25 | ;
|
---|
26 | ;Reset for Roll/Scroll mode
|
---|
27 | S X=$G(IOM,80) X ^%ZOSF("RM")
|
---|
28 | W $P(DDGLVID,DDGLDEL,9)
|
---|
29 | ;
|
---|
30 | N POP,XQH
|
---|
31 | N IOF,IOSL,DDBUC,DDBLC,DDBRZIS
|
---|
32 | N %,%A,%B,%B1,%B2,%B3,%BA,%C,%E,%G,%H,%I,%J,%K,%M,%N
|
---|
33 | N %P,%S,%T,%W,%X,%Y,%XX,%YY
|
---|
34 | N %A0,%D1,%D2,%DT,%J1,%W0
|
---|
35 | ;
|
---|
36 | S DDBUC="ABCDEFGHIJKLMNOPQRSTUVWXYZ",DDBLC="abcdefghijklmnopqrstuvwxyz"
|
---|
37 | DEVICE ;
|
---|
38 | S %ZIS=$S($D(^%ZTSK):"Q",1:""),%ZIS("B")=""
|
---|
39 | S %ZIS("S")="I $TR($P(^(0),U),DDBLC,DDBUC)'[""BROWSE"",$E($$GET1^DIQ(3.5,Y,""SUBTYPE""))=""P"""
|
---|
40 | S IOF="#",IOSL=DDBSRL
|
---|
41 | D ^%ZIS
|
---|
42 | K %ZIS
|
---|
43 | ;
|
---|
44 | I POP D
|
---|
45 | .W !!,"Report canceled!"
|
---|
46 | .H 2
|
---|
47 | ;
|
---|
48 | ;Queue report
|
---|
49 | E I $D(IO("Q")),$D(^%ZTSK) D
|
---|
50 | .S ZTRTN="PRINTHLP^DDBRP"
|
---|
51 | .S ZTDESC="Browser help printout."
|
---|
52 | .N I F I="DDGLHN1","DDGLHN2" S ZTSAVE(I)=""
|
---|
53 | .D ^%ZTLOAD
|
---|
54 | .I $D(ZTSK)#2 W !,"Report queued!",!,"Task number: "_ZTSK,!
|
---|
55 | .E W !,"Report canceled!",!
|
---|
56 | .K ZTSK
|
---|
57 | .S IOP="HOME" D ^%ZIS
|
---|
58 | ;
|
---|
59 | E I $E(IOST,1,2)="C-" D G DEVICE
|
---|
60 | .W !,$C(7)_"You cannot print the Browser help on a CRT.",!
|
---|
61 | ;
|
---|
62 | ;Non-queued report
|
---|
63 | E D
|
---|
64 | .W !,"Printing ..."
|
---|
65 | .U IO
|
---|
66 | .D PRINTHLP
|
---|
67 | .X $G(^%ZIS("C"))
|
---|
68 | ;
|
---|
69 | ;Reset for Screen Mode
|
---|
70 | S X=0 X ^%ZOSF("RM")
|
---|
71 | W $P(DDGLVID,DDGLDEL,8)
|
---|
72 | ;
|
---|
73 | ;Repaint help screen
|
---|
74 | D RPS^DDBRGE
|
---|
75 | Q
|
---|
76 | ;
|
---|
77 | PRINTHLP ;
|
---|
78 | ;
|
---|
79 | N DDGLJ,DDGLL,DDGLP
|
---|
80 | F DDGLI=DDGLHN1:1:DDGLHN2 D
|
---|
81 | . I DDGLI'=DDGLHN1 D
|
---|
82 | .. I $Y+$O(^DI(.84,DDGLI,2," "),-1)+2'<IOSL W @IOF
|
---|
83 | .. E W !!
|
---|
84 | . S DDGLJ=0
|
---|
85 | . F S DDGLJ=$O(^DI(.84,DDGLI,2,DDGLJ)) Q:'DDGLJ D
|
---|
86 | .. S DDGLL=$G(^DI(.84,DDGLI,2,DDGLJ,0))
|
---|
87 | .. F Q:DDGLL'["\" D
|
---|
88 | ... S DDGLP=$F(DDGLL,"\") Q:$E(DDGLL,DDGLP)="\"
|
---|
89 | ... S $E(DDGLL,DDGLP-1,DDGLP)=""
|
---|
90 | .. W !,DDGLL
|
---|
91 | ;
|
---|
92 | S:$D(ZTQUEUED) ZTREQ="@"
|
---|
93 | Q
|
---|