If you use both Category hierarchy and CallInEditor in UFUNCTION, it will result in an unintended sequence as shown below.
[Image Removed]
And, the following code can solve this issue
void FDetailLayoutBuilderImpl::GenerateDetailLayout()
{
...
SubCategoryMap.Empty();
for (FCategoryMap::TIterator It(DefaultCategoryMap); It; ++It)
{
// Remove all subcategories
TSharedPtr<FDetailCategoryImpl> DetailCategory = It.Value();
// Note: Sub-categories are added later
int32 Index = INDEX_NONE;
if (DetailCategory->GetCategoryName().ToString().FindChar(FPropertyNodeConstants::CategoryDelimiterChar, Index))
{
SubCategoryMap.Add(It.Key(), DetailCategory);
It.RemoveCurrent();
}
}
#if 1 //workaround begins
for (FCategoryMap::TIterator It(CustomCategoryMap); It; ++It)
{
// Remove all subcategories
TSharedPtr<FDetailCategoryImpl> DetailCategory = It.Value();
// Note: Sub-categories are added later
int32 Index = INDEX_NONE;
if (DetailCategory->GetCategoryName().ToString().FindChar(FPropertyNodeConstants::CategoryDelimiterChar, Index))
{
SubCategoryMap.Add(It.Key(), DetailCategory);
It.RemoveCurrent();
}
}
#endif //workaround ends
// Build default categories
while (DefaultCategoryMap.Num() > 0)
...
1. Add function using subcategory
UFUNCTION(CallInEditor, Category = "Map|Capture")
void GenerateSnapshot();
2. compile
3. Check Detail panel of Actor
result : does not consider subcategory
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-164419 in the post.
| 6 |
| Component | UE - Framework - Blueprint Editor |
|---|---|
| Affects Versions | 5.0 |
| Created | Sep 20, 2022 |
|---|---|
| Updated | Oct 28, 2025 |