libgitk logging routines
[libgitk core]


Defines

#define ANSI_COLOR_BLACK
 ansi escape sequence for color black

#define ANSI_COLOR_BLUE
 ansi escape sequence for color blue

#define ANSI_COLOR_BROWN
 ansi escape sequence for color brown

#define ANSI_COLOR_CYAN
 ansi escape sequence for color cyan

#define ANSI_COLOR_DARKGRAY
 ansi escape sequence for color dark-gray

#define ANSI_COLOR_GREEN
 ansi escape sequence for color green

#define ANSI_COLOR_LIGHTBLUE
 ansi escape sequence for color light-blue

#define ANSI_COLOR_LIGHTCYAN
 ansi escape sequence for color light-cyan

#define ANSI_COLOR_LIGHTGRAY
 ansi escape sequence for color light-gray

#define ANSI_COLOR_LIGHTGREEN
 ansi escape sequence for color light-green

#define ANSI_COLOR_LIGHTPURPLE
 ansi escape sequence for color light-purple

#define ANSI_COLOR_LIGHTRED
 ansi escape sequence for color light-red

#define ANSI_COLOR_PURPLE
 ansi escape sequence for color purple

#define ANSI_COLOR_RED
 ansi escape sequence for color red

#define ANSI_COLOR_WHITE
 ansi escape sequence for color white

#define ANSI_COLOR_YELLOW
 ansi escape sequence for color yellow

#define gitk_dump(str)
 unformated debug-log output

#define gitk_dump1(fmt, par1)
 unformated debug-log output with one parameter

#define gitk_dump2(fmt, par1, par2)
 unformated debug-log output with two parameters

#define gitk_err(str)
 formated error-log output

#define gitk_err1(fmt, par1)
 formated error-log output with one parameter

#define gitk_err2(fmt, par1, par2)
 formated error-log output with two parameters

#define gitk_err3(fmt, par1, par2, par3)
 formated error-log output with three parameters

#define gitk_err4(fmt, par1, par2, par3, par4)
 formated error-log output with four parameters

#define gitk_log(str)
 formated debug-log output

#define gitk_log1(fmt, par1)
 formated debug-log output with one parameter

#define gitk_log2(fmt, par1, par2)
 formated debug-log output with two parameters

#define gitk_log3(fmt, par1, par2, par3)
 formated debug-log output with three parameters

#define gitk_log4(fmt, par1, par2, par3, par4)
 formated debug-log output with four parameters

#define gitk_log_intro()
 log that function starts

#define gitk_log_outro()
 log that function ends


Functions

void gitk_dialog_dump (xmlDocPtr const doc)
 dump contents of supplied document to STDOUT

void gitk_log_handler (const gchar *const log_domain, const GLogLevelFlags log_level, const gchar *const message, gpointer const user_data)
 log handler for gitk. Use g_log_set_handler(G_LOG_DOMAIN,G_LOG_LEVEL_DEBUG|G_LOG_LEVEL_MESSAGE|G_LOG_LEVEL_WARNING|G_LOG_LEVEL_ERROR, gitk_log_handler, NULL);

void gitk_print_handler (const gchar *const message)
 print handler for gitk, use g_set_printerr_handler(gitk_print_handler);


Detailed Description

This module provides several facillilies for logging.

Define Documentation

#define ANSI_COLOR_BLACK
 

ansi escape sequence for color black

Definition at line 364 of file gitk.h.

#define ANSI_COLOR_BLUE
 

ansi escape sequence for color blue

Definition at line 380 of file gitk.h.

#define ANSI_COLOR_BROWN
 

ansi escape sequence for color brown

Definition at line 376 of file gitk.h.

#define ANSI_COLOR_CYAN
 

ansi escape sequence for color cyan

Definition at line 388 of file gitk.h.

#define ANSI_COLOR_DARKGRAY
 

ansi escape sequence for color dark-gray

Definition at line 396 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define ANSI_COLOR_GREEN
 

ansi escape sequence for color green

Definition at line 372 of file gitk.h.

#define ANSI_COLOR_LIGHTBLUE
 

ansi escape sequence for color light-blue

Definition at line 412 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define ANSI_COLOR_LIGHTCYAN
 

