CDbg Build

Hello everyone! A new CDbg build is here.
You can download build using this link. All instructions you can find inside the zip file.
Simon Anciaux,
I'll take a look when I have some time.
Ronald Fenelus,
This is starting to look pretty good!

It'd be nice to start really using if the project flow was nicer; a few things I can think of offhand:
- not forcing command line use to launch an exe
- being able to set a working directory
- thread selection
- locals

The perf issue when there are a lot of watch variables (like expanding a large array) is pretty important to fix as well as it makes the program entirely unresponsive. I'm sure you've thought of those things but implementing them would make testing the debugger much less painful.

I also found a bug where the debugger crashes after a bit while holding the resume key with a breakpoint repeatedly getting hit. I think it has to do with the watch window as it only seems to happen when a variable is being watched.
Nikita Smith,
Thank you Alephant for the feedback!
Simon Anciaux,
I tried using it to debug a real bug, but there are some missing features that I needed in the watch window:
- being able to type an expression that cast a value/pointer
---- e.g. ( Vec2* ) bytes
- pointer arithmetic
---- e.g. ( Vec2* ) ( ( u32* ) bytes + 1 )
- specifying the number of elements to display (pointer or array)
---- e.g. vec2Array, 15
- I'm using an azerty keyboard layout (fr_be), dead keys don't seem to work, I can't input a '[' ( Alt Gr + '^' ) or ']' ( Alt Gr + '$' ). If I switch the layout to qwerty they work.

If I can suggest something: if you pass WM_KEYUP, WM_KEYDOWN, WM_SYSKEYUP, WM_SYSKEYDOWN messages to TranslateMessage after you handle them (so you can still handle them in any way you want), windows will generate a WM_CHAR message that will contain the character typed by the user and you don't have to worry about the keyboard layout for text input. The character is encoded in UTF-16 so you may need to convert it to UTF-8 or codepoint which is really easy to do, for instance the first 127 character in UTF-16 and UTF-8 are the same in ASCII.

Thank you for the customisation layer. A few remarks:
- you should add command to copy the dll at the right place when the build is successful;
- the default dll has a font problem: "Failed to load the font specified in the module. Debugger will use its internal font". I got the same error with the default font in compiled dll. This path for the font fixed it for me (I'm on windows 7)
file_viewer_config.font = "C:\\Windows\\Fonts\\consola.ttf"; // Full path, no 's' at the end of consola.

(after typing this I realized that there was a font folder with consolas.ttf and the problem is probably because I'm launching cdbg using a batch file from another directory).
- You can use GetKeyNameText to get a string of the name of a key (in the language of the keyboard layout) to display the keys in the menus.
- This one you may not need to fix, I'm using VS2012 and it doesn't support C99, so I got a few errors:
---- stdbool.h doesn't exists in C89;
---- bool, true, false are not defined;
---- There are some variable declarations in the middle of scopes or inside the for loop parenthesis.

Nikita Smith,
mrmixer, thank you for your feedback. I will try to fix everything you mentioned til next release.
Hey this CDbg is looking really nice! When I used it, there were a few things that made me uncomfortable though. The fact that pdb file gets locked up while debugging means I can't keep the debugger open while recompiling my code. One more thing is that when trying to debug a x86 binary, CDbg does not show an error message, which used to. But overall this is looking really amazing! I honestly can't wait to replace VS with your debugger :)
Now I thought about it, it's actually not that big of a deal since I can enforce a different PDB name every time, like how it was done in handmade hero. I guess it isn't a mandatory feature then, I take it back :P
Nikita Smith,
Thanks for trying it out! I already fixed bug with x86 executable and pdb locking.