📄 contrast.frm
字号:
VERSION 5.00
Begin VB.Form contrast
BackColor = &H00E0E0E0&
BorderStyle = 0 'None
Caption = "Form1"
ClientHeight = 2970
ClientLeft = 0
ClientTop = 0
ClientWidth = 4545
LinkTopic = "Form1"
MDIChild = -1 'True
ScaleHeight = 2970
ScaleWidth = 4545
ShowInTaskbar = 0 'False
Begin VB.CommandButton color_but
BackColor = &H00E0E0E0&
Caption = "change color!"
Height = 255
Left = 2520
Style = 1 'Graphical
TabIndex = 3
Top = 2400
Visible = 0 'False
Width = 1335
End
Begin VB.Timer Timer3
Enabled = 0 'False
Interval = 50
Left = 3960
Top = 720
End
Begin VB.Timer Timer4
Enabled = 0 'False
Interval = 50
Left = 3960
Top = 1440
End
Begin VB.CommandButton Command1
BackColor = &H00E0E0E0&
Caption = "&Change"
Height = 255
Left = 1080
Style = 1 'Graphical
TabIndex = 2
Top = 2400
Width = 1095
End
Begin VB.VScrollBar contrast_scroll
Height = 1815
Left = 600
Max = 2
TabIndex = 1
Top = 720
Width = 255
End
Begin VB.Shape Shape3
BackColor = &H00808080&
BackStyle = 1 'Opaque
Height = 375
Left = 1080
Top = 1900
Width = 2775
End
Begin VB.Shape Shape2
BackColor = &H00C0C0C0&
BackStyle = 1 'Opaque
Height = 375
Left = 1080
Top = 1400
Width = 2775
End
Begin VB.Shape Shape1
BackColor = &H00E0E0E0&
BackStyle = 1 'Opaque
Height = 375
Left = 1080
Top = 900
Width = 2775
End
Begin VB.Label Label1
BackStyle = 0 'Transparent
Caption = "Adjust background contrast :"
DragMode = 1 'Automatic
BeginProperty Font
Name = "MS Sans Serif"
Size = 9.75
Charset = 0
Weight = 700
Underline = 0 'False
Italic = 0 'False
Strikethrough = 0 'False
EndProperty
Height = 375
Left = 600
TabIndex = 0
Top = 240
Width = 3255
End
End
Attribute VB_Name = "contrast"
Attribute VB_GlobalNameSpace = False
Attribute VB_Creatable = False
Attribute VB_PredeclaredId = True
Attribute VB_Exposed = False
Dim i
Private Sub color_but_Click()
Mainform.mnucolor.Visible = True
color_but.Enabled = False
End Sub
Private Sub color_but_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
color_but.FontBold = True
End Sub
Private Sub Command1_Click()
Select Case contrast_scroll.Value
Case 0
contrast.BackColor = &HE0E0E0
Mainform.BackColor = &HE0E0E0
assist.BackColor = &HE0E0E0
Case 1
contrast.BackColor = &H8000000F
Mainform.BackColor = &H8000000F
assist.BackColor = &H8000000F
Case 2
contrast.BackColor = &H80000010
Mainform.BackColor = &H80000010
assist.BackColor = &H80000010
End Select
End Sub
Private Sub Command1_DragDrop(Source As Control, X As Single, Y As Single)
Source = label1
color_but.Visible = True
End Sub
Private Sub Command1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Command1.FontBold = True
End Sub
Private Sub Form_Load()
contrast.Height = 1
contrast.Width = 1
Timer3.Enabled = True
End Sub
Private Sub Form_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
Command1.FontBold = False
color_but.FontBold = False
End Sub
Private Sub Timer3_Timer()
If i = 10 Then
Timer3.Enabled = False
Exit Sub
End If
i = i + 1
contrast.Height = i * 297
contrast.Width = i * 454.5
End Sub
Private Sub Timer4_Timer()
If i = 0 Then
Timer4.Enabled = False
Exit Sub
End If
i = i - 1
contrast.Height = contrast.Height - 297
contrast.Width = contrast.Width - 454.5
End Sub
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -