home *** CD-ROM | disk | FTP | other *** search
/ Programming Languages Suite / ProgLangD.iso / Bonus / WSTAR2 / DISK4 / OUTALL.WM_ / OUTALL.bin
Encoding:
Text File  |  1994-02-28  |  11.4 KB  |  138 lines

  1. REM Description:  Outdent first, left, and right indents to 0
  2. REM Filename: outall.wmc
  3. REM Created by: Steve Wylie - 11/08/93
  4.  
  5. REM Can't run if no document open
  6. IF GetDocName$() = "" THEN
  7.     MESSAGE "Please create a new document or open an existing document first."
  8.     STOP
  9. ENDIF
  10.  
  11. REM Can't run in a graphic or table frame
  12. frameType% = GetFrameType()
  13. IF frameType% <> 0 THEN
  14.     Message "The current frame must be a text frame."
  15.     STOP
  16. ENDIF
  17.  
  18. REM Can't run in frame mode
  19. ret% = ViewEditMode(1)
  20. IF ret% = 2 THEN
  21.     ret% = ViewEditMode(2)
  22.     BEEP
  23.     STOP
  24. ENDIF
  25.  
  26. REM Changed local% to 0 if you want the change to apply globally to the paragraph style.
  27. local% = 1
  28.  
  29. REM Save the beginning and end of the selection
  30. yes% = GetTextOffset(strt%, end%)
  31. IF strt% = 0 THEN strt% = 4
  32.  
  33. REM Freeze the screen so that the activity isn't visible
  34. freeze% = ViewFreezeScreen(1)
  35.  
  36. REM Count the number of paragraphs
  37. EditGotoOffset strt%, 
  38. DO
  39.     ret% = GetTextOffset(savestart%, saveend%)
  40.     ParaDown 1, 
  41.     ret% = GetTextOffset(start2%, end2%)
  42.     numParagraphs% = numParagraphs% + 1
  43. LOOP UNTIL end2% >= end% OR end2% = saveend%
  44.  
  45. REM Go to the beginning of the selection
  46. EditGotoOffset strt%, 0
  47.  
  48. FOR i% = 1 TO numParagraphs%
  49.     REM Get the style information
  50.     GetStyleParagraph first%, left%, right%, above%, below%, align%, location%, span%, hyphen%, numHyph%, keep%, allowBreak%, widow%
  51.    
  52.     IF first% <> 0 OR left% <> 0 OR right% <> 0 THEN 
  53.         REM Redefine the style with the new first and left indents.
  54.         DefineStyle , local%
  55.         DefineStyleParagraph 0, 0, 0, , , , , , , , , , 
  56.         EndDefineStyle 1
  57.     ENDIF
  58.  
  59.     REM Go to the next paragraph.
  60.     ParaDown 1,0
  61.     IF GetNextChar$() <> "<Cr>" THEN CharRight 1,0,
  62. NEXT i%
  63.  
  64. REM Restore the selection
  65. EditGotoOffset strt%, 0
  66. if yes%=1 then EditGotoOffset end%, 1
  67.  
  68. REM Restore the screen
  69. freeze% = ViewFreezeScreen(freeze%)
  70.  
  71. 
  72. *****  WARNING *****
  73. This is a WSWin macro file.
  74. Subsequent data is binary information and should not be modified.
  75. # MF # 1.0None762570691ⁿ,╪Ö#
  76. 8àêë
  77. âêçèâ
  78. 8ìî
  79. ïìÄÅ
  80. 8    
  81. 8    æÉÆ
  82. 8 âÉöâ
  83. 8ûò
  84. ïûùÿ
  85. 8
  86. 8¢Ç
  87. ܢ֣
  88. 8
  89. âÖ₧ƒâ
  90. 8á₧
  91. ÜáÖí
  92. 8
  93. 8
  94. 8óÇ
  95. 8 ñѪúº
  96. 8
  97. âÑ⌐â
  98. 8 Ѭ
  99. 8 #¡Ç
  100. ¼¡½«
  101. 8#&
  102. »Ñ▒
  103. 8&( ñ┤╡Ö╢
  104. 8()╕Ç
  105. ╖╕╣
  106. 8)* ñ║╗Ö╝
  107. 8*+╜╜Ç
  108. 8+,
  109. ╛╗╡┐ª╛â╗┐▓â
  110. 8,/└
  111. »Ñ└┴
  112. 8/1├╜┬Ç─┬┬Çâ┬├╟â
  113. 813 ╚╔╩╦╠═╬╧╨╤╥╙╘╒╓
  114. 8343 ╪╔ ┘╩┌╪┘ █╦â┌█▄â
  115. 8437
  116. ▌ó▐
  117. 878αßΓ ▀αßΓπ
  118. 889σÇΣσµ
  119. 89=τÇΦ
  120. ╖τΦΘ
  121. 8==#
  122. Ωφε âφ∞∩â
  123. 8=#>±Ç≥ ≡±≥≤
  124. 8>?╞
  125. 8?B⌠
  126. »Ñ⌠⌡
  127. 8BB
  128. âúÇ≈â
  129. 8BC°Ç
  130. »ª°∙
  131. 8CF
  132. ¼½½·²~┴áⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿⁿ.V.V.V .V-.V5.V;.VA.VN.V^.V    l.V
  133. z.V ê.V û.Vñ.V▓.V╢.V╣.V╜.V└.V┬.V─.V╞.V╔.V╠.V╧.V╥.V╘.V╓.V┌.V▄.V▐.Vα.V Γ.V!Σ.V"Θ.V#∞.V$≡.V%⌡.V&ⁿ.V'/V(
  134. /V)/V*/V+/V,"/V-(/V.-/V/3/V06/V1;/V2@/V3B/V4E/V5J/V6N/V7T/V8Y/V9`/V:g/V;l/V<o/V=w/V>y/V?{/V@/VAê/VBî/VCÅ/VDù/VE₧/VFú/VG¡/VH┤/VI╣/VJ╜/VK┬/VL╟/VM═/VN╤/VO╒/VP▄/VQπ/VRΩ/VS≡/VT≈/VU0VV0VW0VX$0VY10VZ:0V[G0V\P0V]X0V^`0V_h0V`q0Vav0Vb{0VcÇ0Vdç0VeÄ0Vfö0Vg¢0Vh¥0Vió0Vj¿0Vk«0Vl╡0Vm╛0Vn╟0Vo╦0Vp╙0Vq╫0Vr▄0VsΓ0VtΦ0Vuε0Vv⌠0Vw∙0Vx■0Vy1Vz1V{1V|1V}╖U  ╖U+╖U+    ╖U╖U╖U  ╖U ╖U
  135. ë,╖U  H1╖U+      4╖U      9╖U     >╖U  HC╖UçK╖U+      Ä╖U      ô╖U  ÿ╖U     ¥╖U          ¿╖Uç╡╖U     ║╖U  ÿ┐╖U  ÿ─╖U+      ε╖U      ≤╖U  °╖U     ■╖U          ╖Uç╖U  ╖U     ╖U  ⁿ!╖U+  #╖U  ⁿ(╖U  .╖U     4╖U          ;╖U          @╖UçN╖U          T╖U          Y╖U     _╖U  Jd╖U  Ji╖U+  k╖U          s╖UçNä╖U  è╖U     É╖UAKƒ╖U  Ñ╖U     ½╖U  x░╖U  °╢╖U          ┴╖U          ╩╖U     ╨╖UA?┘╖U  ▀╖U     σ╖U          φ╖U          ≤╖U     ∙╖U          ╖U  ╖U  ╖U  ╖U      ╖U          #╖U  (╖U  4.╖U  B4╖U  ,:╖U  ~@╖UAR╖U          Y╖U          _╖U          f╖U          m╖U          t╖U          {╖U          à╖U          ï╖U          ô╖U          £╖U          ó╖U          «╖U          ╡╖U      ╗╖U   ┴╖U  ╟╖U  ═╖U  ╙╖U  ┘╖U   ▀╖UA,δ╖U     ±╖UA/╖U   ╖U  ╖U  ╖U     ╖UA=-╖U  3╖U     9╖U  ?╖U  E╖U     K╖U
  136. ëBX╖U  p^╖U+      e╖U      k╖U     q╖U  pw╖UADü╖U  ç╖U  ì╖U     ô╖U  Ö╖U     ƒ╖U  ╩Ñ╖U  ╩½╖U  ▒╖U     ╖╖U     ╜╖U┐╖U????01CANCELERRORNUM[T1]
  137. GETDOCNAME$[L1]""[T2][T3][L2]MESSAGE"Please create a new document or open an existing document first."[T4][T5][T6]FRAMETYPE%GETFRAMETYPE[T7][L3][L4]"The current frame must be a text frame."[T8][T9][T10]RET%VIEWEDITMODE[T11][T12][L5]2[L6][T13][T14]LOCAL%YES%GETTEXTOFFSETSTRT%END%[T15][L7][L8]4FREEZE%VIEWFREEZESCREEN[T16][T17]EDITGOTOOFFSET[T18][T19][L9][L10]SAVESTART%SAVEEND%[T20]PARADOWN[T21][T22]START2%END2%[T23]NUMPARAGRAPHS%[T24][T25][T26][T27]I%[F1][L11][L12][L13][L14]GETSTYLEPARAGRAPHFIRST%LEFT%RIGHT%ABOVE%BELOW%ALIGN%LOCATION%SPAN%HYPHEN%NUMHYPH%KEEP%ALLOWBREAK%WIDOW%[T28][L15][T29][T30][T31][T32][L16]DEFINESTYLE[T33]DEFINESTYLEPARAGRAPH[T34][T35][T36][T37]ENDDEFINESTYLE[T38][T39][T40][T41][T42]GETNEXTCHAR$[L17]"<Cr>"[T43][T44][L18]CHARRIGHT[T45][T46][T47][T48][T49][L19][L20][T50][T51][T52]
  138.