- wxTextCtrl::SetLabel() worked in Windows 7 and does not in Ubuntu. I verified in the debugger it was passed the correct string.
I cannot read from configuration file I was able to in Windows 7. All files in the project, including the configuration file, have Read/Write permissions for user, group, and everyone else.
Porting a wxWidgets Application to Ubuntu
Porting a wxWidgets Application to Ubuntu
I am trying to run a wxWidgets 3.0.3 application built in Code::Blocks wxSmith running on Windows 7 on Ubuntu. I found that:
Re: Porting a wxWidgets Application to Ubuntu
SetValue() is the correct method.wxTextCtrl::SetLabel() worked in Windows 7 and does not in Ubuntu.
Please be more specific. Maybe it's related to different line endings?I cannot read from configuration file I was able to in Windows 7. All files in the project, including the configuration file, have Read/Write permissions for user, group, and everyone else.
Use the source, Luke!
Re: Porting a wxWidgets Application to Ubuntu
Hi,
Did you rebuild the library or installed them from the repository?
Which code do you use to read/write the configuration file? Does it give any kind of error? Are you trying to read them from the shared folder or the files are on the Ubuntu machine? Are you using wxConfig to operate them?
Thank you.
Did you rebuild the library or installed them from the repository?
Which code do you use to read/write the configuration file? Does it give any kind of error? Are you trying to read them from the shared folder or the files are on the Ubuntu machine? Are you using wxConfig to operate them?
Thank you.
Re: Porting a wxWidgets Application to Ubuntu
The wxWidgets library was compiled on my machine. I tried at first to use precompiled binaries but this did not work due to many compile errors. Compiling the wxWidgets library myself on my machine solved this.
The configuration file was created by my program on a Windows 7 machine. There was data in it I do not want to enter again. So I brought into the Ubuntu on the expectation my program could also read it there.
The config file was created using the wxFileConfig class. I examined this file in the gedit word processor and all was as should be. But gedit did not show me the line termination character(s).
The configuration file was created by my program on a Windows 7 machine. There was data in it I do not want to enter again. So I brought into the Ubuntu on the expectation my program could also read it there.
The config file was created using the wxFileConfig class. I examined this file in the gedit word processor and all was as should be. But gedit did not show me the line termination character(s).
Re: Porting a wxWidgets Application to Ubuntu
Hi,
In which directory did you put this configuration file?
How do you using the wxConfig class? Can you show some code?
Can you run gdb and see if the file is found on the system and if it can be read properly? If it was made on Windows it might be the line-ending...
Thank you.
In which directory did you put this configuration file?
How do you using the wxConfig class? Can you show some code?
Can you run gdb and see if the file is found on the system and if it can be read properly? If it was made on Windows it might be the line-ending...
Thank you.
Re: Porting a wxWidgets Application to Ubuntu
The project can be downloaded from:
http://www.mediafire.com/file/cmgdv01y0 ... u.zip/file
Please read the file "wxWidgets Forum Readme.txt" for answers to questions asked about it in this thread here.
Your help with this is much appreciated.
http://www.mediafire.com/file/cmgdv01y0 ... u.zip/file
Please read the file "wxWidgets Forum Readme.txt" for answers to questions asked about it in this thread here.
Your help with this is much appreciated.
Re: Porting a wxWidgets Application to Ubuntu
Have you tried if the line-endings are the problem? E.g. by just taking the non-working config file and changing the line endings in a text editor?
Use the source, Luke!
Re: Porting a wxWidgets Application to Ubuntu
After seeing your reply I executed the Linux command dos2unix on that configuration file. But now a new problem has made it impossible to see what difference that makes. The applicaion's window does not appear. There is no indication the applications has stopped, and the debugger keeps running until I stop it. A manifestation of this same problem may be that something is corrupting the WYSIWYG wxs file editor. At first things look normal. But when it is scrolled, and then scrolling stops, major parts of the WYSIWYG display disappear. This problem is severe enough that this editor cannot be used to edit it.
Re: Porting a wxWidgets Application to Ubuntu
Apparently it did change something.But now a new problem has made it impossible to see what difference that makes. The application's window does not appear.
But i'm afraid you'll have to learn how to debug under Linux. The issues are too vague as if anyone could solve this just by reading your description.
Use the source, Luke!
Re: Porting a wxWidgets Application to Ubuntu
The new problem was present before I ran dos2unix on that configuration file.
Re: Porting a wxWidgets Application to Ubuntu
Hi,
Install the gdb.
Run the program under gdb and see what is being read from the configuration file.
Thank you.
Install the gdb.
Run the program under gdb and see what is being read from the configuration file.
Thank you.