Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 1

Qt-interest Archive, February 2008
QLineEdits not editable


Message 1 in thread

I have a strange issue here.  I've built a application on my machine:
gentoo Linux , Qt 4.3.2
It compiles and runs fine.  However, when I copy the source and copy it
to another machine
(Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.

I even explicitly set read only to false, and have the same issue.

I'm pretty sure I have the main pieces here.  I'm updating the target
machine to 4.3.2,
but am still very curious.

class myclass : public QDialog
{
    Q_OBJECT
public:
    QLineEdit*   my_line_edit;
    QGroupBox*    base_group_box;
private:
    // blah
private slots:
    // blah
};

myclass::myclass( QWidget* parent, const char* name ) : QDialog( parent,
name )
{
    // constructor
}

void myclass::create_layout()
{
    base_group_box = new QGroupBox( "wee" );
    QGridLayout *layout = new QGridLayout;
    my_line_edit = new QLineEdit;
    my_line_edit->setText( "Some value" );
    my_line_edit->setReadOnly( false ); // paranoid

    layout->addWidget( my_line_edit, x, y );
    base_group_box->setLayout( layout );  
}

--
 [ signature omitted ] 

Message 2 in thread

Paul England wrote:
>I have a strange issue here.  I've built a application on my machine:
>gentoo Linux , Qt 4.3.2
>It compiles and runs fine.  However, when I copy the source and copy it
>to another machine
>(Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.

Stop. Regardless of anything else, you cannot build against one Qt version 
and run against an older one.

You can run against newer versions though.

-- 
 [ signature omitted ] 

Attachment: signature.asc
Description: This is a digitally signed message part.


Message 3 in thread

1: I'm recompiling for each machine I try it on
2: I upgraded another machine to 4.3.2, recompiled, ran it, and have the
same problem.

Thiago Macieira wrote:
> Paul England wrote:
>   
>> I have a strange issue here.  I've built a application on my machine:
>> gentoo Linux , Qt 4.3.2
>> It compiles and runs fine.  However, when I copy the source and copy it
>> to another machine
>> (Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.
>>     
>
> Stop. Regardless of anything else, you cannot build against one Qt version 
> and run against an older one.
>
> You can run against newer versions though.
>
>   

--
 [ signature omitted ] 

Message 4 in thread

Then my guess (may be stupid :) ) is that the second machine has a problem  
somewhere else. It's *very* strange that the same version of Qt on  
different computers (with the same OS) gives different results.

On Tue, 05 Feb 2008 11:04:30 +0300, Paul England <pengland@xxxxxxxxxxxx>  
wrote:
> 1: I'm recompiling for each machine I try it on
> 2: I upgraded another machine to 4.3.2, recompiled, ran it, and have the
> same problem.
>
> Thiago Macieira wrote:
>> Paul England wrote:
>>
>>> I have a strange issue here.  I've built a application on my machine:
>>> gentoo Linux , Qt 4.3.2
>>> It compiles and runs fine.  However, when I copy the source and copy it
>>> to another machine
>>> (Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.
>>>
>>
>> Stop. Regardless of anything else, you cannot build against one Qt  
>> version
>> and run against an older one.
>>
>> You can run against newer versions though.
>>
>>
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with  
> "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/

-- 
 [ signature omitted ] 

Message 5 in thread

I should have been clearer.
I've tried this on at least 2 other machines (both with Qt4.x on them),
and I recompile on each machine the app will run on.  At first I thought
it was a problem with X as the app was running remotely.  On the machine
with the newly updated Qt 4.3.2, it is running locally, and giving the
exact same problem.

I will try to dumb it down and make sure I've not convoluted my code
somewhere.  The problem is that the target machines are remote, which
makes the process much slower.

Thanks
Paul

Constantin Makshin wrote:
> Then my guess (may be stupid :) ) is that the second machine has a
> problem somewhere else. It's *very* strange that the same version of
> Qt on different computers (with the same OS) gives different results.
>
> On Tue, 05 Feb 2008 11:04:30 +0300, Paul England
> <pengland@xxxxxxxxxxxx> wrote:
>> 1: I'm recompiling for each machine I try it on
>> 2: I upgraded another machine to 4.3.2, recompiled, ran it, and have the
>> same problem.
>>
>> Thiago Macieira wrote:
>>> Paul England wrote:
>>>
>>>> I have a strange issue here.  I've built a application on my machine:
>>>> gentoo Linux , Qt 4.3.2
>>>> It compiles and runs fine.  However, when I copy the source and
>>>> copy it
>>>> to another machine
>>>> (Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.
>>>>
>>>
>>> Stop. Regardless of anything else, you cannot build against one Qt
>>> version
>>> and run against an older one.
>>>
>>> You can run against newer versions though.
>>>
>>>
>>
>> -- 
>> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx
>> with "unsubscribe" in the subject or the body.
>> List archive and information: http://lists.trolltech.com/qt-interest/
>

--
 [ signature omitted ] 

Message 6 in thread

Have you ever recompiled it again in the original machine?
If that happened again in the original machine, then it means Some codes are
changed when you copy the codes. (i.e copying the source code file when you
are editing the codes in editor)

Secondly, Did you enable the groupbox or the other parent widgets?
If you set one of the parent widgets of QLineEdit to read-only or disabled,
QLineEdit will be disabled.

** This is my opinion (Just opinion, not technical or theoretical )
Qt4 seems like triggering paintEvent() many times. Even there was no event
except for mouse moving, paintEvent() was initiated many times.
And there are some issues with X, some image data objects are stored in
X-server(remote X-terminal) and others are stored in X-client(server). 
If you used a bunch of image data objects stored in X-client, then there
will be a bottle-neck.


-----Original Message-----
From: Paul England [mailto:pengland@xxxxxxxxxxxx] 
Sent: Tuesday, February 05, 2008 5:04 AM
To: Qt Interest
Subject: Re: QLineEdits not editable

I should have been clearer.
I've tried this on at least 2 other machines (both with Qt4.x on them),
and I recompile on each machine the app will run on.  At first I thought
it was a problem with X as the app was running remotely.  On the machine
with the newly updated Qt 4.3.2, it is running locally, and giving the
exact same problem.

I will try to dumb it down and make sure I've not convoluted my code
somewhere.  The problem is that the target machines are remote, which
makes the process much slower.

Thanks
Paul

Constantin Makshin wrote:
> Then my guess (may be stupid :) ) is that the second machine has a
> problem somewhere else. It's *very* strange that the same version of
> Qt on different computers (with the same OS) gives different results.
>
> On Tue, 05 Feb 2008 11:04:30 +0300, Paul England
> <pengland@xxxxxxxxxxxx> wrote:
>> 1: I'm recompiling for each machine I try it on
>> 2: I upgraded another machine to 4.3.2, recompiled, ran it, and have the
>> same problem.
>>
>> Thiago Macieira wrote:
>>> Paul England wrote:
>>>
>>>> I have a strange issue here.  I've built a application on my machine:
>>>> gentoo Linux , Qt 4.3.2
>>>> It compiles and runs fine.  However, when I copy the source and
>>>> copy it
>>>> to another machine
>>>> (Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.
>>>>
>>>
>>> Stop. Regardless of anything else, you cannot build against one Qt
>>> version
>>> and run against an older one.
>>>
>>> You can run against newer versions though.
>>>
>>>
>>
>> -- 
>> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx
>> with "unsubscribe" in the subject or the body.
>> List archive and information: http://lists.trolltech.com/qt-interest/
>

--
 [ signature omitted ] 

Message 7 in thread

Yes.  I make changes and recompile on the original machine (my
workstation) all the time.
I don't explicitly set the group box or anything else to read only.  I
only set the line edits
to readOnly(false) when I noticed the issue.

Samuel Byeongjun Park wrote:
> Have you ever recompiled it again in the original machine?
> If that happened again in the original machine, then it means Some codes are
> changed when you copy the codes. (i.e copying the source code file when you
> are editing the codes in editor)
>
> Secondly, Did you enable the groupbox or the other parent widgets?
> If you set one of the parent widgets of QLineEdit to read-only or disabled,
> QLineEdit will be disabled.
>
> ** This is my opinion (Just opinion, not technical or theoretical )
> Qt4 seems like triggering paintEvent() many times. Even there was no event
> except for mouse moving, paintEvent() was initiated many times.
> And there are some issues with X, some image data objects are stored in
> X-server(remote X-terminal) and others are stored in X-client(server). 
> If you used a bunch of image data objects stored in X-client, then there
> will be a bottle-neck.
>
>
> -----Original Message-----
> From: Paul England [mailto:pengland@xxxxxxxxxxxx] 
> Sent: Tuesday, February 05, 2008 5:04 AM
> To: Qt Interest
> Subject: Re: QLineEdits not editable
>
> I should have been clearer.
> I've tried this on at least 2 other machines (both with Qt4.x on them),
> and I recompile on each machine the app will run on.  At first I thought
> it was a problem with X as the app was running remotely.  On the machine
> with the newly updated Qt 4.3.2, it is running locally, and giving the
> exact same problem.
>
> I will try to dumb it down and make sure I've not convoluted my code
> somewhere.  The problem is that the target machines are remote, which
> makes the process much slower.
>
> Thanks
> Paul
>
> Constantin Makshin wrote:
>   
>> Then my guess (may be stupid :) ) is that the second machine has a
>> problem somewhere else. It's *very* strange that the same version of
>> Qt on different computers (with the same OS) gives different results.
>>
>> On Tue, 05 Feb 2008 11:04:30 +0300, Paul England
>> <pengland@xxxxxxxxxxxx> wrote:
>>     
>>> 1: I'm recompiling for each machine I try it on
>>> 2: I upgraded another machine to 4.3.2, recompiled, ran it, and have the
>>> same problem.
>>>
>>> Thiago Macieira wrote:
>>>       
>>>> Paul England wrote:
>>>>
>>>>         
>>>>> I have a strange issue here.  I've built a application on my machine:
>>>>> gentoo Linux , Qt 4.3.2
>>>>> It compiles and runs fine.  However, when I copy the source and
>>>>> copy it
>>>>> to another machine
>>>>> (Gentoo Linux qt 4.2.1), the line edits seem to be in view only mode.
>>>>>
>>>>>           
>>>> Stop. Regardless of anything else, you cannot build against one Qt
>>>> version
>>>> and run against an older one.
>>>>
>>>> You can run against newer versions though.
>>>>
>>>>
>>>>         
>>> -- 
>>> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx
>>> with "unsubscribe" in the subject or the body.
>>> List archive and information: http://lists.trolltech.com/qt-interest/
>>>       
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with
> "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
>
>
> --
> To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
> List archive and information: http://lists.trolltech.com/qt-interest/
>
>   

--
 [ signature omitted ] 

Message 8 in thread

Hi,

> Yes.  I make changes and recompile on the original machine (my
> workstation) all the time.
> I don't explicitly set the group box or anything else to read only.  I
> only set the line edits
> to readOnly(false) when I noticed the issue.

What do you notice exactly?

You said that "the line edits seem to be in view only mode" but I'm not sure 
what that means. Depending on the exact symptom

Also it's still not clear to me whether the problem is related to a specific 
version of Qt (Qt 4.2.1 vs. Qt 4.3.2) or to a specific workstation 
independently of the version of Qt.

--
 [ signature omitted ]