{"id":788,"date":"2023-08-18T10:15:15","date_gmt":"2023-08-18T02:15:15","guid":{"rendered":"https:\/\/zhaocunwei.co.uk\/?p=788"},"modified":"2023-08-18T10:21:27","modified_gmt":"2023-08-18T02:21:27","slug":"qt5","status":"publish","type":"post","link":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/","title":{"rendered":"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668"},"content":{"rendered":"<h1>\u524d\u8a00<\/h1>\n<p>\u6db5\u76d6\u4e86\u89c6\u9891\u64ad\u653e\u5668\u7684\u521b\u5efa\u548c\u57fa\u672c\u529f\u80fd<\/p>\n<h1>\u89c6\u9891\u64ad\u653e\u5668\u5b9e\u73b0\u793a\u4f8b<\/h1>\n<pre><code class=\"language-cpp\">#include &lt;QtWidgets&gt;\n#include &lt;QtMultimediaWidgets&gt;\nclass VideoPlayer : public QWidget {\n    Q_OBJECT\npublic:\n    VideoPlayer(QWidget *parent = nullptr)\n        : QWidget(parent)\n    {\n        QVBoxLayout *layout = new QVBoxLayout(this);\n        videoWidget = new QVideoWidget(this);\n        layout-&gt;addWidget(videoWidget);\n        mediaPlayer = new QMediaPlayer(this);\n        mediaPlayer-&gt;setVideoOutput(videoWidget);\n        controlLayout = new QHBoxLayout;\n        playButton = new QPushButton(&quot;Play&quot;);\n        pauseButton = new QPushButton(&quot;Pause&quot;);\n        controlLayout-&gt;addWidget(playButton);\n        controlLayout-&gt;addWidget(pauseButton);\n        layout-&gt;addLayout(controlLayout);\n        connect(playButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::play);\n        connect(pauseButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::pause);\n        \/\/ Replace with your video file path\n        videoFilePath = &quot;\/path\/to\/your\/video\/file.mp4&quot;;\n        mediaPlayer-&gt;setMedia(QUrl::fromLocalFile(videoFilePath));\n    }\n\nprivate slots:\n    void play() {\n        mediaPlayer-&gt;play();\n    }\n\n    void pause() {\n        mediaPlayer-&gt;pause();\n    }\n\nprivate:\n    QVideoWidget *videoWidget;\n    QMediaPlayer *mediaPlayer;\n    QPushButton *playButton;\n    QPushButton *pauseButton;\n    QHBoxLayout *controlLayout;\n    QString videoFilePath;\n};\n\nint main(int argc, char *argv[]) {\n    QApplication app(argc, argv);\n\n    VideoPlayer player;\n    player.show();\n\n    return app.exec();\n}\n#include &quot;main.moc&quot;<\/code><\/pre>\n<p>\u5728\u4e0a\u8ff0\u4ee3\u7801\u4e2d\uff0c\u6211\u4eec\u9996\u5148\u521b\u5efa\u4e00\u4e2a\u540d\u4e3aVideoPlayer\u7684\u81ea\u5b9a\u4e49QWidget\u7c7b\uff0c\u5176\u4e2d\u5305\u542b\u4e86\u4e00\u4e2a\u89c6\u9891\u64ad\u653e\u533a\u57df\uff08QVideoWidget\uff09\u548c\u63a7\u5236\u6309\u94ae\uff08Play\u548cPause\uff09\u3002\u64ad\u653e\u5668\u4f7f\u7528QMediaPlayer\u6765\u7ba1\u7406\u89c6\u9891\u64ad\u653e\uff0c\u5e76\u5c06\u89c6\u9891\u8f93\u51fa\u5230QVideoWidget\u3002<\/p>\n<p>\u8981\u6d4b\u8bd5\u6b64\u793a\u4f8b\uff0c\u60a8\u9700\u8981\u66ff\u6362videoFilePath\u53d8\u91cf\u4e2d\u7684\u8def\u5f84\u4e3a\u60a8\u81ea\u5df1\u7684\u89c6\u9891\u6587\u4ef6\u8def\u5f84\u3002\u7136\u540e\uff0c\u60a8\u53ef\u4ee5\u4f7f\u7528Qt Creator\u6216\u547d\u4ee4\u884c\u7f16\u8bd1\u5668\u6765\u6784\u5efa\u548c\u8fd0\u884c\u8be5\u5e94\u7528\u7a0b\u5e8f\u3002<\/p>\n<h1>\u5b9e\u73b0\u5feb\u8fdb\u548c\u5386\u53f2\u64ad\u653e\u8bb0\u5f55\u529f\u80fd<\/h1>\n<pre><code class=\"language-cpp\">#include &lt;QtWidgets&gt;\n#include &lt;QtMultimediaWidgets&gt;\n\nclass VideoPlayer : public QWidget {\n    Q_OBJECT\n\npublic:\n    VideoPlayer(QWidget *parent = nullptr)\n        : QWidget(parent)\n    {\n        QVBoxLayout *layout = new QVBoxLayout(this);\n        videoWidget = new QVideoWidget(this);\n        layout-&gt;addWidget(videoWidget);\n        mediaPlayer = new QMediaPlayer(this);\n        mediaPlayer-&gt;setVideoOutput(videoWidget);\n        controlLayout = new QHBoxLayout;\n        playButton = new QPushButton(&quot;Play&quot;);\n        pauseButton = new QPushButton(&quot;Pause&quot;);\n        forwardButton = new QPushButton(&quot;Forward&quot;);\n        historyButton = new QPushButton(&quot;History&quot;);\n        controlLayout-&gt;addWidget(playButton);\n        controlLayout-&gt;addWidget(pauseButton);\n        controlLayout-&gt;addWidget(forwardButton);\n        controlLayout-&gt;addWidget(historyButton);\n        layout-&gt;addLayout(controlLayout);\n        connect(playButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::play);\n        connect(pauseButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::pause);\n        connect(forwardButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::forward);\n        connect(historyButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::showHistory);\n        \/\/ Replace with your video file path\n        videoFilePath = &quot;\/path\/to\/your\/video\/file.mp4&quot;;\n        mediaPlayer-&gt;setMedia(QUrl::fromLocalFile(videoFilePath));\n    }\n\nprivate slots:\n    void play() {\n        mediaPlayer-&gt;play();\n    }\n\n    void pause() {\n        mediaPlayer-&gt;pause();\n    }\n\n    void forward() {\n        qint64 currentPosition = mediaPlayer-&gt;position();\n        qint64 newPosition = currentPosition + 10000; \/\/ Forward by 10 seconds\n        mediaPlayer-&gt;setPosition(newPosition);\n    }\n\n    void showHistory() {\n        QMediaPlaylist *playlist = mediaPlayer-&gt;playlist();\n        if (!playlist) {\n            playlist = new QMediaPlaylist(mediaPlayer);\n            mediaPlayer-&gt;setPlaylist(playlist);\n        }\n        \/\/ Save the current position to the history\n        playlist-&gt;addMedia(QUrl::fromLocalFile(videoFilePath));\n        \/\/ Play the last item in the playlist (latest history entry)\n        mediaPlayer-&gt;setPlaylist(playlist);\n        mediaPlayer-&gt;play();\n    }\n\nprivate:\n    QVideoWidget *videoWidget;\n    QMediaPlayer *mediaPlayer;\n    QPushButton *playButton;\n    QPushButton *pauseButton;\n    QPushButton *forwardButton;\n    QPushButton *historyButton;\n    QHBoxLayout *controlLayout;\n    QString videoFilePath;\n};\n\nint main(int argc, char *argv[]) {\n    QApplication app(argc, argv);\n\n    VideoPlayer player;\n    player.show();\n\n    return app.exec();\n}\n#include &quot;main.moc&quot;<\/code><\/pre>\n<h1>\u5386\u53f2\u64ad\u653e\u8bb0\u5f55<\/h1>\n<pre><code class=\"language-cpp\">#include &lt;QtWidgets&gt;\n#include &lt;QtMultimediaWidgets&gt;\n\nclass VideoPlayer : public QWidget {\n    Q_OBJECT\n\npublic:\n    VideoPlayer(QWidget *parent = nullptr)\n        : QWidget(parent)\n    {\n        QVBoxLayout *layout = new QVBoxLayout(this);\n        videoWidget = new QVideoWidget(this);\n        layout-&gt;addWidget(videoWidget);\n        mediaPlayer = new QMediaPlayer(this);\n        mediaPlayer-&gt;setVideoOutput(videoWidget);\n        controlLayout = new QHBoxLayout;\n        playButton = new QPushButton(&quot;Play&quot;);\n        pauseButton = new QPushButton(&quot;Pause&quot;);\n        forwardButton = new QPushButton(&quot;Forward&quot;);\n        historyButton = new QPushButton(&quot;History&quot;);\n        controlLayout-&gt;addWidget(playButton);\n        controlLayout-&gt;addWidget(pauseButton);\n        controlLayout-&gt;addWidget(forwardButton);\n        controlLayout-&gt;addWidget(historyButton);\n        layout-&gt;addLayout(controlLayout);\n        connect(playButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::play);\n        connect(pauseButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::pause);\n        connect(forwardButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::forward);\n        connect(historyButton, &amp;QPushButton::clicked, this, &amp;VideoPlayer::showHistory);\n        \/\/ Create a media playlist for history\n        historyPlaylist = new QMediaPlaylist(mediaPlayer);\n        mediaPlayer-&gt;setPlaylist(historyPlaylist);\n        \/\/ Replace with your video file path\n        videoFilePath = &quot;\/path\/to\/your\/video\/file.mp4&quot;;\n        mediaPlayer-&gt;setMedia(QUrl::fromLocalFile(videoFilePath));\n    }\n\nprivate slots:\n    void play() {\n        mediaPlayer-&gt;play();\n    }\n\n    void pause() {\n        mediaPlayer-&gt;pause();\n    }\n\n    void forward() {\n        qint64 currentPosition = mediaPlayer-&gt;position();\n        qint64 newPosition = currentPosition + 10000; \/\/ Forward by 10 seconds\n        mediaPlayer-&gt;setPosition(newPosition);\n    }\n\n    void showHistory() {\n        \/\/ Play the last item in the history playlist\n        if (historyPlaylist-&gt;mediaCount() &gt; 0) {\n            historyPlaylist-&gt;setCurrentIndex(historyPlaylist-&gt;mediaCount() - 1);\n            mediaPlayer-&gt;play();\n        }\n    }\n\nprivate:\n    QVideoWidget *videoWidget;\n    QMediaPlayer *mediaPlayer;\n    QMediaPlaylist *historyPlaylist;\n    QPushButton *playButton;\n    QPushButton *pauseButton;\n    QPushButton *forwardButton;\n    QPushButton *historyButton;\n    QHBoxLayout *controlLayout;\n    QString videoFilePath;\n};\n\nint main(int argc, char *argv[]) {\n    QApplication app(argc, argv);\n\n    VideoPlayer player;\n    player.show();\n\n    return app.exec();\n}\n\n#include &quot;main.moc&quot;<\/code><\/pre>\n<h1>\u5b9e\u73b0\u964d\u566a\u5904\u7406<\/h1>\n<pre><code class=\"language-cpp\">#include &lt;QtWidgets&gt;\n#include &lt;QtMultimedia&gt;\n\nclass NoiseReducer : public QWidget {\n    Q_OBJECT\n\npublic:\n    NoiseReducer(QWidget *parent = nullptr)\n        : QWidget(parent)\n    {\n        QVBoxLayout *layout = new QVBoxLayout(this);\n\n        startButton = new QPushButton(&quot;Start Recording&quot;);\n        stopButton = new QPushButton(&quot;Stop Recording&quot;);\n        toggleNoiseReductionButton = new QPushButton(&quot;Toggle Noise Reduction&quot;);\n\n        layout-&gt;addWidget(startButton);\n        layout-&gt;addWidget(stopButton);\n        layout-&gt;addWidget(toggleNoiseReductionButton);\n\n        connect(startButton, &amp;QPushButton::clicked, this, &amp;NoiseReducer::startRecording);\n        connect(stopButton, &amp;QPushButton::clicked, this, &amp;NoiseReducer::stopRecording);\n        connect(toggleNoiseReductionButton, &amp;QPushButton::clicked, this, &amp;NoiseReducer::toggleNoiseReduction);\n\n        audioInput = nullptr;\n        audioOutput = nullptr;\n        noiseReductionEnabled = false;\n    }\n\nprivate slots:\n    void startRecording() {\n        QAudioFormat format;\n        format.setSampleRate(44100);\n        format.setChannelCount(1);\n        format.setSampleSize(16);\n        format.setCodec(&quot;audio\/pcm&quot;);\n        format.setByteOrder(QAudioFormat::LittleEndian);\n        format.setSampleType(QAudioFormat::SignedInt);\n\n        QAudioDeviceInfo inputDeviceInfo = QAudioDeviceInfo::defaultInputDevice();\n        if (!inputDeviceInfo.isFormatSupported(format)) {\n            qWarning() &lt;&lt; &quot;Default format not supported, trying to use nearest&quot;;\n            format = inputDeviceInfo.nearestFormat(format);\n        }\n\n        audioInput = new QAudioInput(inputDeviceInfo, format, this);\n\n        noiseReductionBuffer.clear();\n        audioInputIODevice = audioInput-&gt;start();\n        connect(audioInputIODevice, &amp;QIODevice::readyRead, this, &amp;NoiseReducer::processAudioData);\n    }\n\n    void stopRecording() {\n        if (audioInput) {\n            audioInput-&gt;stop();\n            delete audioInput;\n            audioInput = nullptr;\n        }\n    }\n\n    void toggleNoiseReduction() {\n        noiseReductionEnabled = !noiseReductionEnabled;\n    }\n\n    void processAudioData() {\n        QByteArray audioData = audioInputIODevice-&gt;readAll();\n\n        if (noiseReductionEnabled) {\n            \/\/ Apply a simple moving average filter to simulate noise reduction\n            noiseReductionBuffer.append(audioData);\n            if (noiseReductionBuffer.size() &gt; 44100) {  \/\/ Adjust buffer size based on your needs\n                noiseReductionBuffer.remove(0, noiseReductionBuffer.size() - 44100);\n            }\n\n            \/\/ Calculate the average value and replace the audio data with the average\n            qint16 average = 0;\n            for (char value : noiseReductionBuffer) {\n                average += static_cast&lt;qint8&gt;(value);\n            }\n            average \/= noiseReductionBuffer.size();\n\n            audioData.fill(static_cast&lt;char&gt;(average), audioData.size());\n        }\n\n        \/\/ Play the processed audio\n        if (!audioOutput) {\n            audioOutput = new QAudioOutput(QAudioDeviceInfo::defaultOutputDevice(), audioInput-&gt;format(), this);\n            audioOutputIODevice = audioOutput-&gt;start();\n        }\n        audioOutputIODevice-&gt;write(audioData);\n    }\n\nprivate:\n    QPushButton *startButton;\n    QPushButton *stopButton;\n    QPushButton *toggleNoiseReductionButton;\n    QAudioInput *audioInput;\n    QIODevice *audioInputIODevice;\n    QAudioOutput *audioOutput;\n    QIODevice *audioOutputIODevice;\n    QByteArray noiseReductionBuffer;\n    bool noiseReductionEnabled;\n};\n\nint main(int argc, char *argv[]) {\n    QApplication app(argc, argv);\n\n    NoiseReducer noiseReducer;\n    noiseReducer.show();\n\n    return app.exec();\n}\n\n#include &quot;main.moc&quot;\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u524d\u8a00 \u6db5\u76d6\u4e86\u89c6\u9891\u64ad\u653e\u5668\u7684\u521b\u5efa\u548c\u57fa\u672c\u529f\u80fd \u89c6\u9891\u64ad\u653e\u5668\u5b9e\u73b0\u793a\u4f8b #include &lt;QtWidgets&#038;gt [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_mi_skip_tracking":false},"categories":[1],"tags":[],"aioseo_notices":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug\" \/>\n<meta property=\"og:description\" content=\"\u524d\u8a00 \u6db5\u76d6\u4e86\u89c6\u9891\u64ad\u653e\u5668\u7684\u521b\u5efa\u548c\u57fa\u672c\u529f\u80fd \u89c6\u9891\u64ad\u653e\u5668\u5b9e\u73b0\u793a\u4f8b #include &lt;QtWidgets&amp;gt [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/\" \/>\n<meta property=\"og:site_name\" content=\"\u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug\" \/>\n<meta property=\"article:published_time\" content=\"2023-08-18T02:15:15+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-08-18T02:21:27+00:00\" \/>\n<meta name=\"author\" content=\"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"5\u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/\",\"url\":\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/\",\"name\":\"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug\",\"isPartOf\":{\"@id\":\"https:\/\/zhaocunwei.co.uk\/#website\"},\"datePublished\":\"2023-08-18T02:15:15+00:00\",\"dateModified\":\"2023-08-18T02:21:27+00:00\",\"author\":{\"@id\":\"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/dfb1dc0fc4a330c41908d477cd99c0b4\"},\"breadcrumb\":{\"@id\":\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/#breadcrumb\"},\"inLanguage\":\"zh-CN\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/zhaocunwei.co.uk\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/zhaocunwei.co.uk\/#website\",\"url\":\"https:\/\/zhaocunwei.co.uk\/\",\"name\":\"\u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug\",\"description\":\"This site shares programming bugs\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/zhaocunwei.co.uk\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-CN\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/dfb1dc0fc4a330c41908d477cd99c0b4\",\"name\":\"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-CN\",\"@id\":\"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/4226cc1ca6640507df1d2d4ba3da7a62?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/4226cc1ca6640507df1d2d4ba3da7a62?s=96&d=mm&r=g\",\"caption\":\"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46\"},\"sameAs\":[\"http:\/\/zhaocunwei.co.uk\"],\"url\":\"https:\/\/zhaocunwei.co.uk\/index.php\/author\/18500103508163-com\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/","og_locale":"zh_CN","og_type":"article","og_title":"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug","og_description":"\u524d\u8a00 \u6db5\u76d6\u4e86\u89c6\u9891\u64ad\u653e\u5668\u7684\u521b\u5efa\u548c\u57fa\u672c\u529f\u80fd \u89c6\u9891\u64ad\u653e\u5668\u5b9e\u73b0\u793a\u4f8b #include &lt;QtWidgets&gt [&hellip;]","og_url":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/","og_site_name":"\u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug","article_published_time":"2023-08-18T02:15:15+00:00","article_modified_time":"2023-08-18T02:21:27+00:00","author":"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"5\u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/","url":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/","name":"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668 - \u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug","isPartOf":{"@id":"https:\/\/zhaocunwei.co.uk\/#website"},"datePublished":"2023-08-18T02:15:15+00:00","dateModified":"2023-08-18T02:21:27+00:00","author":{"@id":"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/dfb1dc0fc4a330c41908d477cd99c0b4"},"breadcrumb":{"@id":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/#breadcrumb"},"inLanguage":"zh-CN","potentialAction":[{"@type":"ReadAction","target":["https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/zhaocunwei.co.uk\/index.php\/2023\/08\/18\/qt5\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/zhaocunwei.co.uk\/"},{"@type":"ListItem","position":2,"name":"QT5\u5b9e\u73b0\u89c6\u9891\u64ad\u653e\u5668"}]},{"@type":"WebSite","@id":"https:\/\/zhaocunwei.co.uk\/#website","url":"https:\/\/zhaocunwei.co.uk\/","name":"\u672c\u7f51\u7ad9\u5206\u4eab\u7f16\u7a0b\u8fc7\u7a0b\u4e2d\u51fa\u73b0\u7684bug","description":"This site shares programming bugs","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/zhaocunwei.co.uk\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-CN"},{"@type":"Person","@id":"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/dfb1dc0fc4a330c41908d477cd99c0b4","name":"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46","image":{"@type":"ImageObject","inLanguage":"zh-CN","@id":"https:\/\/zhaocunwei.co.uk\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/4226cc1ca6640507df1d2d4ba3da7a62?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/4226cc1ca6640507df1d2d4ba3da7a62?s=96&d=mm&r=g","caption":"\u603b\u662f\u5e78\u798f\u7684\u8001\u8c4c\u8c46"},"sameAs":["http:\/\/zhaocunwei.co.uk"],"url":"https:\/\/zhaocunwei.co.uk\/index.php\/author\/18500103508163-com\/"}]}},"_links":{"self":[{"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/posts\/788"}],"collection":[{"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/comments?post=788"}],"version-history":[{"count":1,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/posts\/788\/revisions"}],"predecessor-version":[{"id":789,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/posts\/788\/revisions\/789"}],"wp:attachment":[{"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/media?parent=788"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/categories?post=788"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/zhaocunwei.co.uk\/index.php\/wp-json\/wp\/v2\/tags?post=788"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}