PC SOFT

ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

Home | Sign in | English EN

This content has been translated automatically. Click here to view the French version.
  • Operation of the Property BrushStyle
  • Limit
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
The Property StyleBackground allows to know and modify the display style of the Background of the cells of tables and/or hierarchical tables.. This property is effective only if the row, the column or the cell is using a background color specified by BackgroundColor. This property can be used to highlight a specific cell in the table.
Example: The "Monday" cell is colored in light green with the "Tube" style.
Example
// Color the DAY cell of the current row
COL_Day[1].Background colour = LightGreen
COL_Day[1].StyleBackground = styleTube
Syntax

Finding out the style of the background color Hide the details

<Background style> = <Element to use>.BrushStyle
<Background style>: Integer constant
Background style currently used:
styleDefaultDefault value. Solid colors.
styleGradientSimple gradient (to the bottom).
styleDiagonalCrossHatchHatches such as xxxxx
styleCrossHatchHatches such as +++++
styleRightDiagonalHatchHatches such as \\\\\\
styleLeftDiagonalHatchHatches such as //////
styleHorizontalHatchHatches such as ------
styleVerticalHatchHatching such as |||||
styleTube2 gradients of the main color, used to get a tube effect.
<Element to use>: Character string (with or without quotes)
Identifies the cell, row or column from a Table or TreeView Table control that must be managed.

Modifying the style of the background color Hide the details

<Element to use>.BrushStyle = <New style>
<Element to use>: Character string (with or without quotes)
Identifies the cell, row or column from a Table or TreeView Table control that must be managed.
<New style>: Integer constant
Background style to use:
styleDefaultSolid colors. This option is used by default when creating a table.
styleGradientSimple gradient (to the bottom).
styleDiagonalCrossHatchHatches such as xxxxx
styleCrossHatchHatches such as +++++
styleRightDiagonalHatchHatches such as \\\\\\
styleLeftDiagonalHatchHatches such as //////
styleHorizontalHatchHatches such as ------
styleVerticalHatchHatching such as |||||
styleTube2 gradients of the main color, used to get a tube effect.
Remarks

Operation of the Property BrushStyle

The effect of changing the Property BrushStyle is visible on a cell, row or column only if the color of this cell, row or column has been defined with Property BackgroundColor.
Using the hatches: The color of hatches is defined by Color. By default, the color of hatches corresponds to the color of the text. To use a different color for the text, call gPen.
Example:
TABLE_SansNom1.Color = Black
TABLE_SansNom1.ColourBackground = LightYellow
FOR I = 1 TO 10
TableAddLine(MySelf)
TABLE_SansName1[I].StyleBottom = styleLeftDiagonalHatch
TABLE_NoName1.COL_NoName1[I] = gPen(LightRed) + "Row " + I
END

Limit

The Property BrushStyle is only available on the cells, rows and columns of the Table and Hierarchy Table fields.
Related Examples:
Style for displaying the table cells Unit examples (WINDEV): Style for displaying the table cells
[ + ] Modifying the display style of table cells.
The ..BrushStyle property is used to hatch the cells or to create a color gradient with "tube" effect.
Minimum version required
  • Version 11
Comments
Click [Add] to post a comment