How to prevent Properties of EditInlineNew Objects from appearing under Category dropdowns ?

TLDR;

I have this:

image

but I want this:

image

Read down below for more context…


Hello,

I have an Array declared with Instanced Specifier:

UPROPERTY(BlueprintReadWrite, EditAnywhere, Instanced, Category = "Config")
TArray<UVisualisationShape*> ShapesToDraw;

…which is meant to store the references to the Objects declared with EditInlineNew Specifier, e.g.

UCLASS(Abstract, DefaultToInstanced, EditInlineNew, ClassGroup = "VisualisationShape",
	meta = (DisplayName = "Visualisation Shape"))
class TLOB_API UVisualisationShape : public UObject
{
	GENERATED_BODY()

public:

	UPROPERTY(EditAnywhere, BlueprintReadWrite)
	FTransform Offset;
	UPROPERTY(EditAnywhere, BlueprintReadWrite)
	FColor Color = FColor::Cyan;
	UPROPERTY(EditAnywhere, BlueprintReadWrite)
	float Thickness = 1.0f;
};

And this works quite well in the Editor.
These Objects appear in the following way when selected:

image

But there is a small caveat - Properties appear under the dropdowns.

Not a very big deal, but I don’t like it at all.
I wish that these would be listed without expanding any dropdowns.

Is there any way to remove these category dropdowns?
Perhaps, a Specifier for UPROPERTY/UCLASS?
So all the Object’s Properties would appear next to each other (see TLDR section above for image).

Thanks!


Edited and bumped as I’m still looking for answer…

Hi!

Have you tried UPROPERTY specifier ShowOnlyInnerProperties?

1 Like

Yes,

tried to use it for both, the array declaration:

UPROPERTY(BlueprintReadWrite, EditAnywhere, Instanced, Category = "Config", meta = (ShowOnlyInnerProperties))
TArray<UDebugVisualizationShape*> ShapesToDraw;

and for Object class declaration:

UCLASS(Abstract, DefaultToInstanced, EditInlineNew, ClassGroup = "DebugVisualizationShape",
	meta = (DisplayName = "Visualization Shape", ShowOnlyInnerProperties))
class DEBUGVISUALIZATION_API UDebugVisualizationShape : public UObject

and even for each sub-class of said class:

UCLASS(ClassGroup = "DebugVisualizationShape", meta = (ShowOnlyInnerProperties, DisplayName = "Arc"))
class DEBUGVISUALIZATION_API UVS_Arc : public UDebugVisualizationShape

Sadly, this still doesn’t work:

but thanks for trying to help!

UCLASS(CollapseCategories)

1 Like

Thanks! collapseCategories seems promising, will check it soon.

Much thanks @spereku!

UCLASS(CollapseCategories) works like a charm. Problem solved.

image

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.