📄 fonscreendisplay.class
字号:
' Gambas class filePRIVATE $sLast AS StringPUBLIC SUB _new() Redraw ENDPUBLIC SUB Timer1_Timer() RedrawENDPRIVATE SUB Redraw() 'DIM hImage AS NEW Image DIM hPict AS Picture DIM sText AS String DIM iInd AS Integer sText = Time IF sText = $sLast THEN RETURN hPict = NEW Picture(ME.Width, ME.Height, TRUE) 'hImage.Resize(ME.Width, ME.Height) 'hPic.Fill(Color.Black) 'hPict = hImage.Picture Draw.Begin(hPict) Draw.Font = Font["64"] Draw.LineWidth = 4 FOR iInd = 8 TO 0 STEP -1 Draw.Foreground = Color.RGB(&h43 - iInd * &h43 / 8, &hC7 - iInd * &hC7 / 8, &hFF - iInd * &HFF / 8) Draw.Text(sText, 16 + iInd, iInd) Draw.Rect(iInd + 4, iInd + 4, hPict.Width - 14, hPict.Height - 14) NEXT 'Draw.Foreground = &H43C7FF& 'Draw.Text(sText, 16, 0) 'Draw.Rect(4, 4, hPict.Width - 10, hPict.Height - 10) Draw.End 'hPic.Mask(Color.Black) 'hPic.Type = Picture.Pixmap ME.Mask = hPict $sLast = sText ENDPUBLIC SUB Form_KeyPress() IF Key.Code = Key["Esc"] THEN ME.CloseEND
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -