WxtextCtrl focux in LInux
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
WxtextCtrl focux in LInux
Hi,
SetFocus of wxtextctrl is not working when wxMIniframe is shown in linux.
Please Find attachement
SetFocus of wxtextctrl is not working when wxMIniframe is shown in linux.
Please Find attachement
You do not have the required permissions to view the files attached to this post.
-
- Part Of The Furniture
- Posts: 7481
- Joined: Sat Apr 16, 2005 7:22 am
- Location: USA, Ukraine
Re: WxtextCtrl focux in LInux
Hi,
Can you show some code?
- Do you use any EVT_SET_FOCUS event?
Also the usual stanza:
- wx version?
- Os version?
- exact GTK+ version used?
- how wx was compiled? any non-default options used?
Thank you.
Can you show some code?
- Do you use any EVT_SET_FOCUS event?
Also the usual stanza:
- wx version?
- Os version?
- exact GTK+ version used?
- how wx was compiled? any non-default options used?
Thank you.
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi , I tried with SetFocus() predefiend function and EVT_ACTIVATE.
Its a GTK+ Version.
Its a GTK+ Version.
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi ,
I tried with setFocus() function of wxTextctrl and EVT_ACTIVATE event.
its a GTK+ version.
I tried with setFocus() function of wxTextctrl and EVT_ACTIVATE event.
its a GTK+ version.
-
- Part Of The Furniture
- Posts: 7481
- Joined: Sat Apr 16, 2005 7:22 am
- Location: USA, Ukraine
Re: WxtextCtrl focux in LInux
Hi
What's wx version do you use?
What's an exact gtk+ version?
Can you post a code?
Thank you.
What's wx version do you use?
What's an exact gtk+ version?
Can you post a code?
Thank you.
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi,
Wx Version we are usinmg 3.0.2
GTK+ Version 2.0
Code::
//After Showing Miniframe frame without Destroying miniframe , i need to give focus to text ctrl
wxMiniframe::Show(true);
wxTextCtrl* txt = (wxTextCtrl*)FindWindowById(ID_SEARCH_TXTCTRL, m_pwxTextCtrlPanel);
txt->SetFocus();
Wx Version we are usinmg 3.0.2
GTK+ Version 2.0
Code::
//After Showing Miniframe frame without Destroying miniframe , i need to give focus to text ctrl
wxMiniframe::Show(true);
wxTextCtrl* txt = (wxTextCtrl*)FindWindowById(ID_SEARCH_TXTCTRL, m_pwxTextCtrlPanel);
txt->SetFocus();
-
- Part Of The Furniture
- Posts: 7481
- Joined: Sat Apr 16, 2005 7:22 am
- Location: USA, Ukraine
Re: WxtextCtrl focux in LInux
Hi,
Is text control inside the miniframe or in the main frame?
Is FindWindowById() function succeeds?
Where is the focus after the call to SetFocus()?
Thank you.
Is text control inside the miniframe or in the main frame?
Is FindWindowById() function succeeds?
Where is the focus after the call to SetFocus()?
Thank you.
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi ,
Text control is in mainfrom,
FindWindowbyid given text control, after that setfocus for that text control is not Working......
Text control is in mainfrom,
FindWindowbyid given text control, after that setfocus for that text control is not Working......
-
- Part Of The Furniture
- Posts: 7481
- Joined: Sat Apr 16, 2005 7:22 am
- Location: USA, Ukraine
Re: WxtextCtrl focux in LInux
Hi,
Which class has the code you showed in the OP?
Can you post complete function (including signature)?
Also please use <code></code> tags to simplify the code reading...
Thank you.
Which class has the code you showed in the OP?
Can you post complete function (including signature)?
Also please use <code></code> tags to simplify the code reading...
Thank you.
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi,
this is the code i am using,
pwxTextCtrlPanel -- wxPanel where txtx control is placeds
wxMiniframe::Show(true);
wxTextCtrl* txt = (wxTextCtrl*)FindWindowById(ID_SEARCH_TXTCTRL, m_pwxTextCtrlPanel);
txt->SetFocus();
this is the code i am using,
pwxTextCtrlPanel -- wxPanel where txtx control is placeds
wxMiniframe::Show(true);
wxTextCtrl* txt = (wxTextCtrl*)FindWindowById(ID_SEARCH_TXTCTRL, m_pwxTextCtrlPanel);
txt->SetFocus();
-
- Site Admin
- Posts: 4254
- Joined: Thu Jan 12, 2006 6:23 pm
- Location: IoW, UK
Re: WxtextCtrl focux in LInux
Hi,
You may feel that your request for help is not succeeding. That is because you are not giving us enough information to help you.
I don't mean that you should paste your whole program, but we need more than just those lines. The best way to help us to help you is to make a small compilable program that we can build and test. And the best way to do that is to add your code to the code of the the 'minimal' sample that comes with the wxWidgets source (and then ideally paste here a diff to 'minimal').
If you do that, not only can we see what is going wrong, but also you may find that your code does work inside 'minimal', which will help you to identify the problem.
Regards,
David
You may feel that your request for help is not succeeding. That is because you are not giving us enough information to help you.
You say "in Linux". Does the same code work on other platforms?SetFocus of wxtextctrl is not working when wxMIniframe is shown in linux.
No it isn't. It is just 3 lines of the code that you are using.this is the code i am using,
I don't mean that you should paste your whole program, but we need more than just those lines. The best way to help us to help you is to make a small compilable program that we can build and test. And the best way to do that is to add your code to the code of the the 'minimal' sample that comes with the wxWidgets source (and then ideally paste here a diff to 'minimal').
If you do that, not only can we see what is going wrong, but also you may find that your code does work inside 'minimal', which will help you to identify the problem.
Regards,
David
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
Hi ,
Please Find Find the attachement, and paste in widgets project in Samples.
Go to button project and click the buton change ....
Please Find Find the attachement, and paste in widgets project in Samples.
Go to button project and click the buton change ....
-
- Site Admin
- Posts: 4254
- Joined: Thu Jan 12, 2006 6:23 pm
- Location: IoW, UK
Re: WxtextCtrl focux in LInux
I don't think the new attachment uploaded. Certainly I can't see it here.
But you don't need an attachment. You should reduce your code to the smallest amount that shows the problem, diff it with 'minimal', then paste the diff here, using 'Code' tags (the button that says 'Code' above your post).
But you don't need an attachment. You should reduce your code to the smallest amount that shows the problem, diff it with 'minimal', then paste the diff here, using 'Code' tags (the button that says 'Code' above your post).
-
- Earned a small fee
- Posts: 10
- Joined: Thu May 10, 2018 12:47 pm
Re: WxtextCtrl focux in LInux
DavidHart wrote:I don't think the new attachment uploaded. Certainly I can't see it here.
But you don't need an attachment. You should reduce your code to the smallest amount that shows the problem, diff it with 'minimal', then paste the diff here, using 'Code' tags (the button that says 'Code' above your post).
Please find the minimal attachement
You do not have the required permissions to view the files attached to this post.