dup_unique_display_name


Description:

[ Version ( since = "3.8" ) ]
public string dup_unique_display_name (Source source, string? extension_name)

Compares source's display_name against other sources having an SourceExtension named extension_name, if given, or else against all other sources in the this.

If sources's display_name is unique among these other sources, the function will return the display_name verbatim. Otherwise the function will construct a string that includes the sources's own display_name as well as those of its ancestors.

The function's return value is intended to be used in messages shown to the user to help clarify which source is being referred to. It assumes source's display_name is at least unique among its siblings.

Free the returned string with g_free when finished with it.

Parameters:

this

an SourceRegistry

source

an Source

extension_name

an extension name, or null

Returns:

a unique display name for source