Search Unity

  1. Unity 6 Preview is now available. To find out what's new, have a look at our Unity 6 Preview blog post.
    Dismiss Notice
  2. Unity is excited to announce that we will be collaborating with TheXPlace for a summer game jam from June 13 - June 19. Learn more.
    Dismiss Notice

Feedback Make EditorGUIUtility.GetHelpIcon public or offer a HelpBox that supports text, icon and tooltip

Discussion in 'Editor & General Support' started by Xarbrough, Apr 21, 2020.

  1. Xarbrough


    Dec 11, 2014
    The EditorGUILayout.HelpBox control is great for many use-cases. However, I would like to pass my own tooltip alongside the normal text and one of the built-in icons. Looking at the internal API I can see that HelpBox is using a LabelField with styling and an internal call to EditorGUIUtility.GetHelpIcon. I also often like to use these help icons in my custom editor code. Please make GetHelpIcon public so we can use these icons in custom editor tools and to implement a custom version of HelpBox that supports text, icon, and tooltip without having to use reflection. Alternatively, Unity could provide an overload to HelpBox that supports the tooltip alongside an icon, but I think GetHelpIcon is more flexible and has the same implications maintenance/support-wise I believe.

    Thanks for considering!
  2. StaggartCreations


    Feb 18, 2015
    Extended styling options for the helpbox would be rad, I use it extensively.

    Though, you can access any of the editor's native icons through EditorGUIUtility.IconContent. A list of available icons can be found here:
    InScatterbrain and Xarbrough like this.