[Geany] msg_win_add

Nick Treleaven nick.treleaven at xxxxx
Tue Sep 18 12:27:59 UTC 2007


On 17/09/07 22:56:35, Jeff Pohlmeyer wrote:
> [...]
> I would also like to be able to clear any existing messages, and
> activate the notebook tab. It looks like the easiest way would be
> to add a reference to the global struct MessageWindow into the
> struct GeanyData.  I can work up a patch if that sounds OK.
> ( I would call the field msg_win since we already have a msgwindow )

I think it might be best to avoid exposing the MessageWindow fields - 
would a single function to clear and focus a message window tab be 
sufficient?

> Also, I'm not sure what sort of housekeeping I need to do when I
> assign
> the build_info.dir string. I assume that if it's non-null to begin
> with, I would
> need to free the existing string, but then who is responsible to free
> the new
> string that I allocated?

Whoever sets the string. If you like you could use:

#include "utils.h"
...
setptr(build_info.dir, g_strdup(new_path_str));

Regards,
Nick



More information about the Users mailing list