Unit 'Intuition' Package
[Overview][Constants][Types][Procedures and functions][Variables][Index] [#aros]

ScrollWindowRaster

Scrolls the content of the rectangle

Declaration

Source position: intuition.pas line 3313

procedure ScrollWindowRaster(

  Win: PWindow;

  Dx: SmallInt;

  Dy: SmallInt;

  XMin: SmallInt;

  YMin: SmallInt;

  XMax: SmallInt;

  YMax: SmallInt

);

Arguments

Win

  

A pointer to a Window structure

Dx

  

May be postive, zero, or negative

Dy

  

May be postive, zero, or negative

XMin

  

Left of bounding rectangle

YMin

  

Upper of bounding rectangle

XMax

  

Right of bounding rectangle

YMax

  

Lower of bounding rectangle

Description

Calls ScrollRasterBF(), which moves the bits in the raster by (dx,dy) towards (0,0) The space vacated is filled by calling EraseRect().

Note: that vacated space is not considered damage! The scroll operation is limited to the rectangle defined by (xmin,ymin)-(xmax,ymax). Bits outside will not be affected. If (xmax,ymax) is outside the rastport then use the lower right corner of the rastport.

If a window is partly obscured, then it is possible for ScrollWindowRaster() to scroll some of the obscured area into view. If the window is simple-refresh, then the formerly obscured area is damage, and the application needs to repair it. If Intuition detects damage as a result of ScrollWindowRaster(), it will send an IDCMP_REFRESHWINDOW event to the application's window. This handling of damage is the principal reason ScrollWindowRaster() is preferred to ScrollRaster() and ScrollRasterBF().

Note: This call uses ScrollRasterBF(), which calls EraseRect() when clearing the newly exposed area. This allows use of a custom layer backfill hook.

Important: boopsi gadgets should use ScrollRaster() or ScrollRasterBF() directly! Never call ScrollWindowRaster() from inside a boopsi gadget's method handler. Note that Intuition will detect and handle damage caused by such use of ScrollRaster() or ScrollRasterBF(), for gadgets with the GMORE_SCROLLRASTER property.

VERY IMPORTANT: if you have any gadgets in your simple-refresh window with the GMORE_SCROLLRASTER property, you must use ScrollWindowRaster() instead of ScrollRaster() or ScrollRasterBF(). Handling of gadget scroll damage is incompatible with continued use of these graphics functions in an Intuition window. NB: If you're using a gadget class whose source code you do not control, that class might be using GMORE_SCROLLRASTER or might start to in a future version. For that reason, you should use ScrollWindowRaster() if you are using any such gadgets.

See also

ScrollRaster()

  

Push bits in rectangle in raster around by dx,dy towards 0,0 inside rectangle.

ScrollRasterBF()

  

Push bits in rectangle in raster around by dx,dy towards 0,0 inside rectangle. Newly empty areas will be filled via EraseRect().

EraseRect()

  

Fill a defined rectangular area using the current BackFill hook.

ScrollWindowRasterNoFill

  

Scrolls the content of the rectangle

WA_BackFill

  

Tag for OpenWindowTagList(). BackFill hook


Documentation generated on: 2021-07-30