• 大小: 1.17MB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2023-08-30
  • 语言: C/C++
  • 标签: QT  

资源简介

基本实现了windows下的记事本功能 使用c++在Qt中编写的,能够输入文字操作,并具有新建文件,打开文件,保存文件,退出,复制,粘贴,撤销,剪切,查找替换等功能。

资源截图

代码片段和文件信息

#include “finddialog.h“
#include “ui_finddialog.h“
//#include “mainwindow.h“
#include 
#include 

findDialog::findDialog(QWidget *parent) :
    QDialog(parent)
    ui(new Ui::findDialog)
{
    ui->setupUi(this);
    ui->radioButtondowF->setChecked(true);//默认向下进行查找和替换
    ui->radioButtondowR->setChecked(true);
    connect(ui->cancelButtonFSIGNAL(clicked())thisSLOT(close()));//取消按钮
    connect(ui->cancelButtonRSIGNAL(clicked())thisSLOT(close()));
    ui->nextButtonF->setEnabled(!ui->lineEditF->text().isEmpty());
    connect(ui->lineEditFSIGNAL(textChanged(QString))thisSLOT(button_Enabed()));
    ui->nextButtonR->setEnabled(!ui->lineEditR->text().isEmpty());
    connect(ui->lineEditRSIGNAL(textChanged(QString))thisSLOT(button_Enabed()));
    ui->pushButtonR->setEnabled(!ui->lineEditR->text().isEmpty());
    ui->pushButtonreplaceAll->setEnabled(!ui->lineEditR->text().isEmpty());
}

findDialog::~findDialog()
{
    delete ui;
}

void findDialog::button_Enabed()//判断查找下一个按钮等等是否可用
{
     ui->nextButtonF->setEnabled(!ui->lineEditF->text().isEmpty());
     ui->nextButtonR->setEnabled(!ui->lineEditR->text().isEmpty());
     ui->pushButtonR->setEnabled(!ui->lineEditR->text().isEmpty());
     ui->pushButtonreplaceAll->setEnabled(!ui->lineEditR->text().isEmpty());
}



 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件          0  2013-03-01 10:25  Text_Edit\text_edit\.goutputstream-L7RHTW

     文件       1368  2013-03-20 15:26  Text_Edit\text_edit\finddialog.cpp

     文件        460  2013-03-20 15:26  Text_Edit\text_edit\finddialog.h

     文件       7044  2013-03-20 15:25  Text_Edit\text_edit\finddialog.ui

     文件        448  2009-09-22 13:43  Text_Edit\text_edit\images\actions\add.png

     文件       1370  2009-10-16 18:37  Text_Edit\text_edit\images\actions\address-book-new.png

     文件        928  2009-10-16 18:37  Text_Edit\text_edit\images\actions\application-exit.png

     文件       1404  2009-10-16 18:37  Text_Edit\text_edit\images\actions\appointment-new.png

     文件       1404  2009-10-16 18:37  Text_Edit\text_edit\images\actions\appointment.png

     文件        828  2009-10-16 18:37  Text_Edit\text_edit\images\actions\back.png

     文件       1086  2009-10-16 18:37  Text_Edit\text_edit\images\actions\bookmark-new.png

     文件       1086  2009-10-16 18:37  Text_Edit\text_edit\images\actions\bookmarks_list_add.png

     文件       1086  2009-10-16 18:37  Text_Edit\text_edit\images\actions\bookmark_add.png

     文件        766  2009-10-16 18:37  Text_Edit\text_edit\images\actions\bottom.png

     文件        976  2009-09-22 13:43  Text_Edit\text_edit\images\actions\call-start.png

     文件        764  2009-09-22 13:43  Text_Edit\text_edit\images\actions\call-stop.png

     文件        548  2009-10-16 18:37  Text_Edit\text_edit\images\actions\centrejust.png

     文件        997  2009-10-16 18:37  Text_Edit\text_edit\images\actions\contact-new.png

     文件       1038  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-new.png

     文件       1481  2009-09-22 13:43  Text_Edit\text_edit\images\actions\document-open-recent.png

     文件        854  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-open.png

     文件       1209  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-page-setup.png

     文件       1188  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-print-preview.png

     文件        937  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-print.png

     文件       1145  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-properties.png

     文件       1226  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-revert.png

     文件       1182  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-save-as.png

     文件       1172  2009-10-16 18:37  Text_Edit\text_edit\images\actions\document-save.png

     文件        758  2009-09-22 13:43  Text_Edit\text_edit\images\actions\document-send.png

     文件        775  2009-10-16 18:37  Text_Edit\text_edit\images\actions\down.png

............此处省略365个文件信息

评论

共有 条评论