show3D
Type: Integer
Availability: Read or write at any time
The show3D property of the Control class is used to control whether automatic three-dimensional (3D) effects are added to the appearance of a control. The show3D property is independent of controls that have inbuilt 3D effects; for example, Frame or Button controls.
The Form sheet of the Define Application dialog in the JADE development environment enables you to specify the default value of the show3D property for new controls. For details about drawing borders on individual controls, see the borderStyle property.
The show3D property is ignored for ActiveXControl and Ocx controls so that they do not have two borders: one drawn by JADE and another drawn by the ActiveXControl or Ocx control itself.
The show3D property is set automatically to Show3D_UseBorderStyle (3) for the ActiveXControl, BrowseButtons, Button, CheckBox, Folder, Frame, JadeDockBar, JadeDockContainer, JadeMask, MultiMedia, Ocx, OptionButton, HScroll and VScroll, Sheet, and StatusLine controls, which ignore the show3D property.
The show3D property is available only in the JADE development environment for the ComboBox, GroupBox, Label, ListBox, Picture, Table, and TextBox controls. You can use the Control class is3D method to return whether the control was drawn three-dimensionally.
For performance reasons, the application default three-dimensional options are not dynamic at run time. The three-dimensional default value for each control class is obtained the first time each class is referenced. Changes to the three-dimensional default values of the application do not take effect until the application is next initiated.
The settings of this property are listed in the following table.
Control Class Constant | Value | Description |
---|---|---|
Show3D_UseAppDefault | 0 | Use application-defined default value for each control class |
Show3D_Not3D | 1 | The control is not displayed as 3D, regardless of the default value |
Show3D_Use3D | 2 | The control is displayed with 3D, regardless of the default value |
Show3D_UseBorderStyle | 3 | Use only the borderStyle property to determine the border |
The 3D effects can be thought of as a border that is two pixels wide.
If the show3D property is set to Show3D_UseAppDefault (0) and the application default setting of the show3D property for the control is true (that is, the control is selected in the 3D Controls list box on the Form sheet of the Define Application dialog) or if the show3D property for the control is set to Show3D_Use3D, the effective border is a sunken three-dimensional effect regardless of the setting of the borderStyle property. If the borderStyle property is set to BorderStyle_3DSunken (2) or BorderStyle_3DRaised (3), the show3D property is reset to Show3D_UseBorderStyle (3).
The Window class borderStyle property is ignored when the show3D property is set to Show3D_Use3D (2) or Show3D_UseAppDefault (0) and the application default is 3D. When painting the control, you should make allowance for the increased border size.
The following example shows the use of the show3D property in the constructor for a customized control.
create() updating; begin isBuilt := false; changeType := ChangeType_None; borderStyle := BorderStyle_Single; // Ignored, because of setting // of the show3D property show3D := Show3D_Use3D; transparent := true; end;