home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sources.hp48
- Path: sparky!uunet!seq!spell
- From: Daniel COHEN-LAROQUE <COHEN@cmu.unige.ch>
- Subject: v06i020: scrn_dc - Viewer utility v1.0, Part01/01
- Message-ID: <1992Aug13.015111.963@seq.uncwil.edu>
- Followup-To: comp.sys.hp48
- Sender: spell@seq.uncwil.edu (Chris Spell)
- Organization: University of Geneva, Switzerland
- Date: Thu, 13 Aug 1992 01:51:11 GMT
- Approved: spell@seq.uncwil.edu
- Lines: 273
-
- Checksum: 3236579399 (verify with brik -cv)
- Submitted-by: Daniel COHEN-LAROQUE <COHEN@cmu.unige.ch>
- Posting-number: Volume 6, Issue 20
- Archive-name: scrn_dc/part01
-
- BEGIN_DOC scrn.doc
-
- Hi everybody!!
-
- This is my first project written in system RPL. It's an improved
- version of an old user RPL program I wrote a few months ago to
- visualize objects like strings, lists, programs with the small 3x7 font.
-
-
- I often uses SCRN for several purposes:
- - To give a help in a program.
- - To get an overview of a program or a biglist.
- - To read long strings/grobs (very good for exams!!!)
-
-
- Although the aim of this program can appear obvious,
- it performs lots of tasks which would be quite long to write
- in user RPL and couldn't reach the speed of system RPL...
-
- [1] Put a program in level 1 and execute 1 ->GROB, then try to
- see the graphic object by << PICT STO {} PVIEW >>, you'll be
- surprised how big will be the width of the grob!
- Moreover, it won't be very pleasant to read it.
-
- SCRN gives you the possibility to scroll a big program or
- a list without this drawback.
-
- [2] You can also put a string which contains newlines. SCRN will
- decompose the string and allows you to read it without being
- compelled to edit it.
- Moreover, if the string begins by "RF" it will call
- the RF object packer written by Lutz Vieweg (Great Program
- if you don't want to use your coins for RamCards!)
- ( Modify SCRN.S since I renamed RF with UNZIP ).
-
- [3] SCRN will "grob" all the stack and display it in the same order,
- that means you can alternate strings, tagged-objects, grobs,
- programs, lists etc...
-
- [4] The size of PICT is set automatically: the lenght is adapted
- to the one of the stack and the widht is by default #131 unless
- a bigger grob is encountered.
-
- Commands for scrolling are :
- ----------------------------
-
- [ATTN] Exits the program and restores the old stack.
-
- Unshifted Cursors Keys scrolls one lines to left, right, up or down.
- Leftshifted Cursors Keys scrolls sixtyfour lines (1 page ) up or down only.
- Rightshifted Cursors Keys scrolls to bottom left, right, up or down.
-
- [Eval] Prints a short author message.
-
- NOTES:
- ------
- **** THIS SOFTWARE IS PROVIDED WITHOUT ANY WARRANTY ****
- Modify, copy and distribute it as you want...
-
- Excuse for any mistakes, English isn't my native language.
- If you have any questions or remarks (specially concerning
- RPL code, shortcuts and so on...), mail me to:
-
- email: cohen@cmu.unige.ch Daniel COHEN-LAROQUE
- address: Les Pommeraies Swiss Federal Institute
- 7416 ARCHAMPS Of Technology.
- FRANCE
-
-
- END_DOC
-
- BEGIN_RPL scrn.s
- ********************************************************
- * Program Name: scrn (Screener) *
- * Version: 1.00 *
- * Description: Allows to "1 ->grob" list,string,grob, *
- * prog etc... *
- * Date: 09.08.92 *
- * Author: Daniel COHEN-LAROQUE *
- * e_mail: cohen@cmu.unige.ch *
- * address: Les Pommeraies, 74160 ARCHAMPS, FRANCE *
- ********************************************************
-
- INCLUDE KEYDEFS.H
- ASSEMBLE
- NIBASC /HPHP48-E/
- RPL
- :: CK1NoBlame
- Clr16 " Formating Stack..." DISPROW1 SetDA1Temp
- DEPTH NDUP
- ONEONE 131 { NULLLAM NULLLAM LAM Width } BIND ( 2nd nulllam stands for )
- DEPTH #2/ ( the # of lines to display )
- ZERO_DO (DO)
- TWO GETLAM ROLL
- DUPTYPECSTR? OVER ONE TWO SUB$ "RF" EQUAL AND IT ( Calls Lutz Vieweg's RF prog )
- :: ID UNZIP ; ( Replace UNZIP with your RF version )
- DUPTYPEGROB? ITE
- ::
- DUP GROBDIMw
- LAM Width #MAX
- ' LAM Width STO ( Adjusts the size of PICT with the bigger grob's one )
- 2GETLAM #1+ ;
- ::
- ZERO 1PUTLAM
- DUPTYPECOL? OVER TYPELIST? OR
- OVER TYPERRP? OR
- OVER TYPEARRY? OR
- IT DECOMP$ ( Allows to see a program or a list )
- DUPTYPECSTR? ?SKIP DO>STR
- BEGIN
- 1GETLAM #1+ 1PUTLAM
- SEP$NL SWAPDUP NULL$?
- UNTIL
- DROP
- 1GETLAM reversym
- 2GETLAM #+ ;
- 2PUTLAM
- LOOP
-
- RECLAIMDISP
- ClrDA1IsStat
- ZEROZERO
- 2GETLAM #6* LAM Width MAKEGROB
- XYGROBDISP
- TURNMENUOFF
- 2GETLAM #1-
- ZEROZERO 1PUTLAM
- DO
- DUPTYPEGROB? ITE
- ::
- HARDBUFF ZERO 1GETLAM
- 3PICK 5PICK GROBDIM DROPDUP
- 1GETLAM #+ #1+ 1PUTLAM
- HEIGHTENGROB ;
- ::
- $>grob
- HARDBUFF ZERO 1GETLAM
- DUP SIX #+ 1PUTLAM ;
- GROB!
- LOOP
- 800 900 UNCOERCE2
- %.1 SWAPOVER
- DOBEEP DOBEEP
- ABND
-
- FALSE { LAM Exit } BIND
- ' NOP
- ' ::
- kpNoShift #=casedrop
- ::
- kcUpArrow ?CaseKeyDef
- :: TakeOver SCROLLUP ;
- kcDownArrow ?CaseKeyDef
- :: TakeOver SCROLLDOWN ;
- kcLeftArrow ?CaseKeyDef
- :: TakeOver SCROLLLEFT ;
- kcRightArrow ?CaseKeyDef
- :: TakeOver SCROLLRIGHT ;
- kcOn ?CaseKeyDef
- :: TakeOver
- TRUE ' LAM Exit STO ;
- kcEval ?CaseKeyDef
- :: TakeOver
- ERRBEEP
- " Viewer By Dan COHEN" NEWLINE$&$
- " cohen@cmu.unige.ch" &$ FlashWarning ;
- kcLeftShift OVER#= OVER kcRightShift #= ORNOT IT
- :: DROP 'DoBadKeyT ;
- ;
- kpLeftShift #=casedrop
- ::
- kcUpArrow ?CaseKeyDef
- :: TakeOver SIXTYFOUR ONE_DO (DO) SCROLLUP LOOP ;
- kcDownArrow ?CaseKeyDef
- :: TakeOver SIXTYFOUR ONE_DO (DO) SCROLLDOWN LOOP ;
- kpLeftShift #=casedrpfls
- DROP 'DoBadKeyT
- ;
- kpRightShift #=casedrop
- ::
- kcUpArrow ?CaseKeyDef
- :: TakeOver JUMPTOP ;
- kcDownArrow ?CaseKeyDef
- :: TakeOver JUMPBOT ;
- kcLeftArrow ?CaseKeyDef
- :: TakeOver JUMPLEFT ;
- kcRightArrow ?CaseKeyDef
- :: TakeOver JUMPRIGHT ;
- kpRightShift #=casedrpfls
- DROP 'DoBadKeyT
- ;
- 2DROP 'DoBadKeyT
- ;
- TrueTrue
- NULL{}
- ONEFALSE
- ' LAM Exit
- ' ERRJMP
- ParOuterLoop
- TURNMENUON
- RECLAIMDISP
- ClrDAsOK
- ;
- END_RPL
-
-
- BEGIN_ASC scrn.asc
- %%HP: T(1)A(R)F(.);
- "D9D20D2951F60E0C2A20D2000020264F627D6164796E6760235471636B6E2E2E
- 2B5421C2093C41309D1304CA36119203800047A2003D4303D43D6E2050759646
- 4786B21300D470C4130E8E303C370300405A57052330451262C2309FF3030040
- 33750C2A2090000256479B3064B30CB916D9D2084E205055E4A59405B2130CF1
- 268DA16D9D208813040C36D6E205075964647866C42679E60D6E205075964647
- 8672D707E316FED30B2130D9D20FEF300E5167E1262C2306122657B302C2302C
- 12657B302C2308912657B30CB91631B5145126A2170880412A1706B316FED300
- E5167A72174726F65508C170442306B316D7ED57E316CBD30B21300F51643370
- CA03113593CF1467E31619626D6E20507596464786F85110B821FC2E47E316E0
- E30CF1460E5167F370CF1268DA16D9D2053621FEF306B316EF116A3216875057
- A7266B316CBD30FED300E5161DD21B2130D9D2008F1153621FEF306B31688130
- B2040CBD300E516B2130976114337011920023001192048300B05914B4940831
- 6A5141A5141794700CA3047A20D6E204054879647B21300D47079E60E8E6079E
- 60D9D209FF303D816D9D20D5040B1FF3D9D2088704231D4B213099040B1FF3D9
- D2088704E61D4B2130F8040B1FF3D9D2088704051D4B21303A040B1FF3D9D208
- 8704C81D4B2130C1B46B1FF3D9D208870418A3079E60D6E20405487964772D70
- B213058040B1FF3D9D20887045E141C2A20D2000026596567756270224970244
- 16E60234F48454E419136C2A20B20000236F68656E60436D657E257E6967656E
- 236863915062983B2130D4140BE0262C230F714091D300B536CB916D9D204423
- 021EF3B2130B2130300403D816D9D20D5040B1FF3D9D2088704ADB46EC370231
- D443370B213099040B1FF3D9D2088704ADB46EC370E61D443370B21303004074
- 5364423021EF3B2130D00403D816D9D20D5040B1FF3D9D208870409615B21309
- 9040B1FF3D9D2088704EA615B2130F8040B1FF3D9D20887045E615B21303A040
- B1FF3D9D208870430715B2130D0040745364423021EF3B21308523021EF3B213
- 0DEBB09E5503353679E60D6E20405487964779E601DE4058983743E4CA031441
- 93B213035DE"
- END_ASC
-
- BYTES: #ED53h 803.5
-
- BEGIN_UU scrn.uue
- begin 644 scrn
- M2%!(4#0X+46=+="2%6_@P*("+0```F+T)M<61I?F=@8R11<VMN;BXK)%$BR0
- MPQ0#V3%`K&,1*3`(`'0J`-,T,$W3Y@(%5VED=&@K,0!-!TPQX.@#PW,P``2E
- M=5`R`U0A)BP#^3\P``0S5\"B`@D`(&5TN0-&.\";89TM@.0"!55.6DE0*S'`
- M'V+8&M;9`H@Q0,!C;2Y0<)5&1H=F3&*7;M#F`@57:61T:"=]<#YA[SVP$@.=
- M+?#^`^`5=AYBPC)@(6)U.R`L`\(A5K<#PC*`&6)U.\";81-;015B*G&`"!2B
- M<6`[8>\]`%YAIR=Q=&)O58`<!T0R8#MA?=YU/F&\/;`2`_`51C,'K#`14SG\
- M078^89$FUN8"!5=I9'1HCQ4!BQ+/XG0^80X^P!]DX!5V/P?\(8:M89TM4&,2
- M[S]@.V'^$:8C87@%=7IBMA/&VP/O/0!>8=$ML1(#G2T`^!$U)O'^`[83AA@#
- M*T#`VP/@%;82`WD603,'$2D`,@`1*4`X``N504M)@!.F%11:07%)!\`Z0*<"
- M;2Y`4(271K<2`]!T<.D&CFYPZ0:=+9#_`],8UMD"74"P\3^=+8!X0#+1M!(#
- MF4"P\3^=+8!X0&[1M!(#CT"P\3^=+8!X0%#1M!(#HT"P\3^=+8!X0(S1M!(#
- M'$NV\3^=+8!X0($Z<.D&;2Y`4(271G?2!RLQ4`@$&__3V0*(!U0>%"PJT`(`
- M(%9I97=E<B!">2!$86X@0T](14Z1,<:B`BL``#+VAE;F!C365N=2YY9V5N8R
- MAC89!2:)LQ(#34&P#F+",O`7!!D]`%MCO!G6V0)$,B#A/RLQL!(#`T`PC6&=
- M+=`%!!O_T]D"B`>DO63.<R`3331SL!(#F4"P\3^=+8!X0-I+YCP';M%$,P<K
- M,3``!$<U1B0#$OZS$@,-0#"-89TMT`4$&__3V0*(!P1I42LQD`D$&__3V0*(
- M!^1J42LQ\`@$&__3V0*(!U1N42LQ,`H$&__3V0*(!S1P42LQT``$1S5&)`,2
- M_K,2`U@R(.$_*S'0O@OI53!38Y=NT.8"!$5X:727;A#M!(6)<S1.K#!!%#DK
- ",0`K
- `
- end
- sum -r/size 15624/1143 section (from "begin" to "end")
- sum -r/size 32226/812 entire input file
- END_UU
-