diff --git a/es-core/src/ThemeData.cpp b/es-core/src/ThemeData.cpp index 3894fa2b0..4bf6ae63d 100644 --- a/es-core/src/ThemeData.cpp +++ b/es-core/src/ThemeData.cpp @@ -397,6 +397,7 @@ std::map> {"containerScrollSpeed", FLOAT}, {"containerStartDelay", FLOAT}, {"containerResetDelay", FLOAT}, + {"containerScrollGap", FLOAT}, {"fontPath", PATH}, {"fontSize", FLOAT}, {"horizontalAlignment", STRING}, diff --git a/es-core/src/components/TextComponent.cpp b/es-core/src/components/TextComponent.cpp index 8d21a3e09..7c46fcbe0 100644 --- a/es-core/src/components/TextComponent.cpp +++ b/es-core/src/components/TextComponent.cpp @@ -595,6 +595,9 @@ void TextComponent::applyTheme(const std::shared_ptr& theme, mScrollDelay = glm::clamp(elem->get("containerStartDelay"), 0.0f, 10.0f) * 1000.0f; } + if (elem->has("containerScrollGap")) { + mScrollGap = glm::clamp(elem->get("containerScrollGap"), 0.1f, 5.0f); + } mHorizontalScrolling = true; } else if (containerType != "vertical") {