MessageLog.logSetHandlerFull

Like g_log_set_handler(), but takes a destroy notify for the user_data.

This has no effect if structured logging is enabled; see [Using Structured Logging][using-structured-logging].

struct MessageLog
static
uint
logSetHandlerFull

Parameters

logDomain string

the log domain, or NULL for the default "" application domain

logLevels GLogLevelFlags

the log levels to apply the log handler for. To handle fatal and recursive messages as well, combine the log levels with the G_LOG_FLAG_FATAL and G_LOG_FLAG_RECURSION bit flags.

logFunc GLogFunc

the log handler function

userData void*

data passed to the log handler

destroy GDestroyNotify

destroy notify for user_data, or NULL

Return Value

Type: uint

the id of the new handler

Meta

Since

2.46