- Code snippets 0.3:
* Added Edit snippet dialog
* Added macro functionality similar to editor's autocomplete
* The images are now correctly loaded when using the plugin from the user's plugin directory
Just little comments or maybe I should give better commit messages next time. The macro system similarity is that you can insert $(name-here) types of macros. Also, the snippet is run through MacroManager so you can use the predefined variables found in the Wiki too.
- Code snippets 0.3.1:
* Improved accessibility in Edit snippet dialog
* Added snippet tool tips; disabled by default in wxWidgets 2.6. Windows only (limitations in wxWidgets)
You might wonder why the tool tips are disabled on wxWidgets 2.6. There's actually comment in the OnItemGetToolTip which is informative about the issue:
// "My eyes! The goggles do nothing!"
Seriously speaking, the tool tips in wxWidgets 2.6 ignore line breaks and produce garbage to the text which will render the tool tip useless. wxWidgets 2.8 shows the tool tips correctly; only on Windows of course.
I actually had to create a Known Issues (http://wiki.codeblocks.org/index.php?title=Code_Snippets_plugin#Known_Issues) section to the Code snippet wiki page because the faults I found in the Edit snippet dialog / these updates, most of the being bugs in wxWidgets.
* goes to create minimal examples for bug reports *
this is the 03 nov thread : http://forums.codeblocks.org/index.php?topic=4368.0
@Yiannis, I think we have a patch for this at berlios, could you have a look at it. If it is the one I have in mind, well then GDB 5.x support will be gone [well we used to tell we don't have 5.x support, recently we did have, maybe it's time again to not have ;-) ]
edit : this is the patch : not sure if it's the same problem, but worth looking at I guess : [ Patch #1658 ] Corrects the "No source file named" behavior when debugging : https://developer.berlios.de/patch/index.php?func=detailpatch&patch_id=1658&group_id=5358
the introduction of
else
{
// for foreign files, we still should use a relative path
wxFileName f(filename);
f.MakeRelativeTo(prj->GetBasePath());
fname = f.GetFullPath();
}
cause the user who reported this to have the problem, but tiwag came up with another example where commenting out the above section doesn't help at all.
The mentioned patch does this in that particular area :
else
{
- // for foreign files, we still should use a relative path
+ // for foreign files, we should use an absolute path
wxFileName f(filename);
- f.MakeRelativeTo(prj->GetBasePath());
+ f.MakeAbsolute();
fname = f.GetFullPath();
+ fname.Replace(_T("\\"), _T("/"));
}
together with :
--- plugins/debuggergdb/gdb_driver.cpp (revision 3258)
+++ plugins/debuggergdb/gdb_driver.cpp (working copy)
@@ -22,7 +22,7 @@
static wxRegEx reThreadSwitch(_T("^\\[Switching to thread .*\\]#0[ \t]+(0x[A-z0-9]+) in (.*) from (.*)"));
static wxRegEx reThreadSwitch2(_T("^\\[Switching to thread .*\\]#0[ \t]+(0x[A-z0-9]+) in (.*) from (.*):([0-9]+)"));
#ifdef __WXMSW__
- static wxRegEx reBreak(_T("([A-z]:)([^:]+):([0-9]+):[0-9]+:[begmidl]+:(0x[0-9A-z]+)"));
+ static wxRegEx reBreak(_T("..([A-z]:)([^:]+):([0-9]+):[0-9]+:[begmidl]+:(0x[0-9A-z]+)"));
#else
static wxRegEx reBreak(_T("\032\032([^:]+):([0-9]+):[0-9]+:[begmidl]+:(0x[0-9A-z]+)"));
#endif
@@ -130,6 +130,7 @@
wxString cmd;
cmd << debugger;
cmd << _T(" -nx"); // don't run .gdbinit
+ cmd << _T(" -readnow "); // read symbol table immediately
cmd << _T(" -fullname "); // report full-path filenames when breaking
cmd << _T(" -quiet"); // don't display version on startup
cmd << _T(" -args ") << debuggee;
@@ -141,6 +142,7 @@
wxString cmd;
cmd << debugger;
cmd << _T(" -nx"); // don't run .gdbinit
+ cmd << _T(" -readnow "); // read symbol table immediately
cmd << _T(" -fullname "); // report full-path filenames when breaking
cmd << _T(" -quiet"); // don't display version on startup
cmd << _T(" -pid=") << wxString::Format(_T("%d"), pid);
@tiwag : if you have a spare moment could you check if your example works correct with the above mentioned patch ?