Is it possible to make EditorGuiLayout.ObjectField(Texture2D) look like ObjectField(String,Texture2D)?

I’m currently creating a horizontal scrollbar in which all the layers of my terrain should be listed. Most importantly, their material should be easily recognizable by their main texture thumbnail.
So far I’ve been using EditorGuiLayout.ObjectField(String,Texture2D), which gives me nice 80x80 thumbnails. Now I want to remove the label, because it’s really just in the way in a horizontal scrollbar. But when I put in an empty label, I still have empty space to the left of my texture field, so that’s no good. Now I went and used the EditorGuiLayout.ObjectField(Texture2D) and I don’t get any empty spaces anymore, but now my textures no longer have a big thumbnail,but a very small field, like any other object would have.
Is there a way to just draw the Texture without label but as a “big” field?

This is an old post, but I stumbled on the same problem and found the solution. So I wanted to share it.

Adding “GUILayout.Width” and “GUILayout.Height” in the options of the Objectfield without label gives a big thumbnail

Did you try using?


Docs Page: Unity - Scripting API: EditorGUIUtility.labelWidth

Try setting it to something low but not 0 as 0 resets the size to default.