ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Help / WLanguage / WLanguage functions / Controls, pages and windows / Drawing functions
  • Opacity
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac CatalystUniversal Windows 10 App
Others
Stored procedures
Clears the content of a variable of type Image or an Image control and fills it with the specified color.
Example
dStartDrawing(IMG_Drawing)
// Draw a rectangle with a light yellow background and a light blue border
dRectangle(10, 10, 50, 50, LightYellow, LightBlue)
// Clear the drawing and apply blue
dClear(LightBlue)
Syntax

Clearing the current image and filling it with the specified color Hide the details

dClear([<Color>])
<Color>: Optional constant or Color variable
Color used to fill the cleared element. This color can correspond to: If this parameter is not specified, the image will be reset to its initial state:
  • transparent for a variable of type Image,
  • background color of the window for an Image control.

Clearing the Image variable or Image control and filling it with the specified color Hide the details

dClear(<Image> [, <Color>])
<Image>: Name of the Image control or variable
Name of the Image control or variable of type Image to be handled.
<Color>: Optional constant or Color variable
Color used to fill the cleared element. This color can correspond to: If this parameter is not specified, the image will be reset to its initial state:
  • transparent for a variable of type Image,
  • background color of the window for an Image control.
Remarks

Opacity

  • If the drawing mode has been enabled in the control without an opacity value (dStartDrawing without the dWithOpacity constant):
    • Windows In Windows, when dClear is used with a color, it will not take the opacity into account.
    • Linux In Linux, only colors with maximum opacity can be used.
  • If the drawing mode has been enabled in the control with an opacity value (dStartDrawing function with the dWithOpacity constant), opacity will be taken into account when dClear is used with a color.
Component: wd300pnt.dll
Minimum version required
  • Version 28
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 06/14/2024

Send a report | Local help