QLineEdit::Password mode not working on touch LCD , connected to ARM board.
hello,
i am facing some problem related to Password mode of QLineEdit. I am entering PIN Number into a QLineEdit box , which can take 6 digits and should display in password mode.
This works fine on PC,But when same code compiled for an ARM Board and run ,than it is not displaying *****. Other things works fine ,like editing and reading. But only problem is, * instead of digit is not getting displayed.
ARM Board has Touch LCD connected and I Am using Qt-4.6.2.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Hello,
can some one please have the hint for this. I am not getting any clue on this.
reply would be appreciated. Thanks in Advance.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Hello,
I am still struggling with this issue. Please reply me if some one knows.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Please provide the source code for the creation of the QLineEdit you are having problems with.
Whilst it is not working on your ARM board, what is value of EchoMode ?
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Dear squidge,
Thanks For your Reply.
I am using very simple code for QLineEdit, just Create it and
setEchoMode(Password),
But i just dont have the fundamentals of Different platform. Why it is working on PC and not on ARM Board. I dont think it has to do with code.
Still let me give u the code , for clarity.
/************************************************** ********/
menupin::menupin(QSignalMapper *mapper, QWidget *parent):QWidget(parent)
{
menu = new QWidget();
menu -> setGeoMetry(0,0,200,300); //just create a base widget
menu -> setStyleSheet("background: transparent;", "border:01;");
pinbox = new QLineEdit(menu); //create pinbox for editing pin
pinbox -> setGeoMetry(80,0,80,35);
pinbox -> setmaxlength(6); //Max length of PIN will be 6 digit
pinbox -> setEchoMode(QLineEdit :: Password);
pinbox -> show();
scene = new QGraphicsScene(); //Taking just a scene
scene -> addWidget(menu); //Adding main menu widget in this scene
view = new QGraphicsView( scene); //creating a view on the scene
view -> setParent(this, Qt::FrameLessWindowhint); //setting class object as a
//parent
view ->setFixedSize(300,200); //changing width and height
view ->rotate(-90); //rotate PINBOX -90 Degree
view -> show();
}
/************************************************** *******/
Please rember , For typing pin on LCD i am using Virtual KeyPad.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Hello,
Just tell me what is lacking in my code. Or is there any thing to do with the configuration.
Please, reply some one i am in trouble.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
No expert can reply to this ? I think this is a bug for Qt-4.6.2 for some platform.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
If you put default text into pin entry box, does it start with stars, or the actual text?
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Thanks squidge,
When I put default text ,than also it doesnt show any text. Neither Actual Text nor text with Stars.
When the same thing i do on my PC, it works fine as it should be.
I cant find out the problem. Please, help me someone.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Freinds,
i am still struggling ,please reply .
Thanks.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Hi savaliya_ambani,
Hope you are doing good.
I also came across the same problem couple of days ago and am also working on touch LCD with ARM board. Merely i played bit trick to get rid of this issue.
here i am using virtual keyboard which is designed by me. its basically a group of button controls and when ever button is pressed handle that events in slots, and in that slot, check for which widget(QLineEdit) is got focus and update that widget with button text using txtbox.setText(txtbox.setText()+btn.text()).
and when ever password QLineEdit got focus, have temparory QString variable in which you will keep updating the btn.text() and at the same time you set pwtxtBox.setText(pwtxtBox.setText()+"*").
when enterkey is pressed(meant to say from virtual keyboard that's enter button is pressed) validate the temparory QString. if your password and temparory string matched then you are set to go on if not clear pwtxtBox.setText("") and temparoty QString.
Thanks
Vijayaragavan S
Enjoy sharing knowledge.
Added after 11 minutes:
Hi savaliya_ambani,
Your code is absolutely rite. you can follow your code not a problem and in the previous message, am suppose to use pointer(->) instead of dot(.). i hope that will make you to come out of that big hurdle.
Thanks
Vijayaragavan
Enjoy sharing knowledge
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Dear Friend,
Its working . Font needs to be loaded.
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Quote:
Originally Posted by
mukesh.savaliya
Dear Friend,
Its working . Font needs to be loaded.
Hi...mukesh.savaliya , i met the same problem , but how to load the fonds? thx
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Please, Refer to the QFont classs and QFontDatabase::addApplicationFont.
This will also help you.
http://www.qtcentre.org/threads/2359...new-Font-to-QT
Re: QLineEdit::Password mode not working on touch LCD , connected to ARM board.
Sorry to bring this up again , I am facing the same problem too , getting a blank line edit even if i type in using password echo mode , Just wanna know what u did to solve it ? Setting font for the line edit or ??