QSpinBox 和 QSlider 联合使用方法
在Qt中,有时候我们想要联合QSpinBox 和 QSlider,使得移动滑块,QSpinBox中的数据会变化,或者我们在QSpinBox中输入一个数值,响应的滑块也会变化,如下图所示:
aaarticlea/png;base64,iVBORw0KGgoAAAANSUhEUgAAATMAAAB8CAIAAACKQ8AEAAAACXBIWXMAAA7EAAAOxAGVKw4bAAAgAElEQVR42u2dd3hUV5bg5b92v+ndmd2dnt39JvS4p7vd48aYaRsZMMkydI9BksnJ5IxIQjlHlFHOOedQClXKOecslBMiGmOiDdiGZc+5971Xr4KEaEOZNvd8v6949arqFRV+dc4N70rrmSh0dXV/8fdvMxgMzbN27VqxjFr0nx07dvzil7/+P//yjqt36LVbDyjXb31zHS/pxl8H1/4CvlLlgSpX58lNOVfUcP/yl7MyQ7mBXLpxT871e9Nirt2bunZXYBK4ikxcvUM3xIjvqQocavq6MpcERP+HGeS+Avx/WPj/f/vo+917Dz552eEfEPRyDxh69uiT1yZ2/+eah4++B+/APnDws88+k5sJWv7N3/6Dp39Ex+C16Pwel9gGQiOhwTW2EYlrAtziFXCPbwbcgIRm94QWwANIbPFKbkOSWoELyRzeyW3eKSokPx/y8Lb54JXcKuApgvv/JLd5JrVSPAQSlaEvxD2Rwy0BcY1vFuMS13w+rglwgctYxJkS0+gUjThGIfaR9XYR9bbhHFYhtVahtRbBtebBNWZBNaaB1YBJQJWRf9U5P8TQr/KMTwVw2rv81AXkhGcpcNyj9Kh76VG3kiOuxYdcig+eLzrgXLTPuXCvY+EeR9lue9kX9tJddgU7bAt2EmB7l50UdgJwKwB32ws4yfY5Fe53LjxwHi/hOAAc8LArAsc/6s4Bz0if+oRnmYFX2ckLZfCfgcvT3hUU+E+e9a0451eJ+CNG/pVdIzfe/1hvaOpmZduEQFX7pBLVlA4FalTpRAYmvrSw94DfhdrOqedSB3SJmVZlcPJm4PH9Y62dPUnJQH9y8kAKMpSSPIwkjRMmU5KmkYSZlITLKQlXZueyytWZ1MRpJHkqNXkyNXk8NXks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HCPJFEzSQkCloqmSnWUtXM52r5Zpn54pWtqLhVJydoeTRptrJ2/pWt2Mw55Hytkuf8FZ1nTSs30zBzHWgpqml1Sc4U5NQ3leiboZ80bVI5N4OWljRncnJaBNeUtkyCg2Dihx9+yJlJ5QRTIY26eoeOX7k9fhkZo8wgozNfC4xcUuLW8DTla36DY2j+TL1CBqe+UuTWj+Crn5wXeO2id3hYDV8rc2kuRl4mt+fFzMtk9JVBHRm7rMQdgXHgCn8pYoIHvAP7wEGqpdxMGkuXLv3F37/NYDA0z8KFC8Uy/n/mLDU6LeAA3wAAAABJRU5ErkJggg==" alt="" width="207" height="83" />
那么我们可以用如下的代码来实现:
ui.setupUi(this);
ui.spinBox->setRange(, );
ui.slider->setRange(, );
connect(ui.spinBox,SIGNAL(valueChanged(int)), ui.slider,SLOT(setValue(int)));
connect(ui.slider,SIGNAL(valueChanged(int)), ui.spinBox,SLOT(setValue(int)));
QSpinBox 和 QSlider 联合使用方法的更多相关文章
- Vivado与SDK的联合调试方法-使用ILA
首先介绍一下我的硬件平台:使用的开发板为米联客出的MIZ702,这个开发板与ZedBoard是兼容的. Vivado硬件调试有几种手段:ILA(集成逻辑分析器Integrated Logic Anal ...
- jpa 联合查询方法
public interface TaskBaseline { String getNumber(); String getTitle(); String getName(); String getP ...
- Adams/Car与Simulink联合仿真方法
必须是Assembly装配体才行,并支持仿真设置.这里使用MDI_Demo_Vehicle模型,输出前缀为test1,输出选择files_only.然后OK输出. 生成的文件如下: 在Plant Ex ...
- C# ashx与html的联合使用
本文将介绍ashx和html的联合使用方法,尽管目前流行mvc,但handler一般处理程序还是ASP.NET的基础知识,结合html页面,做出来的网页绝对比WebForm的简洁和效率高. 首先,概要 ...
- mybatis使用接口联合查询
一.先建立两个实体类和配置文件 配置文件 <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE c ...
- qt编程入门
面对qt编程,必须先知道qt中常用的类: QPushButton按钮类.QLabel标签类.QMessageBox对话框类.QCheckBox.QAction.QMenu.QStatusBar.QTo ...
- 第六章 Qt布局管理器Layout
第六章 Qt布局管理器Layout 大家有没有发现一个现象,我们放置一个组件,给组件最原始的定位是给出这个控件的坐标和宽高值,这样Qt就知道这个组件的位置.当用户改变窗口的大小,组件还静静地呆在原来的 ...
- C++ GUI Programming with Qt4 笔记 -- chap1
1. Hello Qt #include <QApplication> #include <QLabel> int main(int argc, char *argv[]){ ...
- 界面编程之QT窗口系统20180726
/*******************************************************************************************/ 一.坐标系统 ...
随机推荐
- 【vijos】P1514天才的记忆
描述 从前有个人名叫W and N and B,他有着天才般的记忆力,他珍藏了许多许多的宝藏.在他离世之后留给后人一个难题(专门考验记忆力的啊!),如果谁能轻松回答出这个问题,便可以继承他的宝藏.题目 ...
- objective-c 遍历文件夹查看文件
#import <Foundation/Foundation.h>int main (int argc, const char * argv[]){ @autoreleasepool ...
- LoadRunner替换字符串(可以同时替换多个)
在global.h中添加代码 /* * @param char* dest 目标串,也就是替换后的新串 * @param const char* src 源字符串,被替换的字符串 * @param c ...
- hdu1166 线段树
Problem Description C国的死对头A国这段时间正在进行军事演习,所以C国间谍头子Derek和他手下Tidy又开始忙乎了.A国在海岸线沿直线布置了N个工兵营地,Derek和Tidy的任 ...
- BZOJ 2565 回文串-Manacher
题目链接:http://www.lydsy.com/JudgeOnline/problem.php?id=2565 题意:中文题 思路:定义L[i],R[i].表示以i为左端点/右端点时,最长回文串长 ...
- psql-04数据类型(2)
复合类型 PostgreSQL中可以如C语言中的结构体一样定义一个复合类型; 创建 create type person as ( name text, age int, sex boolean ); ...
- Uva12206 Stammering Aliens 后缀数组&&Hash
Dr. Ellie Arroway has established contact with an extraterrestrial civilization. However, all effort ...
- Docker中搭建Hadoop-2.6单机伪分布式集群
1 获取一个简单的Docker系统镜像,并建立一个容器. 1.1 这里我选择下载CentOS镜像 docker pull centos 1.2 通过docker tag命令将下载的CentOS镜像名称 ...
- 通过adb命令打印log
1.adb logcat --打印当前设备上所有日志 2.adb logcat | findstr *** --过滤仅含***的日志 3.adb logcat *:W --过滤打印严重级别W及以上 ...
- CodeForceS#276-B(求最大值)
B. Valuable Resources Many computer strategy games require building cities, recruiting army, conqu ...