Bits of Bytes
bits of coding, C++, Qt, git, gamedev, linux and other tech stuff
Davide Coppola November 22, 2016 4 Comments
Qt
API, C++, code, example, guide, Hacker News, http, JSON, network, networking, news, project, Qt, reader, REST, source, stories, tutorial
This tutorial will show you how to use Qt Network and JSON to create a simple Hacker News
← Previous post
Next post →
I would like to be able to set different colors for each row. 🙂
Regards
Add this code at the top of the StoryEntry constructor:
QPalette pal; pal.setColor(QPalette::Background, Qt::white); setAutoFillBackground(true); setPalette(pal);
Then you can play with it and pass a color to the constructor for example.
Thanks for this quick insight on how to use QNetworkManager.
Hello, I came across this problem, qt.network.ssl: QSslSocket::connectToHostEncrypted: TLS initialization failed ,could someone help me, please?
Your email address will not be published. Required fields are marked *
Save my name, email, and website in this browser for the next time I comment.
I would like to be able to set different colors for each row. 🙂
Regards
Add this code at the top of the StoryEntry constructor:
QPalette pal;
pal.setColor(QPalette::Background, Qt::white);
setAutoFillBackground(true);
setPalette(pal);
Then you can play with it and pass a color to the constructor for example.
Thanks for this quick insight on how to use QNetworkManager.
Hello, I came across this problem, qt.network.ssl: QSslSocket::connectToHostEncrypted: TLS initialization failed
,could someone help me, please?