Function Macro

GObjectDEFINE_FINAL_TYPE_WITH_CODE

Declaration

#define G_DEFINE_FINAL_TYPE_WITH_CODE (
  TN,
  t_n,
  T_P,
  _C_
)

Description

A convenience macro for type implementations.

Similar to G_DEFINE_TYPE_WITH_CODE(), but defines a final type and allows you to insert custom code into the *_get_type() function, e.g. interface implementations via G_IMPLEMENT_INTERFACE().

See G_DEFINE_TYPE_EXTENDED() for an example.

Available since:2.70

Parameters

TN none
 

The name of the new type, in Camel case.

t_n none
 

The name of the new type, in lower case, with words separated by _ (snake case)

T_P none
 

The GType of the parent type.

_C_ none
 

Custom code that gets inserted in the type_name_get_type() function.