gitkinit.c File Reference

libgitk init routine More...

#include "gitkincludes.h"

Include dependency graph for gitkinit.c:

Include dependency graph

Go to the source code of this file.

Defines

#define GITK_INIT_C
#define GITK_LIB_C
 file is part of the gitkcore library.


Functions

void gitk_init (guint *const argc, gchar ***const argv, gchar *const _client_package_name, gchar *const _client_locale_dir)
 Filters gitk-related options from commandline options, setup initial data for the application using the lib and loads the renderer.

gboolean gitk_init_common_xpath_expressions (void)
 Tries to prepare (compile) common xpath expressions.

gboolean gitk_init_process_commandline (guint *const argc, gchar ***const argv)
 Checks if there have been passed some parameters for libgitk or libgitk-renderers and process them.

gboolean gitk_init_xml (void)
 Initializes xml resources such as the parser and xpath expressions.

gboolean gitk_init_xsl (void)
 Initializes xsl resources such as stylesheets and extension modules/functions.

gboolean gitk_init_xsl_domain (void)
 Loads the stylesheet for domain transformation.

gboolean gitk_init_xsl_style (void)
 Loads the stylesheet for renderer specific style application.


Detailed Description

libgitk init routine

Id
gitkinit.c,v 1.76 2004/09/07 17:46:41 ensonic Exp

Author:
Stefan Kost <ensonic@users.sf.net>
Date:
Fri Jun 29 15:19:01 2001

Definition in file gitkinit.c.


Define Documentation

#define GITK_LIB_C
 

file is part of the gitkcore library.

Definition at line 27 of file gitkinit.c.


Function Documentation

gboolean gitk_init_common_xpath_expressions void   )  [static]
 

Tries to prepare (compile) common xpath expressions.

Definition at line 237 of file gitkinit.c.

References gitk_err, GITK_NS_PREFIX, xpath_get_dialog_modality, xpath_get_dialog_name, and xpath_get_label.

Referenced by gitk_init().

gboolean gitk_init_process_commandline guint *const  argc,
gchar ***const  argv
[static]
 

Checks if there have been passed some parameters for libgitk or libgitk-renderers and process them.

Options for renderers are currently:

Todo:
list available renderers and available styles here? Or should we use another switch for it.

Definition at line 160 of file gitkinit.c.

References _, cleanup_commandline_args(), gitk_log, gitk_log1, gitk_puts(), gitk_renderer_name, gitk_server_port, gitk_style_name, and parse_commandline_arg().

Referenced by gitk_init().

Here is the call graph for this function:

gboolean gitk_init_xml void   )  [static]
 

Initializes xml resources such as the parser and xpath expressions.

Definition at line 216 of file gitkinit.c.

References gitk_libxmlxslt_error_func(), and xmlLoadExtDtdDefaultValue.

Referenced by gitk_init().

Here is the call graph for this function:

gboolean gitk_init_xsl void   )  [static]
 

Initializes xsl resources such as stylesheets and extension modules/functions.

Todo:
generate a stylesheet containing all message-ids of the client-catalog (how to get them ?) -- v1) gettext/intl/dcigettext.c gettext/intl/gettextP.h struct loaded_l10nfile *domain_file; struct loaded_domain *damain_data; if((domain_file = _nl_find_domain (dirname, single_locale, xdomainname, binding)!=NULL) { domain_data = (struct loaded_domain *) domain_file->data; !! now see the second half of : dcigettext.c/_nl_find_msg() } -- v2) compile with -I link with -L read_mo.o message.o
#include "message.h" #include "read-mo.h"

message_list_ty *mlp=message_list_alloc(FALSE); size_t j; const message_ty *mp; const char *msgstr = mp->msgstr; size_t msgstr_len = mp->msgstr_len; const char *p;

read_mo_file (mlp, fn); for (j = 0; j < mlp->nitems; j++) mp=mlp->item[j]; print("[s]->,mp->msgid); // Process each NUL delimited substring separately. for (p = msgstr; p < msgstr + msgstr_len; ) { size_t length = strlen (p); print(" [s],p); p += length + 1; } } message_list_free (mlp); -- v3) use own xslt extension function gettext() that has been registered above

Definition at line 259 of file gitkinit.c.

References gitk_err, gitk_init_xsl_domain(), gitk_init_xsl_style(), gitk_libxmlxslt_error_func(), gitk_renderer_name, I18N_NS_URL, xsl_expand, xsl_i18n, and XSL_PATH.

Referenced by gitk_init().

Here is the call graph for this function:

gboolean gitk_init_xsl_domain void   ) 
 

Loads the stylesheet for domain transformation.

Definition at line 350 of file gitkinit.c.

References gitk_err, gitk_err1, gitk_log1, gitk_renderer_name, xsl_domain, and XSL_ROOT_PATH.

Referenced by gitk_event_loop_exchange(), and gitk_init_xsl().

gboolean gitk_init_xsl_style void   ) 
 

Loads the stylesheet for renderer specific style application.

Definition at line 375 of file gitkinit.c.

References gitk_err, gitk_err1, gitk_log1, gitk_renderer_name, gitk_style_name, XSL_ROOT_PATH, and xsl_style.

Referenced by gitk_event_loop_exchange(), gitk_init_xsl(), and index_html().


Generated on Thu Oct 28 10:59:36 2004 for gitk by doxygen 1.3.6