Qt

The code is here .when i compile it says
error writing to -:invalid argument
what could be the problem???
help me im totaly stuck here

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
  #include "finddialog.h"
#include <QtGui>
#include <QHBoxLayout>
#include <QVBoxLayout>

FindDialog::FindDialog(QWidget *parent) :
    QMainWindow(parent)
{
    label=new QLabel(tr("Find &what"));
    lineEdit=new QLineEdit;
    label->setBuddy(lineEdit);

    caseCheckBox=new QCheckBox(tr("Match &case"));
    backwardCheckBox=new QCheckBox(tr("Search &backward"));

    findButton=new QPushButton(tr("&Find"));
    findButton->setDefault(true);
    findButton->setEnabled(false);

    closeButton=new QPushButton(tr("Close"));
    connect(lineEdit,SIGNAL(textChanged(const QString&)),this,SLOT(enableFindButton));
    connect(findButton,SIGNAL(clicked()),this,SLOT(close()));
    connect(closeButton,SIGNAL(clicked()),this,SLOT(close()));

    QHBoxLayout *topLeftLayout=new QHBoxLayout;
    topLeftLayout->addWidget(label);
    topLeftLayout->addWidget(lineEdit);

    QVBoxLayout *leftLayout=new QVBoxLayout;
    leftLayout->addLayout(topLeftLayout);
    leftLayout->addWidget(caseCheckBox);
    leftLayout->addWidget(backwardCheckBox);

    QVBoxLayout *rightLayout=new QVBoxLayout;
    rightLayout->addWidget(findButton);
    rightLayout->addWidget(closeButton);
    rightLayout->addStretch();

    QHBoxLayout *mainLayout=new QHBoxLayout;
    mainLayout->addLayout(leftLayout);
    mainLayout->addLayout(rightLayout);
    setLayout(mainLayout);
    setWindowTitle("Mahrukh");
    setFixedHeight(sizeHint().height());
}


void FindDialog::findClicked()
{
    QString text = lineEdit->text();
    Qt::CaseSensitivity cs = caseCheckBox->isChecked() ?Qt::CaseSensitive:Qt::CaseInsensitive;
    if(backwardCheckBox->isChecked()){

        emit findPrevious(text,cs);

    }
    else{
        emit findNext(text,cs);
    }

}

void FindDialog::enableFindButton(const QString &text)
{
    findButton->setEnabled(!text.isEmpty());
}
Also tell me where to find tutorials on Qt ....
i do not want drag and drop.....
Topic archived. No new replies allowed.