SHAPE_TEXT |
GET_GLYPH_METRICS);
- const OperationsMask sizeOperations = static_cast<OperationsMask>(LAYOUT | ALIGN | REORDER);
+ const OperationsMask sizeOperations = static_cast<OperationsMask>(LAYOUT | ALIGN | REORDER);
// Set the update info to relayout the whole text.
TextUpdateInfo& textUpdateInfo = impl.mTextUpdateInfo;
{
impl.UpdateModel(onlyOnceOperations);
+ if(impl.mIsAutoScrollEnabled)
+ {
+ // Layout the text for the new width.
+ operationsPending = static_cast<OperationsMask>(operationsPending | requestedOperationsMask);
+ }
+
DoRelayout(impl,
requestedControllerSize,
static_cast<OperationsMask>(onlyOnceOperations | requestedOperationsMask),
}
// Update the visual model.
- bool isAutoScrollEnabled = impl.mIsAutoScrollEnabled;
+ bool isAutoScrollEnabled = impl.mIsAutoScrollEnabled;
+ bool isAutoScrollMaxTextureExceeded = impl.mIsAutoScrollMaxTextureExceeded;
+
Size newLayoutSize;
viewUpdated = impl.mLayoutEngine.LayoutText(layoutParameters,
newLayoutSize,
elideTextEnabled,
isAutoScrollEnabled,
+ isAutoScrollMaxTextureExceeded,
ellipsisPosition);
impl.mIsAutoScrollEnabled = isAutoScrollEnabled;
void Controller::Relayouter::CalculateVerticalOffset(Controller::Impl& impl, const Size& controlSize)
{
- ModelPtr& model = impl.mModel;
- VisualModelPtr& visualModel = model->mVisualModel;
- Size layoutSize = model->mVisualModel->GetLayoutSize();
- Size oldLayoutSize = layoutSize;
- float offsetY = 0.f;
- bool needRecalc = false;
- float defaultFontLineHeight = impl.GetDefaultFontLineHeight();
+ ModelPtr& model = impl.mModel;
+ VisualModelPtr& visualModel = model->mVisualModel;
+ Size layoutSize = model->mVisualModel->GetLayoutSize();
+ Size oldLayoutSize = layoutSize;
+ float offsetY = 0.f;
+ bool needRecalc = false;
+ float defaultFontLineHeight = impl.GetDefaultFontLineHeight();
if(fabsf(layoutSize.height) < Math::MACHINE_EPSILON_1000)
{