当前位置: 首页 > news >正文

为什么网站后台编辑不了网站设计的公司价格

为什么网站后台编辑不了,网站设计的公司价格,湖南网站开发 d岚鸿,网站二次开发是什么QWizard使用 描述方法枚举#xff1a;enum QWizard::WizardButton枚举#xff1a;enum QWizard::WizardOption枚举#xff1a;enum QWizard::WizardStyle枚举#xff1a;enum QWizard::WizardPixmap常用成员方法槽函数信号 示例设置标题添加page页设置按钮文本设置自定义按… QWizard使用 描述方法枚举enum QWizard::WizardButton枚举enum QWizard::WizardOption枚举enum QWizard::WizardStyle枚举enum QWizard::WizardPixmap常用成员方法槽函数信号 示例设置标题添加page页设置按钮文本设置自定义按钮文本设置page页设置帮助 按钮设置像素图registerField(const QString name, QWidget *widget, const char *property Q_NULLPTR, const char *changedSignal Q_NULLPTR)方法QWizardPage::setCommitPage(bool commitPage)方法创建QWizardPage调用 完整示例解释 描述 QWizard类为向导提供了一个框架。 向导(在macOS上也称为助手)是一种特殊类型的输入对话框由一系列页面组成。向导的目的是一步一步地指导用户完成流程。对于用户可能难以学习的复杂或不常见的任务向导非常有用。 QWizard继承QDialog并表示向导。每个页面都是一个QWizardPage (QWidget的子类)。要创建您自己的向导您可以直接使用这些类或者您可以创建它们的子类以获得更多的控制。 方法 枚举enum QWizard::WizardButton 此enum指定向导中的按钮。 关联函数 可使用setButton(),setButtonText(),setButtonLayout()等函数进行设置。 常量值描述解释QWizard::BackButton0The Back button (Go Back on macOS)后退按钮(在macOS上返回)QWizard::NextButton1The Next button (Continue on macOS)Next按钮(macOS上的Continue)QWizard::CommitButton2The Commit button提交按钮QWizard::FinishButton3The Finish button (Done on macOS)完成按钮(在macOS上完成)QWizard::CancelButton4The Cancel button (see also NoCancelButton)取消按钮(参见NoCancelButton)QWizard::HelpButton5The Help button (see also HaveHelpButton)帮助按钮(参见HaveHelpButton)QWizard::CustomButton16The first user-defined button (see also HaveCustomButton1)第一个用户定义的按钮(参见HaveCustomButton1)QWizard::CustomButton27The second user-defined button (see also HaveCustomButton2)第二个用户定义的按钮(参见HaveCustomButton2)QWizard::CustomButton38The third user-defined button (see also HaveCustomButton3)第三个用户定义按钮(参见HaveCustomButton3) 以下值只有在使用setButtonLayout()方法的时候有效 常量值描述解释QWizard::Stretch9A horizontal stretch in the button layout水平伸缩在按钮布局中 枚举enum QWizard::WizardOption 此enum指定影响向导外观的各种选项。 关联函数 setOptions(), setOption(), 和 testOption(). 常量值描述解释QWizard::IndependentPages0x00000001The pages are independent of each other (i.e., they don’t derive values from each other).各页面相互独立即它们不从彼此中派生值。QWizard::IgnoreSubTitles0x00000002Don’t show any subtitles, even if they are set.即使已设置也不显示任何副标题。QWizard::ExtendedWatermarkPixmap0x00000004Extend any WatermarkPixmap all the way down to the window’s edge.将任何水印位图一直扩展到窗口边缘。QWizard::NoDefaultButton0x00000008Don’t make the Next or Finish button the dialog’s default button.不要将“下一步”或“完成”按钮设置为对话框的默认按钮。QWizard::NoBackButtonOnStartPage0x00000010Don’t show the Back button on the start page.在起始页面上不显示“返回”按钮。QWizard::NoBackButtonOnLastPage0x00000020Don’t show the Back button on the last page.在最后一页上不显示“返回”按钮。QWizard::DisabledBackButtonOnLastPage0x00000040Disable the Back button on the last page.禁用最后一页上的“返回”按钮。QWizard::HaveNextButtonOnLastPage0x00000080Show the (disabled) Next button on the last page.在最后一页上显示禁用的“下一步”按钮。QWizard::HaveFinishButtonOnEarlyPages0x00000100Show the (disabled) Finish button on non-final pages.在非最终页面上显示禁用的“完成”按钮。QWizard::NoCancelButton0x00000200Don’t show the Cancel button.不显示“取消”按钮。QWizard::CancelButtonOnLeft0x00000400Put the Cancel button on the left of Back (rather than on the right of Finish or Next).将“取消”按钮放在“返回”按钮的左侧而不是“完成”或“下一步”按钮的右侧。QWizard::HaveHelpButton0x00000800Show the Help button.显示“帮助”按钮。QWizard::HelpButtonOnRight0x00001000Put the Help button on the far right of the button layout (rather than on the far left).将“帮助”按钮放在按钮布局的最右边而不是最左边。QWizard::HaveCustomButton10x00002000Show the first user-defined button (CustomButton1).显示第一个用户定义的按钮CustomButton1。QWizard::HaveCustomButton20x00004000Show the second user-defined button (CustomButton2).显示第二个用户定义的按钮CustomButton2。QWizard::HaveCustomButton30x00008000Show the third user-defined button (CustomButton3).显示第三个用户定义的按钮CustomButton3。QWizard::NoCancelButtonOnLastPage0x00010000Don’t show the Cancel button on the last page.在最后一页上不显示“取消”按钮。 WizardOptions类型是qflag的类型定义。它存储了WizardOption值的OR组合。 枚举enum QWizard::WizardStyle 此enum指定QWizard支持的不同外观。 关联函数 可通过setWizardStyle()进行外观设置如果不设置使用setPixmap()方法设置位图无效。 常量值描述解释QWizard::ClassicStyle0Classic Windows look经典的 Windows 外观QWizard::ModernStyle1Modern Windows look现代的 Windows 外观QWizard::MacStyle2macOS lookmacOS 外观QWizard::AeroStyle3Windows Aero lookWindows Aero 外观QWizard::NStyles4默认 枚举enum QWizard::WizardPixmap 此enum指定可以与页面关联的像素图。 关联函数 通过 setPixmap(), QWizardPage::setPixmap()等方法设置像素图。 常量值描述解释QWizard::WatermarkPixmap0The tall pixmap on the left side of a ClassicStyle or ModernStyle pageClassicStyle或ModernStyle页面左侧的高度较高的像素图QWizard::LogoPixmap1The small pixmap on the right side of a ClassicStyle or ModernStyle page headerClassicStyle或ModernStyle页面标题栏右侧的小像素QWizard::BannerPixmap2The pixmap that occupies the background of a ModernStyle page header占用ModernStyle页面标题栏背景的像素图QWizard::BackgroundPixmap3The pixmap that occupies the background of a MacStyle wizard占用MacStyle向导背景的像素图QWizard::NPixmaps4默认 常用成员方法 int addPage(QWizardPage *page)将给定的页面添加到向导中返回新页面的ID。QAbstractButton *button(WizardButton which) const返回指定按钮类型的按钮如下一步、上一步、完成等。QString buttonText(WizardButton which) const返回指定按钮类型的文本。int currentId() const返回当前页面的ID。QWizardPage *currentPage() const返回当前页面。QVariant field(const QString name) const返回具有给定名称的字段的值。bool hasVisitedPage(int id) const检查页面ID是否已经被访问过。virtual int nextId() const返回下一个要显示的页面的ID。WizardOptions options() const返回当前设置的选项。QWizardPage *page(int id) const返回指定ID的页面。QListint pageIds() const返回添加到向导中的所有页面的ID的列表。QPixmap pixmap(WizardPixmap which) const返回指定像素图类型的像素图如向导标志、向导背景等。void removePage(int id)从向导中删除指定ID的页面。void setButton(WizardButton which, QAbstractButton *button)设置指定按钮类型的按钮。void setButtonLayout(const QListWizardButton layout)设置按钮布局。void setButtonText(WizardButton which, const QString text)设置指定按钮类型的文本。void setDefaultProperty(const char *className, const char *property, const char *changedSignal)设置默认属性。void setField(const QString name, const QVariant value)设置字段的值。void setOption(WizardOption option, bool on true)设置指定选项的开启或关闭状态。void setOptions(WizardOptions options)设置选项。void setPage(int id, QWizardPage *page)设置指定ID的页面。void setPixmap(WizardPixmap which, const QPixmap pixmap)设置指定像素图类型的像素图。void setSideWidget(QWidget *widget)设置侧边栏小部件。void setStartId(int id)设置向导的起始ID。void setSubTitleFormat(Qt::TextFormat format)设置副标题的格式。void setTitleFormat(Qt::TextFormat format)设置标题的格式。void setWizardStyle(WizardStyle style)设置向导的风格。QWidget *sideWidget() const返回侧边栏小部件。int startId() const返回向导的起始ID。Qt::TextFormat subTitleFormat() const返回副标题的格式。bool testOption(WizardOption option) const检查指定选项是否已启用。Qt::TextFormat titleFormat() const返回标题的格式。virtual bool validateCurrentPage()验证当前页面是否符合要求。QListint visitedPages() const返回已访问的页面的ID列表。WizardStyle wizardStyle() const返回向导的风格。 槽函数 void back()显示前一个页面。void next()显示下一个页面。void restart()从头开始显示向导的第一个页面。 信号 void currentIdChanged(int id)当前页面的ID已更改。void customButtonClicked(int which)单击自定义按钮时发射。void helpRequested()当用户请求帮助时发射。void pageAdded(int id)向导中添加了新页面。void pageRemoved(int id)从向导中删除了页面。 示例 c 设置标题 setWindowTitle(QStringLiteral(wizard show));添加page页 QWizard wizard;wizard.addPage(createIntroPage());wizard.addPage(createRegistrationPage());wizard.addPage(createConclusionPage());设置按钮文本 setButtonText(QWizard::NextButton, 下一步);setButtonText(QWizard::CancelButton, 取消);setButtonText(QWizard::BackButton, 返回);这个是只有设置了setWizardStyle(QWizard::ModernStyle);样式后才会显示回退按钮只有添加了page页之后才会显示下一步按钮如果啥都没添加界面只有 cancel如果是最后一页显示是finish而不是下一步。 设置自定义按钮文本 setButtonText(QWizard::CustomButton1, 自定义1);setOptions(options() | QWizard::HaveCustomButton1);设置自定义按钮文本后不会显示只有设置setOptions()后才显示这个自定义按钮是每页都显示可以根据是否需要自行控制显隐。 设置page页 setPage(Page_Intro, new IntroPage);setPage(Page_Evaluate, new EvaluatePage);setPage(Page_Register, new RegisterPage);setPage(Page_Details, new DetailsPage);setPage(Page_Conclusion, new ConclusionPage);第一个参数为自定义id可以重写QWizard 的 nextId()方法自定义上一步下一步具体跳到某页。 设置帮助 按钮 setOption(HaveHelpButton, true);设置像素图 setPixmap(QWizard::LogoPixmap, QPixmap(:/images/logo.png));registerField(const QString name, QWidget *widget, const char *property Q_NULLPTR, const char *changedSignal Q_NULLPTR)方法 registerField(details.company*, companyLineEdit);registerField(details.email*, emailLineEdit);registerField(details.postal*, postalLineEdit);创建一个名为name的字段该字段与给定小部件的给定属性关联。从那时起可以使用field()和setField()访问该属性。 字段对于整个向导来说是全局的并且使任何单个页面都可以轻松访问由另一个页面存储的信息而不必将所有逻辑放在QWizard中也不必让页面显式地了解彼此。 “name”以“*”结尾时为必填字段。当页面有强制字段时Next和/或Finish按钮只有在所有强制字段都填满时才启用。这需要指定一个changedSignal以告诉QWizard重新检查由必填字段存储的值。 调用,不加后面的* field(details.email).toString();QWizardPage::setCommitPage(bool commitPage)方法 如果commitPage为true则将该页设置为提交页;否则将其设置为普通页面。 提交页是表示不能通过单击“返回”或“取消”来撤消的操作的页面。 提交按钮取代提交页面上的Next按钮。单击此按钮只调用QWizard::next()就像单击next一样。 直接从提交页面进入的页面会禁用后退按钮。 创建QWizardPage QWizardPage *createIntroPage(){QWizardPage *page new QWizardPage;page-setTitle(Introduction);QLabel *label new QLabel(This wizard will help you register your copy of Super Product Two.);label-setWordWrap(true);QVBoxLayout *layout new QVBoxLayout;layout-addWidget(label);page-setLayout(layout);return page;}调用 int main(int argc, char *argv[]){QApplication app(argc, argv);// 以下是翻译根据不同style可以显示不同的最下方按钮为中文#ifndef QT_NO_TRANSLATIONQString translatorFileName QLatin1String(qt_);translatorFileName QLocale::system().name();QTranslator *translator new QTranslator(app);if (translator-load(translatorFileName, QLibraryInfo::location(QLibraryInfo::TranslationsPath)))app.installTranslator(translator);#endifQWizard wizard;wizard.addPage(createIntroPage());wizard.addPage(createRegistrationPage());wizard.addPage(createConclusionPage());wizard.setWindowTitle(Trivial Wizard);wizard.show();return app.exec();}完整示例 #include QtWidgets #include QTranslator #include QLocale #include QLibraryInfo// 创建Intro页 QWizardPage *createIntroPage() {QWizardPage *page new QWizardPage;page-setTitle(Introduction);QLabel *label new QLabel(This wizard will help you register your copy of Super Product Two.);label-setWordWrap(true);QVBoxLayout *layout new QVBoxLayout;layout-addWidget(label);page-setLayout(layout);return page; } // 创建Registration页 QWizardPage *createRegistrationPage() {QWizardPage *page new QWizardPage;page-setTitle(Registration);page-setSubTitle(Please fill both fields.);QLabel *nameLabel new QLabel(Name:);QLineEdit *nameLineEdit new QLineEdit;QLabel *emailLabel new QLabel(Email address:);QLineEdit *emailLineEdit new QLineEdit;QGridLayout *layout new QGridLayout;layout-addWidget(nameLabel, 0, 0);layout-addWidget(nameLineEdit, 0, 1);layout-addWidget(emailLabel, 1, 0);layout-addWidget(emailLineEdit, 1, 1);page-setLayout(layout);return page; } // 创建Conclusion页 QWizardPage *createConclusionPage() {QWizardPage *page new QWizardPage;page-setTitle(Conclusion);QLabel *label new QLabel(You are now successfully registered. Have a nice day!);label-setWordWrap(true);QVBoxLayout *layout new QVBoxLayout;layout-addWidget(label);page-setLayout(layout);return page; } // 调用 int main(int argc, char *argv[]) {QApplication app(argc, argv);// 翻译 #ifndef QT_NO_TRANSLATIONQString translatorFileName QLatin1String(qt_);translatorFileName QLocale::system().name();QTranslator *translator new QTranslator(app);if (translator-load(translatorFileName, QLibraryInfo::location(QLibraryInfo::TranslationsPath)))app.installTranslator(translator); #endifQWizard wizard;wizard.addPage(createIntroPage());wizard.addPage(createRegistrationPage());wizard.addPage(createConclusionPage());wizard.setWindowTitle(Trivial Wizard);wizard.show();return app.exec(); }解释 代码定义了一个简单的 Qt 向导包括三个页面Intro介绍、Registration注册和Conclusion结论并提供了一些翻译支持。 在 createIntroPage() 函数中创建了一个 QWizardPage 对象设置了页面的标题和一个 QLabel用于显示介绍文字。 在 createRegistrationPage() 函数中同样创建了一个 QWizardPage 对象并设置了页面的标题和子标题。然后添加了两个 QLineEdit 和两个 QLabel用于输入和显示用户的姓名和电子邮件地址。 在 createConclusionPage() 函数中也创建了一个 QWizardPage 对象并设置了页面的标题和一个 QLabel用于显示注册成功的消息。 在 main() 函数中首先创建了一个 QApplication 对象用于运行整个 Qt 应用程序。然后检查是否启用了翻译功能如果是则加载相应的翻译文件并将其安装到应用程序中。 接下来创建了一个 QWizard 对象并添加了三个页面。设置了向导的标题并显示出来。最后调用 app.exec() 运行应用程序进入 Qt 的事件循环直到应用程序关闭或者通过主动退出来结束。
http://www.huolong8.cn/news/30216/