ansi escape sequence for color light-cyan

Definition at line 420 of file gitk.h.

#define ANSI_COLOR_LIGHTGRAY
 

ansi escape sequence for color light-gray

Definition at line 392 of file gitk.h.

Referenced by gitk_dialog_dump(), and gitk_dialog_dump_walker().

#define ANSI_COLOR_LIGHTGREEN
 

ansi escape sequence for color light-green

Definition at line 404 of file gitk.h.

#define ANSI_COLOR_LIGHTPURPLE
 

ansi escape sequence for color light-purple

Definition at line 416 of file gitk.h.

#define ANSI_COLOR_LIGHTRED
 

ansi escape sequence for color light-red

Definition at line 400 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define ANSI_COLOR_PURPLE
 

ansi escape sequence for color purple

Definition at line 384 of file gitk.h.

#define ANSI_COLOR_RED
 

ansi escape sequence for color red

Definition at line 368 of file gitk.h.

#define ANSI_COLOR_WHITE
 

ansi escape sequence for color white

Definition at line 424 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define ANSI_COLOR_YELLOW
 

ansi escape sequence for color yellow

Definition at line 408 of file gitk.h.

#define gitk_dump str   ) 
 

unformated debug-log output

Definition at line 449 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define gitk_dump1 fmt,
par1   ) 
 

unformated debug-log output with one parameter

Definition at line 453 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define gitk_dump2 fmt,
par1,
par2   ) 
 

unformated debug-log output with two parameters

Definition at line 457 of file gitk.h.

Referenced by gitk_dialog_dump_walker().

#define gitk_err str   ) 
 

formated error-log output

Definition at line 481 of file gitk.h.

Referenced by gitk__cxpath_get_node(), gitk__cxpath_get_object(), gitk__cxpath_get_string(), gitk_dialog_new_from_memory(), gitk_dialog_new_from_string(), gitk_dialog_set_content(), gitk_dialog_trans_expand(), gitk_dialog_trans_i18n(), gitk_init(), gitk_init_common_xpath_expressions(), gitk_init_xsl(), gitk_init_xsl_domain(), gitk_init_xsl_style(), gitkr_dialog_generate_dialog_widgets(), gitkr_dialog_generate_layout(), gitkr_dialog_generate_sequential_layout(), gitkr_dialog_generate_sequential_layout_build_page(), gitkr_dialog_output_layout(), gitkr_render(), gitkr_widget_optionchoice_get_choices(), and gitkr_widget_optionchoice_get_ids().

#define gitk_err1 fmt,
par1   ) 
 

formated error-log output with one parameter

Definition at line 485 of file gitk.h.

Referenced by gitk__xpath_get_node(), gitk__xpath_get_object(), gitk__xpath_get_string(), gitk_dialog_new_from_file(), gitk_dialog_trans_domain(), gitk_init_xsl_domain(), gitk_init_xsl_style(), gitkr_dialog_generate_dialog_widgets(), and gitkr_dialog_generate_layout().

#define gitk_err2 fmt,
par1,
par2   ) 
 

formated error-log output with two parameters

Definition at line 489 of file gitk.h.

Referenced by gitk_dialog_trans_style(), gitk_renderer_activate(), and gitk_xpath_type_filter().

#define gitk_err3 fmt,
par1,
par2,
par3   ) 
 

formated error-log output with three parameters

Definition at line 493 of file gitk.h.

#define gitk_err4 fmt,
par1,
par2,
par3,
par4   ) 
 

formated error-log output with four parameters

Definition at line 497 of file gitk.h.

#define gitk_log str   ) 
 

formated debug-log output

Definition at line 461 of file gitk.h.

