User forums > Using Code::Blocks
Incremental Search
killerbot:
no luck :fresh checkout from svn repo
--- Quote --- g++ -DHAVE_CONFIG_H -I. -I. -I../../../../src/include -I/usr/lib64/wx/include/gtk2-unicode-release-2.8 -I/usr/include/wx-2.8 -D_FILE_OFFSET_BITS=64 -D_LARGE_FILES -D__WXGTK__ -pthread -I../../../../src/include -I../../../../src/include/wxscintilla/include -Ulinux -Uunix -O2 -ffast-math -g -O2 -DCB_PRECOMP -Winvalid-pch -fPIC -DPIC -fexceptions -MT IncrementalSearch.lo -MD -MP -MF .deps/IncrementalSearch.Tpo -c IncrementalSearch.cpp -fPIC -DPIC -o .libs/IncrementalSearch.o
IncrementalSearch.cpp: In member function 'virtual void IncrementalSearch::BuildMenu(wxMenuBar*)':
IncrementalSearch.cpp:127: error: 'class wxMenuItem' has no member named 'GetLabelText'
IncrementalSearch.cpp:127: error: 'class wxMenuItem' has no member named 'GetItemLabelText'
make[4]: *** [IncrementalSearch.lo] Error 1
make[4]: Leaving directory `/home/killerbot/Documents/CodeBlocksDev/trunk/src/plugins/contrib/IncrementalSearch'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/killerbot/Documents/CodeBlocksDev/trunk/src/plugins/contrib'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/killerbot/Documents/CodeBlocksDev/trunk/src/plugins'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/killerbot/Documents/CodeBlocksDev/trunk/src'
make: *** [all-recursive] Error 1
--- End quote ---
g++ (GCC) 4.1.2
wx : 2.8.4
Jenna:
--- Quote from: killerbot on October 11, 2008, 04:25:37 pm ---wx : 2.8.4
--- End quote ---
That's the problem "GetLabelText" and "GetItemLabelText" are in wxWidgets since 2.8.5.
I can add a version-guard and use the older functions if wxGtk is too old.
EDIT:
That means you have a more recent version on 32-bit linux, right?
EDIT2:
It would be nice if you could test the following code instead the original one:
--- Code: ---#if wxCHECK_VERSION(2,8,5)
if (items[i]->GetLabelText(items[i]->GetItemLabelText()) == _("Find previous"))
#else
if (items[i]->GetLabelFromText(items[i]->GetLabel()) == _("Find previous"))
#endif
--- End code ---
I can't test it, because I do not have wxWidgets 2.8.4 anymore.
I it works I will commit it.
rhf:
--- Quote from: jens on October 11, 2008, 01:00:21 pm ---Are the images inside "IncrementalSearch.zip" (it should be in "share/CodeBlocks").
The images are in the subfolder "images" and "images/16x16" inside the zip-file.
--- End quote ---
No, the images are not there.
--- Quote from: jens on October 11, 2008, 01:00:21 pm ---Do you have an image in the "Search -> Incremental Search" MenuItem ? It is in the same zip-file.
--- End quote ---
No. The icon does not show up in the Menu either.
--- Quote from: jens on October 11, 2008, 01:00:21 pm ---Have you tried to remove the zip from "src/devel/share/CodeBlocks" and "src/output/share/CodeBlocks" before building ?
--- End quote ---
Well I use the standard update.bat file obtained via SVN. The images appear to be unzipped in the two dirs
C:\CodeBlocks_SVN\src\plugins\contrib\IncrementalSearch\images and
C:\CodeBlocks_SVN\src\plugins\contrib\IncrementalSearch\images\16x16,
but apparently they are not getting copied to the appropriate devel\share\CodeBlocks\... and output\share\CodeBlocks\... sub-directories.
The update.bat file in C:\CodeBlocks_SVN\src\plugins\contrib\IncrementalSearch does copy two .png files to the \share\CodeBlocks\settings directories. I don't know if the other image .png files are copied somewhere else.
Biplab:
--- Quote from: rhf on October 11, 2008, 05:08:31 pm ---
--- Quote from: jens on October 11, 2008, 01:00:21 pm ---Are the images inside "IncrementalSearch.zip" (it should be in "share/CodeBlocks").
The images are in the subfolder "images" and "images/16x16" inside the zip-file.
--- End quote ---
No, the images are not there.
--- End quote ---
Compile IncrementalSearch with the attached project file. I suspect recursive addition of image file is not working here (this was affecting Linux builds, too). :)
[attachment deleted by admin]
killerbot:
--- Quote from: jens on October 11, 2008, 04:35:16 pm ---
--- Quote from: killerbot on October 11, 2008, 04:25:37 pm ---wx : 2.8.4
--- End quote ---
That's the problem "GetLabelText" and "GetItemLabelText" are in wxWidgets since 2.8.5.
I can add a version-guard and use the older functions if wxGtk is too old.
EDIT:
That means you have a more recent version on 32-bit linux, right?
EDIT2:
It would be nice if you could test the following code instead the original one:
--- Code: ---#if wxCHECK_VERSION(2,8,5)
if (items[i]->GetLabelText(items[i]->GetItemLabelText()) == _("Find previous"))
#else
if (items[i]->GetLabelFromText(items[i]->GetLabel()) == _("Find previous"))
#endif
--- End code ---
I can't test it, because I do not have wxWidgets 2.8.4 anymore.
I it works I will commit it.
--- End quote ---
I can test it either, since I have upgraded my wx to 2.8.9 on my 64-bit linux box. And now it builds correctly :-)
Navigation
[0] Message Index
[#] Next page
[*] Previous page
Go to full version