領域は、パネル内の特定の領域です。指定した領域を、行単位で上下に、列単位で左右にスクロールできます。
PPB-Update-Mask でのビット設定に応じて、次のように特定のデータ項目を指定する必要があります。
| attribute-buffer | pic x(n) | 
| PPB-Buffer-Offset | pic 9(4) comp-x | 
| PPB-Fill-Attribute | pic x | 
| PPB-Fill-Character | pic x | 
| PPB-Panel-ID | pic 9(4) comp-x | 
| PPB-Scroll-Count | pic 9(4) comp-x | 
| PPB-Scroll-Direction | pic 9(2) comp-x | 
| PPB-Update-Height | pic 9(4) comp-x | 
| PPB-Update-Mask | pic x | 
| PPB-Update-Start-Col | pic 9(4) comp-x | 
| PPB-Update-Start-Row | pic 9(4) comp-x | 
| PPB-Update-Width | pic 9(4) comp-x | 
| PPB-Vertical-Stride | pic 9(4) comp-x | 
| text-buffer | pic x(n) | 
| ビット | 必要なデータ項目 | 
| attribute-buffer | PPB-Update-Mask のビット 1 が設定されている場合は、領域を埋める属性バッファーを指定します。 | 
| PPB-Buffer-Offset | PPB-Update-Mask のビット 0 が設定されている場合は、text-buffer から表示する最初の文字位置を指定します。PPB-Update-Mask のビット 1 が設定されている場合は、attribute-buffer から表示する最初の属性位置を指定します。 | 
| PPB-Fill-Attribute | PPB-Update-Mask のビット 3 が設定されている場合は、領域を埋める属性を指定します。 | 
| PPB-Fill-Character | PPB-Update-Mask のビット 2 が設定されている場合は、領域を埋める文字を指定します。 | 
| PPB-Panel-ID | スクロールされるパネルの識別ハンドル。この値は、PF-Create-Panel 呼び出しで返されます。 | 
| PPB-Scroll-Count | スクロールする行数。 | 
| PPB-Scroll-Direction | スクロールの方向。 | 
| PPB-Update-Height | スクロールする領域の高さ。 | 
| PPB-Update-Mask | 「Panels パラメーター ブロック」セクションを参照してください。 | 
| PPB-Update-Start-Col | スクロールで影響を受ける領域の最初の列。 | 
| PPB-Update-Start-Row | スクロールで影響を受ける領域の最初の行。 | 
| PPB-Update-Width | スクロールする領域の幅。 | 
| PPB-Vertical-Stride | PPB-Update-Mask のビット 0 または 1 が設定されている場合は、text-buffer または attribute-buffer の行の長さを指定します。 | 
| text-buffer | PPB-Update-Mask のビット 0 が設定されている場合は、領域を埋めるテキスト バッファーを指定します。 | 
パネルは 50 文字幅、15 行の高さで定義されています。パネルのハンドルは、ws-save-panel-id に保存されています。
この例では、パネルのテキストおよび属性を 15 行、上スクロールし、空きになっているテキストを、テキスト バッファーおよび属性バッファーからのテキストおよび属性で埋めます。テキストおよび属性バッファーの最初の 15 行は、すでに使用されています (画面に表示されている)。そのため、テキストおよび属性バッファーの 16 行目からスクロールが始まります (テキストおよび属性バッファーの 1 行は 50 文字幅です)。
* Define an update rectangle; that is a block of the panel 
* to scroll. In this case, define the entire panel as the
* rectangle.
       move 50 to ppb-update-width.
       move 15 to ppb-update-height.
* Since the update rectangle is the same size as the panel,
* begin scrolling with line 1, column 1 of the panel (where 
* 0,0 is the top left-hand corner of the panel).
       move 0 to ppb-update-start-row.
       move 0 to ppb-update-start-col.
* The rectangle scrolls up.
       move 0 to ppb-scroll-direction
* Scroll up 15 lines.
       move 15 to ppb-scroll-count.
* The panel is filled with text and attributes from user
* specified buffers. The first 15 lines (each line in the 
* buffer is 50 characters wide) are already displayed. Start
* updating with the 16th line of the buffers. 
* PPB-Buffer-Offset specifies what character of the buffers 
* to begin with (where 1 is the first character). Therefore, 
* start with the 751st character (15 rows times 50 
* characters per row equals 750 characters already on the 
* screen).
       move 751 to ppb-buffer-offset.
* One row of the update rectangle is 50 characters wide.
       move 50 to ppb-vertical-stride.
* Update the vacated portions of the panel using text and
* attribute buffers (set bits 0 and 1 of PPB-Update-Mask) 
* and changes are seen on the screen as the rectangle 
* scrolls in the enabled panel(set bits 4 and 5 of 
* PPB-Update-Mask). x"33" is binary 00110011.
       move x"33" to ppb-update-mask.
* The panel ID was saved in ws-save-panel-id.
       move ws-save-panel-id to ppb-panel-id.
* Scroll the panel. The text buffer is text-buffer and the
* attribute buffer is attribute-buffer.
       move pf-scroll-panel to ppb-function.
       call "PANELS" using panels-parameter-block
       text-buffer
       attribute-buffer
       if ppb-status not = zero
*         (code to abort)
 
    
説明:
パネルでは、テキストおよび属性を別々にスクロールできません。