相关文章:

  • nodejs 做网站js交件可以免费开店的平台
  • 门头沟区专业网站制作网站建设建设银行官方网站打不开啊
  • 中山做网站服务好ps里新建网站尺寸怎么做
  • 织梦医院网站模板一站式服务大厅官网
  • 怎样给网站做关键词优化记事本怎样做网站
  • 口碑好的福州网站建设网络部署方案
  • 计算机应用技术php网站开发论文网站建设格式
  • 网站建设项目实践山西手动网站建设推广
  • 房地产网站cms徐州网约车
  • 网站建设设计制作包头三个好消息
  • 如何建立网站快捷方式做一个企业网站价格
  • 凉山州城乡规划建设局网站网站后台编辑器
  • 网站优化培训中心网站建设协议书模板 完整版
  • 计算机网站建设职业群wordpress 导航站
  • 设计参考网站推荐彩票网站开发系统如何搭建
  • 泉州做网站联系方式wordpress评论美化插件
  • 重庆seo整站优化设置网站建设教程软件下载
  • 营销型网站建设式球磨机263企业邮箱登录入口手机版
  • 网站监测营销管理网站
  • 做网站一般注册商标哪个类分销系统方案
  • 网站开发有专利吗网上营销网站
  • 牛商网建设的食品网站深圳物流公司收费标准
  • 哪里可以做免费的物流网站电竞网站开发需求报告
  • 广东省建设工程执业中心网站如何做自己官方网站
  • 网站怎么做电脑系统下载江苏省网站备案查询
  • 网站建设有关要求宣传片制作公司推荐
  • 技术支持 骏域网站建设专家佛山比58同城做的好的网站
  • google网站搜索知名设计品牌有哪些
  • 中山微网站建设多少钱wordpress504
  • 专业个人网站建设o2o网站开发公司