home *** CD-ROM | disk | FTP | other *** search
/ The Best of Windows 95.com 1996 September / WIN95_09964.iso / program / vbmax3d.zip / 3DShadows.frm (.txt) < prev    next >
Visual Basic Form  |  1996-06-09  |  6KB  |  210 lines

  1. VERSION 4.00
  2. Begin VB.Form frm3DShadows 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "VBMax 3D Effects Demo - Drop Shadows"
  5.    ClientHeight    =   3030
  6.    ClientLeft      =   585
  7.    ClientTop       =   1425
  8.    ClientWidth     =   6990
  9.    Height          =   3435
  10.    Icon            =   "3DShadows.frx":0000
  11.    Left            =   525
  12.    LinkTopic       =   "Form1"
  13.    LockControls    =   -1  'True
  14.    MaxButton       =   0   'False
  15.    MinButton       =   0   'False
  16.    ScaleHeight     =   3030
  17.    ScaleWidth      =   6990
  18.    ShowInTaskbar   =   0   'False
  19.    Top             =   1080
  20.    Width           =   7110
  21.    Begin VB.Frame Frame3 
  22.       Caption         =   "Shadows"
  23.       Height          =   1635
  24.       Left            =   4440
  25.       TabIndex        =   13
  26.       Top             =   120
  27.       Width           =   2415
  28.       Begin VB.HScrollBar sliOffset 
  29.          Height          =   255
  30.          Left            =   750
  31.          Max             =   10
  32.          Min             =   1
  33.          TabIndex        =   3
  34.          Top             =   1155
  35.          Value           =   10
  36.          Width           =   1515
  37.       End
  38.       Begin VB.OptionButton optShadow 
  39.          Caption         =   "Light"
  40.          Height          =   255
  41.          Index           =   0
  42.          Left            =   180
  43.          TabIndex        =   0
  44.          Top             =   300
  45.          Value           =   -1  'True
  46.          Width           =   795
  47.       End
  48.       Begin VB.OptionButton optShadow 
  49.          Caption         =   "Dark"
  50.          Height          =   255
  51.          Index           =   1
  52.          Left            =   180
  53.          TabIndex        =   1
  54.          Top             =   720
  55.          Width           =   795
  56.       End
  57.       Begin VB.Label lblOffset 
  58.          Caption         =   "Offset:"
  59.          Height          =   195
  60.          Left            =   180
  61.          TabIndex        =   2
  62.          Top             =   1200
  63.          Width           =   540
  64.       End
  65.    End
  66.    Begin VB.PictureBox Picture1 
  67.       Appearance      =   0  'Flat
  68.       AutoSize        =   -1  'True
  69.       BackColor       =   &H80000005&
  70.       ForeColor       =   &H80000008&
  71.       Height          =   510
  72.       Left            =   3360
  73.       Picture         =   "3DShadows.frx":000C
  74.       ScaleHeight     =   480
  75.       ScaleWidth      =   480
  76.       TabIndex        =   12
  77.       TabStop         =   0   'False
  78.       Top             =   240
  79.       Width           =   510
  80.    End
  81.    Begin VB.FileListBox File1 
  82.       Appearance      =   0  'Flat
  83.       Height          =   615
  84.       Left            =   180
  85.       TabIndex        =   11
  86.       TabStop         =   0   'False
  87.       Top             =   1140
  88.       Width           =   1215
  89.    End
  90.    Begin VB.DirListBox Dir1 
  91.       Appearance      =   0  'Flat
  92.       Height          =   705
  93.       Left            =   180
  94.       TabIndex        =   10
  95.       TabStop         =   0   'False
  96.       Top             =   120
  97.       Width           =   1215
  98.    End
  99.    Begin VB.VScrollBar VScroll1 
  100.       Height          =   1215
  101.       Left            =   3480
  102.       Max             =   10
  103.       TabIndex        =   9
  104.       TabStop         =   0   'False
  105.       Top             =   1320
  106.       Width           =   255
  107.    End
  108.    Begin VB.HScrollBar HScroll1 
  109.       Height          =   255
  110.       Left            =   1800
  111.       Max             =   10
  112.       TabIndex        =   8
  113.       TabStop         =   0   'False
  114.       Top             =   2280
  115.       Width           =   1215
  116.    End
  117.    Begin VB.ComboBox Combo1 
  118.       Appearance      =   0  'Flat
  119.       Height          =   765
  120.       Left            =   180
  121.       Style           =   1  'Simple Combo
  122.       TabIndex        =   7
  123.       TabStop         =   0   'False
  124.       Text            =   "Combo1"
  125.       Top             =   2040
  126.       Width           =   1215
  127.    End
  128.    Begin VB.CommandButton cmdClose 
  129.       Cancel          =   -1  'True
  130.       Caption         =   "Close"
  131.       Height          =   360
  132.       Left            =   5280
  133.       TabIndex        =   4
  134.       Top             =   2460
  135.       Width           =   900
  136.    End
  137.    Begin VB.TextBox Text1 
  138.       Appearance      =   0  'Flat
  139.       Height          =   300
  140.       Left            =   1800
  141.       TabIndex        =   5
  142.       TabStop         =   0   'False
  143.       Text            =   "Text1"
  144.       Top             =   1320
  145.       Width           =   1215
  146.    End
  147.    Begin VB.Line Line1 
  148.       X1              =   4260
  149.       X2              =   4260
  150.       Y1              =   120
  151.       Y2              =   2880
  152.    End
  153.    Begin VB.Label Label1 
  154.       Appearance      =   0  'Flat
  155.       BackColor       =   &H80000005&
  156.       BorderStyle     =   1  'Fixed Single
  157.       Caption         =   "Label1"
  158.       ForeColor       =   &H80000008&
  159.       Height          =   300
  160.       Left            =   1800
  161.       TabIndex        =   6
  162.       Top             =   360
  163.       Width           =   1215
  164.    End
  165. Attribute VB_Name = "frm3DShadows"
  166. Attribute VB_Creatable = False
  167. Attribute VB_Exposed = False
  168. Option Explicit
  169. Dim mo3D    As New C3D
  170. Private Sub cmdClose_Click()
  171.     Unload Me
  172. End Sub
  173. Private Sub Form_Load()
  174.     CenterForm Me
  175.     With mo3D
  176.         .Style = gnRECESSED
  177.         .Offset = sliOffset.Value
  178.     End With
  179.     DrawShadows
  180. End Sub
  181. Private Sub Form_Unload(Cancel As Integer)
  182.     Set mo3D = Nothing
  183.     Set frm3DShadows = Nothing
  184. End Sub
  185. Private Sub DrawShadows()
  186.     Cls
  187.     With mo3D
  188.         .Line3D Line1
  189.         .DropShadow Text1
  190.         .DropShadow Label1
  191.         .DropShadow HScroll1
  192.         .DropShadow VScroll1
  193.         .DropShadow Combo1
  194.         .DropShadow Dir1
  195.         .DropShadow File1
  196.         .DropShadow Picture1
  197.     End With
  198. End Sub
  199. Private Sub optShadow_Click(Index As Integer)
  200.     Select Case Index
  201.         Case 0: mo3D.Shadow = gnLIGHT_SHADOW
  202.         Case 1: mo3D.Shadow = gnDARK_SHADOW
  203.     End Select
  204.     DrawShadows
  205. End Sub
  206. Private Sub sliOffset_Change()
  207.     mo3D.Offset = sliOffset.Value
  208.     DrawShadows
  209. End Sub
  210.