Referenced by capi_sound_output(), capi_text_output(), gitk_context_activate(), gitk_context_count_active(), gitk_context_get_highest_used_priority(), gitk_dialog_dump(), gitk_dialog_get_dst(), gitk_dialog_hide(), gitk_dialog_new(), gitk_dialog_set_content(), gitk_dialog_show(), gitk_dialog_trans(), gitk_dialog_trans_expand(), gitk_dialog_trans_i18n_walker(), gitk_dialog_trans_initial(), gitk_dialog_validate(), gitk_event_loop_exchange(), gitk_event_loop_start(), gitk_init(), gitk_init_process_commandline(), gitk_libxmlxslt_error_func(), gitk_relayout(), gitk_renderer_activate(), gitk_renderer_init(), gitk_server_thread(), gitk_template_message_with_title(), gitkr_dialog_free_layout(), gitkr_dialog_generate_dialog_widgets(), gitkr_dialog_generate_hierarchical_layout(), gitkr_dialog_generate_layout(), gitkr_dialog_generate_layout_walker(), gitkr_dialog_generate_sequential_layout(), gitkr_dialog_generate_sequential_layout_build_page(), gitkr_dialog_new_layout(), gitkr_dialog_output_layout(), gitkr_done(), gitkr_event_loop_start(), gitkr_event_loop_unescape_key(), gitkr_init(), gitkr_init_process_commandline(), gitkr_render(), gitkr_select_context(), gitkr_set_context(), gitkr_widget_characterinput_alphabetic_output(), gitkr_widget_characterinput_handle(), gitkr_widget_optionchoice_get_choices(), gitkr_widget_optionchoice_output(), gitkr_widget_optionchoice_value_output(), global_on_close(), global_on_dialog_hide(), global_on_dialog_show(), index_html(), main(), main_show(), parse_commandline_arg(), sighandler_editable_widget_on_changed(), sighandler_on_sighup(), sighandler_on_sigint(), sighandler_on_sigwinch(), sighandler_option_widget_on_changed(), sighandler_widget_on_clicked(), sighandler_window_on_close(), sighandler_window_on_destroy(), test_setup(), and test_teardown().

#define gitk_log1 fmt,
par1   ) 
 

formated debug-log output with one parameter

Definition at line 465 of file gitk.h.

Referenced by capi_dtmf_input_arrow(), capi_exception(), color_name_to_code(), dialog_on_clicked(), gitk__cxpath_get_node(), gitk__dialog_set_title(), gitk_context_activate(), gitk_context_get_highest_used_priority(), gitk_dialog_new(), gitk_dialog_process_event(), gitk_dialog_set_content(), gitk_dialog_show(), gitk_dialog_trans_domain(), gitk_event_loop_exchange(), gitk_init(), gitk_init_process_commandline(), gitk_init_xsl_domain(), gitk_init_xsl_style(), gitk_renderer_activate(), gitk_renderer_init(), gitk_sensor_locale(), gitk_server_thread(), gitkr_dialog_free_layout(), gitkr_dialog_generate_dialog_widgets(), gitkr_dialog_generate_layout(), gitkr_dialog_generate_layout_walker(), gitkr_dialog_generate_sequential_layout(), gitkr_dialog_generate_sequential_layout_build_page(), gitkr_dialog_generate_sequential_layout_count_pages(), gitkr_dialog_output_layout(), gitkr_event_loop_end(), gitkr_event_loop_getkey(), gitkr_event_loop_start(), gitkr_init(), gitkr_init_process_commandline(), gitkr_render(), gitkr_widget_characterinput_value_output(), gitkr_widget_get_value(), gitkr_widget_optionchoice_handle(), gitkr_widget_optionchoice_new(), gitkr_widget_optionchoice_output(), handle_dialog_ctrl_widgets(), handle_dialog_main_widgets(), info_show(), main(), main_on_clicked(), main_show(), parse_commandline_arg(), sighandler_editable_widget_on_changed(), sighandler_option_widget_on_changed(), sighandler_widget_on_clicked(), and sighandler_window_on_destroy().

#define gitk_log2 fmt,
par1,
par2   ) 
 

formated debug-log output with two parameters

Definition at line 469 of file gitk.h.

Referenced by capi_sound_output(), gitk__dialog_attach_callback(), gitk__widget_get_value(), gitk_dialog_new_from_parser_context(), gitk_dialog_trans_style(), gitk_dialog_validate(), gitk_renderer_activate(), gitk_set_error(), gitkr_dialog_free_layout(), gitkr_dialog_generate_layout(), gitkr_dialog_generate_layout_walker(), gitkr_dialog_generate_sequential_layout_build_page(), gitkr_dialog_generate_sequential_layout_count_pages(), gitkr_dialog_output_layout(), gitkr_init(), gitkr_widget_optionchoice_get_choices(), handle_dialog_main_widgets(), index_html(), main(), main_on_changed(), parse_commandline_arg(), and sighandler_on_sigwinch().

