CaptureArea Example for Builder 3.0
This is also the example for the ScaleMode property, CaptureAreaDrawCursorIndex property, CaptureAreaFillPattern property, CaptureAreaDrawLineStyle property, CaptureAreaDrawEllipseWidth property, CaptureAreaDrawEllipseHeight property, CaptureAreaInfoLeft property, CaptureAreaInfoTop property, CaptureAreaInfoHeight property, CaptureAreaInfoWidth property, CaptureAreaShowDrawCursor property, CaptureAreaIncludeCursor property, CaptureAreaEnableKeyboard property, CaptureAreaShowOpaqueText property, CaptureAreaShowCursorPosition property, CaptureAreaShowAreaSize property, CaptureAreaShowInfoWindow property, CaptureAreaSensitiveInfoWindow property, CaptureAreaBitmapWithRegion property, CaptureAreaZoomFactor property, CaptureAreaFillForeColor property, CaptureAreaFillPattern property, CaptureAreaFillBackColor property, CaptureAreaDrawLineColor property, CaptureAreaTextForeColor property, and CaptureAreaTextBackColor property.
/*show area info window*/
LEADScr1->CaptureAreaShowInfoWindow = true;
/*show area size during capture*/
LEADScr1->CaptureAreaShowAreaSize = true;
/*enable sensitive area info window*/
LEADScr1->CaptureAreaSensitiveInfoWindow = true;
/*set zoom factor*/
LEADScr1->CaptureAreaZoomFactor = 3;
/*position capture area info window*/
LEADScr1->CaptureAreaInfoTop = 100;
LEADScr1->CaptureAreaInfoLeft = 100;
/*size the capture area info window*/
LEADScr1->CaptureAreaInfoWidth = 100;
LEADScr1->CaptureAreaInfoHeight = 200;
/*set colors*/
LEADScr1->CaptureAreaDrawLineColor = clBlack;
LEADScr1->CaptureAreaTextForeColor = clBlue;
LEADScr1->CaptureAreaTextBackColor = clBlack;
/*capture with a region*/
LEADScr1->CaptureAreaBitmapWithRegion = true;
/*show cursor position with opaque background*/
LEADScr1->CaptureAreaShowCursorPosition = true;
LEADScr1->CaptureAreaShowOpaqueText = true;
/*disable keyboard*/
LEADScr1->CaptureAreaEnableKeyboard = false;
/* ! include cursor in captured image*/
LEADScr1->CaptureAreaIncludeCursor = false;
/*setup the background*/
LEADScr1->CaptureAreaFillBackColor = clRed;
LEADScr1->CaptureAreaFillForeColor = clBlue;
LEADScr1->CaptureAreaFillPattern = bsDiagCross;
/*capture a round rect*/
LEADScr1->CaptureAreaDrawLineStyle = psDashDot;
LEADScr1->CaptureAreaDrawEllipseHeight = 5;
LEADScr1->CaptureAreaDrawEllipseWidth = 5;
/*show cursor while drawing*/
LEADScr1->CaptureAreaUseCrossLinesCursor = false;
LEADScr1->CaptureAreaDrawCursor = crArrow;
LEADScr1->CaptureAreaShowDrawCursor = true;
/* the capture*/
LEADScr1->CaptureArea(CAPTURE_AREA_ROUNDRECT);
/*copy the image to a Main Control*/
LEAD1->Bitmap = LEADScr1->Bitmap;