Skip to content

3rd Party Software

Combining Qt with 3rd party libraries or components? Ask here!
1.1k Topics 5.5k Posts
  • Streaming contents of QByteArray SOLVED

    5
    0 Votes
    5 Posts
    3k Views
    G

    Finally got this working. Here is the code:

    @
    QByteArray star = getImage(":/images/star");
    char* starData = star.data();
    uint8_t* starData8t = (uint8_t*)starData;@

  • 0 Votes
    2 Posts
    871 Views
    sierdzioS

    Try trUtf8(), although it should be obsolete in Qt 5. Qt 5 expects (well, let's put it more strongly: requires) source code to be encoded in UTF-8.

  • QCA verify sign

    3
    0 Votes
    3 Posts
    3k Views
    E

    My way to answer this question:

    Load the public key
    @

    QCA::ConvertResult conv_res;
    QCA::PublicKey pub_key = QCA::PublicKey::fromPEMFile("public.pem", &conv_res);
    if(conv_res != QCA::ConvertGood){
    qDebug() << "Public key could not be loaded";
    return;
    }
    @

    Loading the signature file:
    @
    QFile sig_file("signature");
    sig_file.open(QFile::ReadOnly);
    QByteArray sig_text = sig_file.readAll();
    sig_file.close();
    @

    Finally verifying the signature
    @
    // sec_data is a plain data QCA::SecureArray object that was previosly decrypted using the private key counterpart of the public key being used here
    if(!pub_key.canVerify()){
    qDebug() << "Bad public key";
    return;
    }else{
    pub_key.startVerify(QCA::EMSA3_SHA1);
    pub_key.update(sec_data.data());
    if(pub_key.validSignature(sig_text)){
    qDebug() << "Signature verification suceedded";
    }else{
    qDebug() << "Signature verification failed";
    }

    // To make the verification in one step: if(pub_key.verifyMessage( sec_data.data(), sig_text, QCA::EMSA3_SHA1)){ Log::write(Log::Levels::Success, "One step signature validation succeeded"); } }

    @

    BTW, I used the following command to generate the signed digest of my data.txt file(using Ubuntu Linux):

    openssl dgst -verify public.pem -signature signature data.txt

  • Problem building quazip-Libary 0.5.1

    6
    0 Votes
    6 Posts
    11k Views
    A

    Hi LVreg,

    The problem is that QuaZIP can not find the zlib library. You should include the path of the headers an also the libraries when you run qmake:

    @
    qmake "INCLUDEPATH+=C:/Qt/Qt5/5.0.1/Src/qtbase/src/3rdparty/zlib" "LIBS+=-LC:/Qt/Qt5/5.0.1/Src/qtbase/src/3rdparty/zlib -lz"
    mingw32-make
    @

    There is a full explanation in my blog if you want to check it out: http://www.antonioborondo.com/2014/10/22/zipping-and-unzipping-files-with-qt/

  • 0 Votes
    6 Posts
    3k Views
    P

    Thanks for help.

  • 0 Votes
    2 Posts
    2k Views
    SGaistS

    Hi and welcome to devnet,

    Are you sure you are linking to the library containing that symbol ?

  • [Closed]Unicode symbols

    4
    0 Votes
    4 Posts
    1k Views
    I

    TextCodec is need to convert not UTF to UTF and vice versa. For example:
    @
    QTextCodec *codec = QTextCodec::codecForName("CP1251");
    ...
    QByteArray cp1251Array = codec->fromUnicode(utfString);
    QByteArray utfArray = codec->toUnicode(cp1251Array);
    @

  • QWT Framework not found

    10
    0 Votes
    10 Posts
    5k Views
    SGaistS

    Sorry for that. No it's not that. I was asking you (for testing purpose) to try linking to another framework (anything you like but not one of OS X's system framework and not a Qt dependent framework)

  • 0 Votes
    4 Posts
    1k Views
    SGaistS

    Are you sure all dependencies of the plugin can be found ?

  • 0 Votes
    5 Posts
    2k Views
    L

    That worked

    Thanks!

  • How to process SDL events with Qt?

    3
    0 Votes
    3 Posts
    3k Views
    T

    "Some progress", yes. It has been a while and I sadly didn't finish the whole project due to being unable to make the control scheme configurable (I will return to that). But I managed to pipe the input commands through a state machine which translated the digital ones into unique, user-readable strings (e.g. a short version of "button 25 released while buttons 7 and 9 were held down") while the analogue ones consisted of numbers and a string. That data was then mapped to some method and things started working. I don't remember all the coding details and am not yet sure if there isn't a better way to achieve what I need the program to do.

  • Qwt install fails at 'make' command

    4
    0 Votes
    4 Posts
    2k Views
    J

    I figured it out already, I had to uninstall Xcode 5, install Xcode 6, reinstall the xcode command line tools for Xcode 6, edit the qdevice.pri file, restart the computer and then it finally let me make and install qwt. I now have another issue, but I am going to post a new question for that. Thanks.

  • 0 Votes
    4 Posts
    4k Views
    SGaistS

    Good question, PDF compression ? :)

    Anyway, glad you succeeded. Happy coding !

  • 0 Votes
    1 Posts
    2k Views
    No one has replied
  • Lightweight RPC

    3
    0 Votes
    3 Posts
    9k Views
    B

    Hi RohitIti,
    unfortunately it's not part of QT, but it's available from the link above and easy to compile and integrate. So there's no need to write it on your own.

  • QT-Mediawiki

    7
    0 Votes
    7 Posts
    3k Views
    D

    I found:
    https://blogs.kde.org/2009/01/11/querying-wiki-using-qt

    And:
    https://gitorious.org/qt-examples/qt-examples/source/b335f5c23e9ae54abed073a926d7bfe0f28d8434:mediawiki

    Which is the same project of Richard Moore.

  • Thread optimization issue

    Locked
    1
    0 Votes
    1 Posts
    720 Views
    No one has replied
  • Qwt Direct Painter Clipping [SOLVED]

    2
    0 Votes
    2 Posts
    3k Views
    K

    Hello,
    I need real time clipped data plotting too. Could you please share your CustomPlot class implementation, so I can use it as an example? Or if you can't share it, at least post some references.

  • Qt 5.2.1 + OpenCV 2.4.9 in Visual Studio 2012

    8
    0 Votes
    8 Posts
    3k Views
    A

    Yeah, could habe been...
    I tried both... not changing anything... :/

    I'll try to get another webcam and will have a look if that is the reason!

  • 0 Votes
    3 Posts
    4k Views
    G

    Hi,

    Can anyone suggest, which lint tool is suitable for qt applications and how to use it. I found list of tools like PC Lint, cppcheck, valgrind, Coverity, Clang Static Analyzer etc.