home *** CD-ROM | disk | FTP | other *** search
/ Programming Tool Box / SIMS_2.iso / vb_code1 / 3ctrls / splitter.frm < prev    next >
Text File  |  1994-05-05  |  8KB  |  226 lines

  1. VERSION 2.00
  2. Begin Form Splitter 
  3.    BackColor       =   &H00C0C0C0&
  4.    Caption         =   "Resize controls using the colored splitter bars"
  5.    ClientHeight    =   3720
  6.    ClientLeft      =   570
  7.    ClientTop       =   1635
  8.    ClientWidth     =   8415
  9.    Height          =   4185
  10.    Left            =   480
  11.    LinkTopic       =   "Form1"
  12.    ScaleHeight     =   3720
  13.    ScaleWidth      =   8415
  14.    Top             =   1260
  15.    Width           =   8595
  16.    Begin VideoSoftElastic mainElastic 
  17.       Align           =   5  'Fill Container
  18.       AutoSizeChildren=   2  'Uneven Horizontal
  19.       BackColor       =   &H0000FF00&
  20.       BorderWidth     =   0
  21.       Height          =   3720
  22.       IntBkg          =   &H0000FF00&
  23.       Left            =   0
  24.       Splitter        =   1  'Yes (with uneven spacing)
  25.       TabIndex        =   0
  26.       Top             =   0
  27.       Width           =   8415
  28.       Begin VideoSoftElastic MiddleElastic 
  29.          AutoSizeChildren=   1  'Even Horizontal
  30.          BackColor       =   &H00C0C0C0&
  31.          BevelOuter      =   1  'Raised
  32.          BevelOuterWidth =   1
  33.          BorderWidth     =   12
  34.          Height          =   3720
  35.          IntBkg          =   &H00C0C0C0&
  36.          Left            =   2475
  37.          TabIndex        =   12
  38.          Top             =   0
  39.          Width           =   2655
  40.          Begin TextBox Text2 
  41.             Height          =   3360
  42.             Left            =   180
  43.             TabIndex        =   14
  44.             Text            =   "Text2"
  45.             Top             =   180
  46.             Width           =   2295
  47.          End
  48.       End
  49.       Begin VideoSoftElastic LeftElastic 
  50.          AutoSizeChildren=   1  'Even Horizontal
  51.          BackColor       =   &H00C0C0C0&
  52.          BevelOuter      =   1  'Raised
  53.          BevelOuterWidth =   1
  54.          BorderWidth     =   12
  55.          Height          =   3720
  56.          IntBkg          =   &H00C0C0C0&
  57.          Left            =   0
  58.          TabIndex        =   11
  59.          Top             =   0
  60.          Width           =   2385
  61.          Begin TextBox Text1 
  62.             Height          =   3360
  63.             Left            =   180
  64.             TabIndex        =   13
  65.             Text            =   "Text1"
  66.             Top             =   180
  67.             Width           =   2025
  68.          End
  69.       End
  70.       Begin VideoSoftElastic RightElastic 
  71.          AutoSizeChildren=   4  'Uneven Vertical
  72.          BackColor       =   &H0000FF00&
  73.          BorderWidth     =   0
  74.          Height          =   3720
  75.          IntBkg          =   &H0000FF00&
  76.          Left            =   5220
  77.          Splitter        =   1  'Yes (with uneven spacing)
  78.          TabIndex        =   1
  79.          Top             =   0
  80.          Width           =   3195
  81.          Begin VideoSoftElastic ElasticTop 
  82.             AutoSizeChildren=   3  'Even Vertical
  83.             BackColor       =   &H00C0C0C0&
  84.             BevelInner      =   7  'Shadow
  85.             BevelInnerWidth =   3
  86.             BevelOuter      =   1  'Raised
  87.             BevelOuterWidth =   1
  88.             BorderWidth     =   12
  89.             ChildSpacing    =   10
  90.             Height          =   2985
  91.             IntBkg          =   &H00C0C0C0&
  92.             Left            =   0
  93.             TabIndex        =   6
  94.             Top             =   0
  95.             Width           =   3195
  96.             Begin CommandButton Command1 
  97.                BackColor       =   &H00C0C0C0&
  98.                Caption         =   "&Colors"
  99.                FontBold        =   -1  'True
  100.                FontItalic      =   0   'False
  101.                FontName        =   "System"
  102.                FontSize        =   9.75
  103.                FontStrikethru  =   0   'False
  104.                FontUnderline   =   0   'False
  105.                Height          =   555
  106.                Index           =   0
  107.                Left            =   180
  108.                TabIndex        =   10
  109.                Top             =   180
  110.                Width           =   2835
  111.             End
  112.             Begin CommandButton Command1 
  113.                BackColor       =   &H00C0C0C0&
  114.                Caption         =   "&Fonts"
  115.                FontBold        =   -1  'True
  116.                FontItalic      =   0   'False
  117.                FontName        =   "System"
  118.                FontSize        =   9.75
  119.                FontStrikethru  =   0   'False
  120.                FontUnderline   =   0   'False
  121.                Height          =   540
  122.                Index           =   1
  123.                Left            =   180
  124.                TabIndex        =   9
  125.                Top             =   885
  126.                Width           =   2835
  127.             End
  128.             Begin CommandButton Command1 
  129.                BackColor       =   &H00C0C0C0&
  130.                FontBold        =   -1  'True
  131.                FontItalic      =   0   'False
  132.                FontName        =   "System"
  133.                FontSize        =   9.75
  134.                FontStrikethru  =   0   'False
  135.                FontUnderline   =   0   'False
  136.                Height          =   540
  137.                Index           =   2
  138.                Left            =   180
  139.                TabIndex        =   8
  140.                Top             =   1575
  141.                Width           =   2835
  142.             End
  143.             Begin CommandButton Command1 
  144.                BackColor       =   &H00C0C0C0&
  145.                FontBold        =   -1  'True
  146.                FontItalic      =   0   'False
  147.                FontName        =   "System"
  148.                FontSize        =   9.75
  149.                FontStrikethru  =   0   'False
  150.                FontUnderline   =   0   'False
  151.                Height          =   540
  152.                Index           =   3
  153.                Left            =   180
  154.                TabIndex        =   7
  155.                Top             =   2265
  156.                Width           =   2835
  157.             End
  158.          End
  159.          Begin VideoSoftElastic ElasticBottom 
  160.             AutoSizeChildren=   1  'Even Horizontal
  161.             BackColor       =   &H00C0C0C0&
  162.             BevelInner      =   7  'Shadow
  163.             BevelInnerWidth =   4
  164.             BevelOuter      =   1  'Raised
  165.             BevelOuterWidth =   1
  166.             BorderWidth     =   10
  167.             ChildSpacing    =   12
  168.             Height          =   645
  169.             IntBkg          =   &H00C0C0C0&
  170.             Left            =   0
  171.             TabIndex        =   2
  172.             Top             =   3075
  173.             Width           =   3195
  174.             Begin CommandButton Command1 
  175.                BackColor       =   &H00C0C0C0&
  176.                Caption         =   "A"
  177.                Height          =   345
  178.                Index           =   6
  179.                Left            =   150
  180.                TabIndex        =   5
  181.                Top             =   150
  182.                Width           =   855
  183.             End
  184.             Begin CommandButton Command1 
  185.                BackColor       =   &H00C0C0C0&
  186.                Caption         =   "B"
  187.                Height          =   345
  188.                Index           =   5
  189.                Left            =   1185
  190.                TabIndex        =   4
  191.                Top             =   150
  192.                Width           =   840
  193.             End
  194.             Begin CommandButton Command1 
  195.                BackColor       =   &H00C0C0C0&
  196.                Caption         =   "C"
  197.                Height          =   345
  198.                Index           =   4
  199.                Left            =   2205
  200.                TabIndex        =   3
  201.                Top             =   150
  202.                Width           =   840
  203.             End
  204.          End
  205.       End
  206.    End
  207. End
  208. Option Explicit
  209.  
  210. Sub Command1_Click (Index As Integer)
  211.   Dim newcolor&
  212.   Select Case Index
  213.  
  214.     Case 0  'Change to random colors
  215.       newcolor = QBColor(Rnd * 15)
  216.       MainElastic.BackColor = newcolor
  217.       RightElastic.BackColor = newcolor
  218.  
  219.     Case 1   'Fonts
  220.       Text1.FontSize = (Text1.FontSize + 2) Mod 13
  221.       Text2.FontSize = (Text2.FontSize + 2) Mod 13
  222.       
  223.   End Select
  224. End Sub
  225.  
  226.