#define gitk_log3 fmt,
par1,
par2,
par3   ) 
 

formated debug-log output with three parameters

Definition at line 473 of file gitk.h.

Referenced by gitk__widget_get_value(), gitk_init(), gitkr_dialog_generate_dialog_widgets(), gitkr_event_loop_unescape_key(), gitkr_widget_characterinput_handle(), handle_dialog_main_widgets(), index_html(), and main().

#define gitk_log4 fmt,
par1,
par2,
par3,
par4   ) 
 

formated debug-log output with four parameters

Definition at line 477 of file gitk.h.

 
#define gitk_log_intro  ) 
 

log that function starts

Definition at line 501 of file gitk.h.

Referenced by gitk_dialog_trans(), gitk_dialog_trans_initial(), gitk_done(), gitk_event_loop_end(), gitk_event_loop_start(), gitk_init(), gitkr_dialog_free_layout(), gitkr_dialog_generate_sequential_layout_count_pages(), gitkr_dialog_hide(), gitkr_dialog_output_layout(), gitkr_dialog_show(), gitkr_done(), gitkr_event_loop_end(), gitkr_event_loop_getkey(), gitkr_event_loop_restart(), gitkr_event_loop_start(), gitkr_render(), gitkr_select_context(), gitkr_widget_label_new(), handle_dialog_ctrl_widgets(), handle_dialog_main_widgets(), sighandler_editable_widget_on_changed(), sighandler_option_widget_on_changed(), sighandler_widget_on_clicked(), sighandler_window_on_close(), and sighandler_window_on_destroy().

 
#define gitk_log_outro  ) 
 

log that function ends

Definition at line 505 of file gitk.h.

Referenced by gitk_dialog_trans(), gitk_dialog_trans_initial(), gitk_done(), gitk_event_loop_end(), gitk_event_loop_start(), gitk_init(), gitkr_dialog_free_layout(), gitkr_dialog_generate_sequential_layout_count_pages(), gitkr_dialog_hide(), gitkr_dialog_output_layout(), gitkr_dialog_show(), gitkr_done(), gitkr_event_loop_end(), gitkr_event_loop_getkey(), gitkr_event_loop_start(), gitkr_render(), gitkr_select_context(), handle_dialog_ctrl_widgets(), handle_dialog_main_widgets(), and sighandler_window_on_destroy().


Function Documentation

void gitk_dialog_dump xmlDocPtr const  doc  ) 
 

dump contents of supplied document to STDOUT

Parameters:
doc document to dump

check_mode &&

Definition at line 90 of file gitktools.c.

References ANSI_COLOR_LIGHTGRAY, gitk_dialog_dump_walker(), gitk_log, and print_ansi.

Referenced by gitk_dialog_get_dst(), and gitk_dialog_new().

Here is the call graph for this function:

void gitk_log_handler const gchar *const  log_domain,
const GLogLevelFlags  log_level,
const gchar *const  message,
gpointer const  user_data
 

log handler for gitk. Use g_log_set_handler(G_LOG_DOMAIN,G_LOG_LEVEL_DEBUG|G_LOG_LEVEL_MESSAGE|G_LOG_LEVEL_WARNING|G_LOG_LEVEL_ERROR, gitk_log_handler, NULL);

Todo:
filter on G_LOG_DOMAIN {gitk-core,gitk-render-{text,gtk,...},gitk-examples,gtk,glib,...}

Definition at line 69 of file gitkerrors.c.

References gitk_print_handler().

Referenced by gitk_init(), gitkr_init(), and main().

Here is the call graph for this function:

void gitk_print_handler const gchar *const  message  ) 
 

print handler for gitk, use g_set_printerr_handler(gitk_print_handler);

Todo:
add option to set logfile (per configure ?, per command line (will miss initial messages))

Definition at line 79 of file gitkerrors.c.

References log_file_name.

Referenced by gitk_init(), and gitk_log_handler().


Generated on Thu Oct 28 11:04:26 2004 for gitk by doxygen 1.3.6