@@ -128,42 +128,46 @@ void CesiumFeaturesMetadataViewer::SyncAndRebuildUI() {
128128 [SNew (SHeader)
129129 .Content ()[SNew (STextBlock)
130130 .TextStyle (FCesiumEditorModule::GetStyle (), " Heading" )
131- .Text (FText::FromString (TEXT (" glTF Metadata " )))
131+ .Text (FText::FromString (TEXT (" glTF Features " )))
132132 .Margin (FMargin (0 .f , 10 .f ))]];
133133
134- if (!this ->_metadataSources .IsEmpty ()) {
135- TSharedRef<SScrollBox> pGltfContent = SNew (SScrollBox);
136- for (const PropertySourceView& source : this ->_metadataSources ) {
137- this ->createGltfPropertySourceDropdown (pGltfContent, source );
134+ if (!this ->_featureIdSets .IsEmpty ()) {
135+ TSharedRef<SScrollBox> pGltfFeatures = SNew (SScrollBox);
136+ for (const FeatureIdSetView& featureIdSet : this ->_featureIdSets ) {
137+ this ->createGltfFeatureIdSetDropdown (pGltfFeatures, featureIdSet );
138138 }
139- pContent->AddSlot ().MaxHeight (400 .0f ).AutoHeight ()[pGltfContent ];
139+ pContent->AddSlot ().MaxHeight (400 .0f ).AutoHeight ()[pGltfFeatures ];
140140 } else {
141141 pContent->AddSlot ().AutoHeight ()
142- [SNew (STextBlock)
143- .AutoWrapText (true )
144- .Text (FText::FromString (TEXT (
145- " This tileset does not contain any glTF metadata in its current view." )))];
142+ [SNew (SHorizontalBox) + SHorizontalBox::Slot ().FillWidth (0 .05f ) +
143+ SHorizontalBox::Slot ()
144+ [SNew (STextBlock)
145+ .AutoWrapText (true )
146+ .Text (FText::FromString (TEXT (
147+ " This tileset does not contain any glTF features in its current view." )))]];
146148 }
147149
148150 pContent->AddSlot ().AutoHeight ()
149151 [SNew (SHeader)
150152 .Content ()[SNew (STextBlock)
151153 .TextStyle (FCesiumEditorModule::GetStyle (), " Heading" )
152- .Text (FText::FromString (TEXT (" glTF Features " )))
154+ .Text (FText::FromString (TEXT (" glTF Metadata " )))
153155 .Margin (FMargin (0 .f , 10 .f ))]];
154156
155- if (!this ->_featureIdSets .IsEmpty ()) {
156- TSharedRef<SScrollBox> pGltfFeatures = SNew (SScrollBox);
157- for (const FeatureIdSetView& featureIdSet : this ->_featureIdSets ) {
158- this ->createGltfFeatureIdSetDropdown (pGltfFeatures, featureIdSet );
157+ if (!this ->_metadataSources .IsEmpty ()) {
158+ TSharedRef<SScrollBox> pGltfContent = SNew (SScrollBox);
159+ for (const PropertySourceView& source : this ->_metadataSources ) {
160+ this ->createGltfPropertySourceDropdown (pGltfContent, source );
159161 }
160- pContent->AddSlot ().MaxHeight (400 .0f ).AutoHeight ()[pGltfFeatures ];
162+ pContent->AddSlot ().MaxHeight (400 .0f ).AutoHeight ()[pGltfContent ];
161163 } else {
162164 pContent->AddSlot ().AutoHeight ()
163- [SNew (STextBlock)
164- .AutoWrapText (true )
165- .Text (FText::FromString (TEXT (
166- " This tileset does not contain any glTF features in its current view." )))];
165+ [SNew (SHorizontalBox) + SHorizontalBox::Slot ().FillWidth (0 .05f ) +
166+ SHorizontalBox::Slot ()
167+ [SNew (STextBlock)
168+ .AutoWrapText (true )
169+ .Text (FText::FromString (TEXT (
170+ " This tileset does not contain any glTF metadata in its current view." )))]];
167171 }
168172
169173 pContent->AddSlot ()
@@ -908,14 +912,17 @@ CesiumFeaturesMetadataViewer::createFeatureIdSetInstanceRow(
908912 FString sourceString = FString::Printf (
909913 TEXT (" Used with \" %s\" (Property Table)" ),
910914 **pItem->pPropertyTableName );
911- pBox->AddSlot ().FillWidth (1 .0f ).Padding (5 .0f ).VAlign (
912- EVerticalAlignment::VAlign_Center)
913- [SNew (STextBlock)
914- .AutoWrapText (true )
915- .Text (FText::FromString (sourceString))
916- .ToolTipText (FText::FromString (
917- " The property table with which this feature ID set should be used. "
918- " Add properties from the corresponding property table under \" glTF Metadata\" ." ))];
915+ pBox->AddSlot ()
916+ .FillWidth (1 .0f )
917+ .Padding (5 .0f )
918+ .HAlign (HAlign_Fill)
919+ .VAlign (EVerticalAlignment::VAlign_Center)
920+ [SNew (STextBlock)
921+ .AutoWrapText (true )
922+ .Text (FText::FromString (sourceString))
923+ .ToolTipText (FText::FromString (
924+ " The property table with which this feature ID set should be used. "
925+ " Add properties from the corresponding property table under \" glTF Metadata\" ." ))];
919926 }
920927
921928 pBox->AddSlot ()
0 commit comments