|
PEresetimageBOOL PEresetimage (hObject, nXAspect, nYAspect )
This function is called to reset the image when the objects properties are adjusted. This function is normally called after PEreinitialize in the sequence:
PEreinitialize( hPE ) PEresetimage( hPE, 0, 0) InvalidateRect // Windows API
Or, another scenario, it is used like...
PEreinitialize ( hPE ) // Read ManualMaxY, or other properties related to your logic, // respect to ManualMaxY for example. PEresetimage ( hPE, 0, 0 ) InvalidateRect // Windows API
The above code allows you to interogate properties related to data/scales and update properties with respect to these readings without causing an additional image to be generated (which can be a lengthy process for larger data sets.)
Returns NonZero if the function was successful, otherwise Zero.
Comments Another potential scenario where you will call this function is prior to calling PEgetmeta. This allows you to build a metafile with a desired aspect ratio in preparation to sending to a device context. In this case, the aspect ratio used with PEresetimage should be the same as used with the SetViewportExt Windows function. For PEgetmeta and printing information, look to Question 21 in Chapter 7. Though, PEresetimageEx is more commonly used with printing logic.
See Also: PEresetimageEx, PEreinitialize
.NET developers, see PeFunction.ResetImage or PeFunction.ReinitializeResetImage
Ocx|Vcl developers, see the PEactions property.
With OCX interface, you can call this function as follows... Pego1.PEactions = 2 'calls PEresetimage
In Delphi, use... PEGraph1.PEactions := gResetImage; {calls PEresetimage} |
©2022 Gigasoft, Inc. | All rights reserved.
Gigasoft is a registered trademark, and ProEssentials a trademark of Gigasoft, Inc. |