登录
首页 » 界面开发 » 基于c#的时钟

基于c#的时钟

于 2022-01-26 发布 文件大小:47.56 kB
0 207
下载积分: 2 下载次数: 1

代码说明:

资源描述本源程序是基于C#的时钟设计,能为初学者提供参考价值,为初学者提供基本的编写代码思路, namespace Clock { public partial class MainForm : Form { private PointF center; private float r; private Pen hourPen; private Pen minutePen; private Pen secondPen; private Thread timeThread; public MainForm() { InitializeComponent(); ShowInTaskbar = false;//不在任务栏中显示 SetStyle(ControlStyles.DoubleBuffer, true); SetStyle(ControlStyles.UserPaint,true); SetStyle(ControlStyles.AllPaintingInWmPaint,true); center = new PointF(ClientSize.Width/ 2.0f, ClientSize.Height/ 2.0f); r = Math.Min(ClientSize.Width / 2.0f, ClientSize.Height / 2.0f); hourPen = new Pen(Color.Black, 2.5f); minutePen = new Pen(Color.Black, 1.5f); secondPen = new Pen(Color.Black, 0.5f); timeThread=new Thread(new ThreadStart(DrawTime)); timeThread.Start(); } protected override void OnPaint(PaintEventArgs e) { Graphics g = e.Graphics; g.Clear(BackColor); //g.SmoothingMode =

下载说明:请别用迅雷下载,失败请重下,重下不扣分!

发表评论

0 个回复

  • VB程序,可直接用来编制个性化.
    VB界面程序,可直接用来编制个性化界面.-VB interface procedures can be used directly for the preparation of personalized interface.
    2022-12-28 12:15:03下载
    积分:1
  • Qt login,自动识别焦点
    #include "mainwindow.h" #include "ui_mainwindow.h" MainWindow::MainWindow(QWidget *parent) :     QMainWindow(parent),     ui(new Ui::MainWindow) {     ui->setupUi(this);     pushButton = new QPushButton(this);     pushButton->setObjectName(QString::fromUtf8("pushButton"));     pushButton->setGeometry(QRect(40, 180, 51, 27));     pushButton_2 = new QPushButton(this);     pushButton_2->setObjectName(QString::fromUtf8("pushButton_2"));     pushButton_2->setGeometry(QRect(40, 140, 51, 27));     pushButton_3 = new QPushButton(this);     pushButton_3->setObjectName(QString::fromUtf8("pushButton_3"));     pushButton_3->setGeometry(QRect(100, 140, 51, 27));   &
    2022-03-13 04:00:49下载
    积分:1
  • hao duihua好对话框,介绍如何改变标题的程序
    hao duihua好对话框,介绍如何改变标题的程序-good dialog on how to change the procedures title
    2022-05-29 00:51:46下载
    积分:1
  • 选课管理系统
    课堂大作业做的选课系统, 其中包括完整的数据库,学生选课的时候还有课程表的查询,界面美观,可以使用,里面还有完整的设计文档。需要的人可以进行学习研究一下,是第一次做的C#系统软件,很多不成熟的地方还请多多包涵。
    2022-01-22 00:07:06下载
    积分:1
  • 与国外经典计算机教材《Practical Object
    与国外经典计算机教材《Practical Object-Oriented Design with UML》配套的源代码。作者:Mark Priestley -classic computer with foreign materials "Practical Object-Oriented Design with UML" complementary source. Author : Mark Priestley
    2022-01-25 15:01:15下载
    积分:1
  • Outlook style segmentation
    Outlook风格的切分-Outlook style segmentation
    2022-06-21 06:20:36下载
    积分:1
  • 这是一个realplayer的源代码
    这是一个realplayer的源代码-This is a source REALPLAYER
    2022-05-23 05:37:01下载
    积分:1
  • a button type of skin
    一个VC 的皮肤按钮类-a button type of skin
    2022-10-25 16:55:03下载
    积分:1
  • how to change the background color dialog
    如何改变对话框的背景色-how to change the background color dialog
    2022-07-03 09:53:38下载
    积分:1
  • simulated ATM function, able to access, report the loss, elimination households,...
    模拟ATM的功能,能实现存取款,挂失,消户,注册,解冻等功能~-simulated ATM function, able to access, report the loss, elimination households, registration, thawed functions ~
    2022-03-07 08:18:25下载
    积分:1
  • 696516资源总数
  • 106914会员总数
  • 0今日下载