bCenterCascadeModuleText
bCenterCascadeModuleText
#Overview
name: bCenterCascadeModuleText
The value of this variable can be defined or overridden in .ini config files. 1
.ini config file referencing this setting variable.
It is referenced in 5
C++ source files.
#Summary
#Usage in the C++ source code
The purpose of bCenterCascadeModuleText is to control the vertical alignment of module text and buttons within the Cascade particle system editor in Unreal Engine 5. It is used to enhance the visual layout of the Cascade editor interface.
This setting variable is primarily used in the Cascade module, which is part of the Unreal Engine’s particle system editor. It is referenced in the FCascadeEmitterCanvasClient class, which is responsible for rendering the Cascade editor’s canvas.
The value of this variable is set in the UCascadeOptions class, which is a configuration class for Cascade editor preferences. It is defined as a boolean property that can be edited in the editor’s configuration settings.
This variable interacts with other layout-related variables such as ModuleHeight and various positioning calculations within the FCascadeEmitterCanvasClient class.
Developers should be aware that:
- This setting affects the visual appearance of the Cascade editor interface.
- It is part of the editor’s configuration and not a runtime setting for particle systems.
- Changing this value will affect all modules displayed in the Cascade editor.
Best practices when using this variable include:
- Consider user preferences and readability when deciding whether to center the text or not.
- Ensure that any custom modules or extensions to the Cascade editor respect this setting for consistency.
- If modifying the Cascade editor’s layout, check how this setting interacts with your changes to maintain a cohesive interface.
#Setting Variables
#References In INI files
Location: <Workspace>/Engine/Config/BaseEditorPerProjectUserSettings.ini:604, section: [/Script/UnrealEd.CascadeOptions]
- INI Section:
/Script/UnrealEd.CascadeOptions
- Raw value:
true
- Is Array:
False
#References in C++ code
#Callsites
This variable is referenced in the following C++ source code:
#Loc: <Workspace>/Engine/Source/Editor/Cascade/Private/CascadeEmitterCanvasClient.cpp:69
Scope (from outer to inner):
file
function FCascadeEmitterCanvasClient::FCascadeEmitterCanvasClient
Source code excerpt:
else
{
EditorOptions->bCenterCascadeModuleText = false;
}
// This window will be 2D/canvas only, so set the viewport type to None
ViewportType = LVT_None;
CanvasDimensions = FIntPoint(0,0);
#Loc: <Workspace>/Engine/Source/Editor/Cascade/Private/CascadeEmitterCanvasClient.cpp:1495
Scope (from outer to inner):
file
function void FCascadeEmitterCanvasClient::DrawModule
Source code excerpt:
StringSize(GEngine->GetSmallFont(), XL, YL, *(ModuleName));
int32 StartY = 3;
if (CascadePtr.Pin()->GetEditorOptions()->bCenterCascadeModuleText == true)
{
StartY = FMath::Max<int32>((ModuleHeight - YL) / 2, 3);
}
Canvas->DrawShadowedString(10, StartY, *(ModuleName), GEngine->GetSmallFont(), FLinearColor::White);
}
#Loc: <Workspace>/Engine/Source/Editor/Cascade/Private/CascadeEmitterCanvasClient.cpp:1543
Scope (from outer to inner):
file
function void FCascadeEmitterCanvasClient::DrawCurveButton
Source code excerpt:
int32 YPosition = 2;
if (CascadePtr.Pin()->GetEditorOptions()->bCenterCascadeModuleText == true)
{
YPosition = FMath::Max<int32>((ModuleHeight - 16) / 2, 2);
}
Canvas->DrawTile(EmitterWidth - 20, YPosition, 16, 16, 0.f, 0.f, 1.f, 1.f, FLinearColor::White, GetIconTexture(Icon_CurveEdit));
if (bHitTesting)
Canvas->SetHitProxy(NULL);
#Loc: <Workspace>/Engine/Source/Editor/Cascade/Private/CascadeEmitterCanvasClient.cpp:1614
Scope (from outer to inner):
file
function void FCascadeEmitterCanvasClient::DrawEnableButton
Source code excerpt:
{
int32 YPosition = 2;
if (CascadePtr.Pin()->GetEditorOptions()->bCenterCascadeModuleText == true)
{
YPosition = FMath::Max<int32>((ModuleHeight - 16) / 2, 2);
}
if (Module->bEnabled)
{
Canvas->DrawTile(EmitterWidth - 40, YPosition, 16, 16, 0.f, 0.f, 1.f, 1.f, FLinearColor::White, GetIconTexture(Icon_ModuleEnabled));
#Loc: <Workspace>/Engine/Source/Editor/UnrealEd/Classes/Preferences/CascadeOptions.h:161
Scope (from outer to inner):
file
class class UCascadeOptions : public UObject
Source code excerpt:
/** If true, center the module name and buttons in the module box. */
UPROPERTY(EditAnywhere, config, Category=Options)
uint32 bCenterCascadeModuleText:1;
/** The number of units the mouse must move before considering the module as dragged. */
UPROPERTY(EditAnywhere, config, Category=Options)
int32 Cascade_MouseMoveThreshold;
/** The radius of the motion mode */